[HOWTO] Reset User Password via single user mode

Satcomer

In Geostationary Orbit
Read this MacOSXHint on how to reset your 10.5 password via the single user mode.

1. Boot into single user mode (press Command-S at power on)
2. Type fsck -fy
3. Type mount -uw /
4. Type launchctl load /System/Library/LaunchDaemons/com.apple.DirectoryServices.plist
5. Type dscl . -passwd /Users/username password, replacing username with the targeted user and password with the desired password.
6.Reboot

This allows you to reset the password in single user mode without booting from the install media.
 
Cool hack! And one more reason to block single user mode by setting a firmware password if you use a mac at work!
 
instead of typing
dscl . -passwd /Users/username password
just type
passwd /Users/username password
thats what worked for me.
 
single user mode reset password:leopard
mount -uw /
ls /users
passwd (user's name)
(enter the password cannot be seen)
reboot


------

single user mode change password tiger

1. mount -uw /
2. sh /etc/rc
3. ls /users
4. passwd (user name)
 
single user mode reset password:leopard
mount -uw /
ls /users
passwd (user's name)
(enter the password cannot be seen)
reboot


------

single user mode change password tiger

1. mount -uw /
2. sh /etc/rc
3. ls /users
4. passwd (user name)

I'm sorry, but I don't understand you at all. I bought a used mac laptop. The person I bought it from doesn't remember the password, so I can't install any new software or make myself the administrator. What can I do?
 
I'm sorry, but I don't understand you at all. I bought a used mac laptop. The person I bought it from doesn't remember the password, so I can't install any new software or make myself the administrator. What can I do?

Ask yourself if it is a PPC or Intel Mac? Plus whenever asking for help please list the Mac and possible the version of OS x you are using.

Now do you know how to boot into Single-User mode? For the instructions to boot into that mode and once that comes up type the instructions provided by sheraz4u. He expanded my original post for 10.4.x for Tiger users (Tiger is 10.4.x and Leopard is 10.5.x).

Lastly if you just bought that from a user then he/she should have reformatted or provided you with a password. Plus you should NEVER buy a used computer without the original install disk provided with it. If you think about it the seller might leave all their personal stuff on the Mac/computer (that is advice for any kind of computer).
 
Okay. It's a PPC mac. System OSX4.11. He DID reformat and wipe and all that good stuff. Made the admin noname and can't remember what he made the password.

I have never started any Mac and seen a place where I could enter anything like the following:
1. mount -uw /
2. sh /etc/rc
3. ls /users
4. passwd (user name)

Is this something that only happens in single-user or verbose mode? I understand getting there, I've just never done it.

I appreciate your help. Thank you.
 
Well follow these steps (since you have a Tiger (10.4.11) these are the steps). I will try to be right to the point.

1. Ask the person who sold you the Mac what Username did he give the Mac when he formatted it before he sold it. This is VERY import!

2. Find the Power button.. With the other hand hold the two buttons Command (apple key) button + the letter S (at the same time) while booting up the Mac.

3. Hold down the command + s until you see a black screen with white scrolling letters. Let go of the buttons at this point.

4. At the prompt sign (where you can type) type:
fsck -y

Let that run (it will run for about 5 to 10 minutes) until it reports all is well with the disk. At the point of this it will give you another typing prompt.

4. Type: mount -uw /

Then hit the 'return' button.

5. At the next prompt type: sh /etc/rc

Then hit the 'return' button.

6. At the net prompt type: ls /users

Then hit the 'return' button.

7. At the next prompt (at this point you NEED to have the Username the person made on that Mac) type: passwd (your Username without the quotes )

At this point it should ask you to type the new password for the Username you used. It will ask to type the new password one more time to make sure it is good before it changes the password. If all goes well and the change is successful you can type: reboot at any prompt to exit single-user mode and reboot the Mac into normal mode.

Lastly at the login page you will be able to use you new password to login. If you can login go you system Preferences (in the Dock) and launch it. Choose the "Accounts" pane to change the user preferences about logging in. What ever you DON'T change the current logged in User name at any time. Just make a new Administrator account and then login to that new Account and then you can go to the same place and then delete the Username that is not yours.

I hope this helps because it the best I come up with at this time of night before bed. Good Luck.
 
Last edited:
Read this MacOSXHint on how to reset your 10.5 password via the single user mode.

----
single user mode reset password:leopard
mount -uw /
ls /users
passwd (user's name)
(enter the password cannot be seen)
reboot
----

Would I use this if my Admin account changes to standard? This what happened and now I can't add software, change file names, etc. It happened after I downloaded OS X 10.5.7 . Now everything is messed up for Admin account.

iMac Early 2009, OS X 10.5.7
 
Read this MacOSXHint on how to reset your 10.5 password via the single user mode.

You have different problems! The hint was only to change an password. Unless you really messed up the instructions then something else went wrong. Do you still have the OS X install disk? If you do then do an Archive & Install to keep your programs and fix your system problems.

Plus did you read the hint [HOWTO] Fix User lost Administrator privileges?

I read the blog and wondered if that is the route I would go to fix my problem.

Do I need to use the startup disk to remedy my problem? I found instructions for that too.

I'm still confused which way to proceed.

These are the instructions:
Mac OS X 10.5: Administrator user changes to standard

Symptoms
After performing an upgrade installation (the default type) of Mac OS X 10.5 Leopard, an administrator account may change to a standard one.
Resolution
1. Start from your Mac OS X 10.5 Install DVD. (You do not need to install Leopard again.)
2. From the Utilities menu, choose Reset Password (do not choose Firmware Password Utility).
3. Follow the onscreen instructions to reset the root password (the root account is not the same as your account). Specifically: Select the name of the drive that Mac OS X is installed on, select the user named "System Administrator (root)" from the pop-up menu, type the password in the first field, re-enter the password in the second field, then click the Save button.
4. Restart from your Mac OS X Leopard volume.
5. When the login window appears, select "Other..." and log in as the root user using the password that was created above.* Note: If Mac OS X automatically logs in, choose Log Out (name) from the Apple menu to get to the login window.
6. Go to Accounts preferences and check (enable) "Allow user to administer this computer" for the affected user.
7. From the Apple menu, choose Log Out root....
8. Log in as the user account that had this issue. (Your account should now have administrator access.)
9. Use Directory Utility to disable the root user via Directory Utility's Edit menu. You may need to click the lock icon first).



Is resetting the password for the 'root' account the same as in your instructions? In other words I determine the 'root' account's password right then?
 
When I enter the command sh /etc/rc, I get stuck on this repeating message:

Sep 3 23:16:00 brenton-walters-ibook-g4 lookupd[58]: Can't load /System/Library/PrivateFrameworks/NetInfo.framework/Resources/lookupd/Agents/NI.bundle/NI

The last NI alternates with DS, and the time changes as it repeats. I can still enter commands to break up the repetition, but I when I enter the last one (passwd my username with a space) I get this:

usage: passwd [-i infosystem] [-l location] [name]
supported infosystems are:
netinfo
file
nis
opendirectory
for netinfo, location may be a domain name or server/tag
for fil, location may be a file name (/etc/master.passwd is the default)
for nis, location may be a NIS domainname
for opendirectory, location may be a directory node name

then back to the repeating line.

Edit: I just entered passwd myusername (without the space) and it returned:
Changing password for myusername.
New password:

I typed in a new password, then retyped it, and it said Sorry. I tried this multiple times, being extra-special careful. Should I just take it in?
 
ahaha, we all need to screw up the first time, and it has to be frustrating. Or else everyone would be a computer genius.
In more helpful words, have you tried inserting the OS install disk and repairing permissions?
 
Back
Top