Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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

1 Answer 1

Log out users after a certain time limit:

http://hints.macworld.com/article.php?story=20100604123854198


EDIT:

Alternatively, create an executable shell script with something like:

#!/bin/bash
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

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.