 |
 |
Why do me and root have the same password? Wait. Do we?
|
 |
|
 |
|
Registered User
Join Date: Oct 2003
Status:
Offline
|
|
When I log in to my box as "john", I type my password: mycatsbreathsmellslikecatfood
Now, my 'john' account is a so-called "Admin" account. The only Admin account on the computer as a matter of fact.
When I need to use sudo for any particularly dangerous command, like say, 'sudo ls -l', I have to give... a password. Hmm... Am I giving my password here or the root password?
Wait. Thinking back, when I installed Panther, I was never asked to provide a root password -- I had to come up with only one password; for the "john" user.
Is my password actually the root password as well? If not, what *is* the root password?!
Hmm... life is so much simpler with Slackware... ;^) [ducks]
|
|
|
| |
|
|
|
 |
|
 |
|
Professional Poster
Join Date: Oct 1999
Location: Always within bluetooth range
Status:
Offline
|
|
You're an admin user, not "Root" (which is disabled by default in OS X). To enable Root, you must manually go into Applications/Utilities/NetInfo Manager .... go to the "Security" menu and click "Enable Root User". You'll then be prompted to create a password. Unless you have a specific need to enable Root, its better just to leave it off. If you have to enable root for some reason ... go back and disable root when you are finished.
So ... no, your password is NOT Root's password (unless you choose to make it so)
|
|
|
| |
|
|
|
 |
|
 |
|
Registered User
Join Date: Oct 2003
Status:
Offline
|
|
Thanks for the reply Herschel. I'm a bit used to unix, so the idea of a disabled root user strikes me as very unnatural. :)
Interestingly enough: on my Powerbook, I've never enabled root, so there's no root password set for it. When I boot into single-user mode on the PB and run the passwd command, it just hangs (!). I guess it doesn't like having the current password being ... hmm... undefined? :)
|
|
|
| |
|
|
|
 |
|
 |
|
Grizzled Veteran
Join Date: Apr 2001
Status:
Offline
|
|
That's the way sudo works - with your own password.
It's purpose is to allow non-root users to run commands as root. Otherwise, well, they'd have to have the root password.
And on OS X there is no reason to enable root. You can do everything with sudo and sudo -s.
Wade
|
|
|
| |
|
|
|
 |
|
 |
|
Registered User
Join Date: Oct 2003
Status:
Offline
|
|
> That's the way sudo works - with your own password.
Right. I was just confused because, after installing Panther, the only password I ever had to come up with during the install was my own. Since I figured that there *had* to be a root user, I just guessed that the one password maybe somehow went for both. [shrug]
I mean, who ever heard of a root user but no root password?! :)
|
|
|
| |
|
|
|
 |
|
 |
|
Mac Elite
Join Date: Oct 1999
Location: San Jose, Ca
Status:
Offline
|
|
The "sudo" password is always the password for the user invoking it. Sudo then goes to a file (/etc/sudoers) and sees what the policy is for that user/group. Since there is a line in the standard sudoers file on MacOS X that says:
%admin ALL=(ALL) ALL
...sudo knows that anyone in the admin group can run any application as if they were root, but since there is nothing that says they don't have to use a password, they have to give their password.
Sudo is a very powerful admin tool when you know how to use it correctly.
|
|
|
| |
|
|
|
 |
|
 |
|
Addicted to MacNN
Join Date: Mar 2000
Location: London, UK
Status:
Offline
|
|
Originally posted by larkost:
Sudo is a very powerful admin tool when you know how to use it correctly.
And a very dangerous one when you don't.
|
|
|
| |
|
|
|
 |
 |
|
 |
|
|
|
|
|

|
|
 |
Forum Rules
|
 |
 |
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
 |
 |
 |
 |
|
 |
|