Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Reboot a hung system with Spotlight and Terminal' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Reboot a hung system with Spotlight and Terminal
Authored by: siMac on Dec 30, '08 08:01:55AM

Why bother with SSH? All you need is a terminal window and you can just enter 'sudo reboot' then the admin password.

SSH would be useful if you are unable to get a terminal window to open on the hung machine as you will be able to issue the reboot command from another machine on the same network.



[ Reply to This | # ]
Reboot a hung system with Spotlight and Terminal
Authored by: Alrescha on Dec 30, '08 08:09:23AM

I think implied was the possibility that you might not be logged in as an administrator (I do not use a privileged userid most of the time). In this case, you still don't need to use ssh, but could just type "su admin_user_name" and type the appropriate password.

A.



[ Reply to This | # ]
Reboot a hung system with Spotlight and Terminal
Authored by: Stormchild on Dec 30, '08 08:21:28AM

Yeah, was going to ask the same thing. There's no reason to SSH to your own machine. And if you're only going to execute a single command as root, there's no need to even 'su'. Just 'sudo' the command.



[ Reply to This | # ]
Reboot a hung system with Spotlight and Terminal
Authored by: junklight on Dec 30, '08 08:25:15AM

ah ssh'ing from another machine - a trick that has saved me on more than one occasion.

Often if you have ssh'd in you can kill rogue processes.

ps -A and a sudo kill -9 XXX where XXX is the process number can often work wonders.



[ Reply to This | # ]
Reboot a hung system with Spotlight and Terminal
Authored by: kainewynd2 on Dec 30, '08 08:58:34AM
It is easier to just type: 'login username' rather than ssh. SSH requires remote login to be checked, login always works on a local machine (which is what this hint is for).

In short, replace this:
Log into Terminal as an administrator, for example: ssh admin@mycomputername.local (replace admin with the short name of an administrator account, and mycomputername.local with your computer's Bonjour name (see the Sharing preference pane).

With this:
Log into Terminal as an administrator; for example: login admin (replace admin with the short name of an administrator account).

Simple as pie... ;)

[ Reply to This | # ]
Reboot a hung system with Spotlight and Terminal
Authored by: kiltbear on Dec 30, '08 09:07:18AM

Very cool, my suggestion was to "su admin" rather than "login admin"

Slightly different than "sudo". "sudo" is kind of like an enhanced "su".

"sudo newuser", if you are an admin account will allow you to use your own password to become that new user. "su newuser" will prompt you for the newuser's password.

Another subtle difference is that "su newuser" won't try to do any login stuff, like sourcing your .profile, etc, which login will. So, in some case "su admin" will get you to your privileged execute status with less fuss and muss if things are hanging.



[ Reply to This | # ]
Reboot a hung system with Spotlight and Terminal
Authored by: mat79 on Dec 30, '08 10:45:56AM

IIRC only the Admin-Users are in the sudoers file, so a login would be safer



[ Reply to This | # ]