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 know how to enable root account on Leopard, but not Snow Leopard. How can I do it?

share|improve this question
    
Aren't the steps the same? I though you had to boot from the DVD and see the users options on the top menu. –  Tiago Veloso Sep 21 '09 at 15:44
3  
Why do you want to enable it? There's nothing I do that I can't just as conveniently do with sudo. –  David Thornley Sep 21 '09 at 17:00
    
Sometimes even Apple tells you to enable the root user for some administrative tasks that are just easier using root: support.apple.com/kb/HT1428 –  Arjan Oct 23 '09 at 8:36
    
When I enter System/Library/CoreServices/ I cannot find the lock you are referring to. could you explicitly tell me the name of the file? –  user66020 Feb 4 '11 at 14:18
add comment

6 Answers

up vote 8 down vote accepted

The steps are covered in the SnowLeopardTips.net article Enable root account in Snow Leopard:

  1. Open Directory Utility in /System/Library/CoreServices/.
  2. Click the padlock icon and type in your password.
  3. From the Edit menu, select Enable Root User.
  4. Select Change Root Password from the Edit menu and type in the new root password.
  5. Click the padlock icon to lock the application again.
share|improve this answer
    
Thank you. For Snow Leopard, Apple seems to bury the Directory Utility tool deep down. –  Hai Vu Sep 22 '09 at 3:52
add comment

You can get a root shell without enabling the root user account - on an admin user account at least.

sudo bash    # requires admin password
echo $SHELL 
env

# alternative
sudo -H -i   # requires admin password
echo $SHELL 
env
share|improve this answer
add comment

Type sudo passwd then su - will work with the new password.

share|improve this answer
add comment

Straight from Apple for enabling root access from 10.5 and newer:

Mac OS X 10.5:

  1. From the Finder's Go menu, choose Utilities.
  2. Open Directory Utility.

Mac OS X 10.6:

  1. From the Finder's Go menu, choose Go To Folder and enter /System/Library/CoreServices/. Alternatively you can open the Accounts Preference Pane in System Preferences, click on Login Options, click on "Join..." beside Network Account Server and then click "Open Directory Utility..." in the sheet that comes down.
  2. Open Directory Utility.

Mac OS X 10.5 and 10.6:

  1. Click the lock in the Directory Utility window.
  2. Enter an administrator account name and password, then click OK.
  3. Choose Enable Root User from the Edit menu.
  4. Enter the root password you wish to use in both the Password and Verify fields, then click OK.

Source: Enabling and using the "root" user in Mac OS X

share|improve this answer
2  
In 10.6, Directory Utility is hidden in /System/Library/CoreServices. –  Gordon Davisson Sep 22 '09 at 16:26
add comment

If you need a full root shell and find sudoing cumbersome, you can do:

sudo su -

That will give you a normal UID 0 shell to play with.

share|improve this answer
    
This is probably the easiest way to do it. –  JD. Sep 21 '09 at 20:42
    
That works! Thanks. –  Hai Vu Sep 22 '09 at 3:51
2  
'sudo -i' does the same thing afaik. –  Rich Bradshaw Sep 23 '09 at 18:11
    
@Rich: Nice. Thanks. –  Tadeusz A. Kadłubowski Sep 23 '09 at 18:12
    
I do it this way on the linux boxes I use too. There is no reason to have a root account anymore. –  sal Oct 23 '09 at 13:45
add comment

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.