So I cant get su
command to work on a terminal. All I do is type "su" and press enter, it asks for the password and I enter my currently logged in user password. It always gives this error. I swear this used to work earlier, not sure what happened.
su: Sorry
I am running a Mac OSX 10.7.1 (Lion). Anyone know what could be wrong? I am entering the right password.
In MacOS X, the root user is disabled by default, therefore su will not work. As others have stated, it's best to use sudo .
If a command requires it, you can use su to switch to the root user. Under normal circumstances, you shouldn't log in as the root user. Important: If you use su to log in as the root user, be especially careful because you have sufficient privileges to make changes that can cause your computer to stop working.
To provide sudo access, the user has to be added to the sudo group. The su command lets you switch the current user to any other user. If you need to run a command as a different (non-root) user, use the –l [username] option to specify the user account.
Click Open Directory Utility. in the Directory Utility window, then enter an administrator name and password. From the menu bar in Directory Utility: Choose Edit > Enable Root User, then enter the password that you want to use for the root user.
sudo su
will do the trick in Mac Os X terminal :)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With