How to Change the Admin Password with Mac OS X Single User Mode:
- First you need to enter Single User Mode. Reboot the Mac and hold down Command+S at boot to enter into the command line.
- You’ll see a note where Mac OS X tells you that you need to run two commands in order to make filesystem changes, this is necessary so let’s handle that first
- The first command checks the Mac OS X filesystem for errors and fixes them, it can take a few minutes to run:
fsck -fy
- The next command mounts the root Mac OS X drive as writable, allowing you to make changes to the filesystem:
mount -uw /
- After the filesystem is mounted, you can reset any users password using the following command:
passwd username
- You’ll need to enter the new password twice to reset and confirm the changes
If you’re fixing someones machine and you don’t know the username to reset, just look in /Users with:
Here you’ll see at least three items, .localized, Shared, and a username. The username is what you’ll want to change with the passwd command.ls /Users/
After the password is reset and confirmed, you can exit out of Single User Mode by typing exit or reboot.
That’s it. Now you can access Mac OS X with the new password. In this way you can change an Admin password in Mac OS X Single User Mode. If you found any difficulty in following the above steps then feel free to ask in the comment section below