Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have 2 accounts, both admin, on my Mac OS X 10.6 MacBook Pro. I use fast user switching and automatic login. Both accounts have no password. Security is not an issue.

It's irritating that whenever I go to restart the computer (frequently, dualboot every night to play games), I get the message prompt:

"There are currently logged in users who may lose unsaved changes if you restart this computer"

And I have to enter one of the user names and hit enter. How can I prevent this message from occurring and simply reboot without that? I know I can log one of the users off, but that's yet another step..

share|improve this question

Log out users after a certain time limit:


Alternatively, create an executable shell script with something like:

echo "password" | sudo -S shutdown -r now

You could link this to an alias on your desktop.

The -S switch takes input from stdin, which is your root password as indicated above.

If you don't feel comfortable putting the root password in clear text, you could use visudo as outlined here.

share|improve this answer
But I switch the users frequently up until the point that I want to restart – Nektarios Jan 19 '11 at 4:00
See my revised answer with script. – user3463 Jan 19 '11 at 4:32
I had no idea a sudo request was what made the window pop up. That's excellentt - will try this tonight, thank you – Nektarios Jan 19 '11 at 18:26
The shell script works yes, but having a shell script to reboot my mac isn't exactly ideal - still looking for a solution to the proper reboot dialog to work – Nektarios Jan 20 '11 at 4:02
Good luck with that. You won't find anything. You're asking for a way to bypass the root password. – user3463 Jan 20 '11 at 18:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .