Home > Uncategorized > HOWTO: Reset a lost OS X password

HOWTO: Reset a lost OS X password

May 5th, 2009 grady

I’ve you’ve forgotten your Mac’s admin account password, don’t worry. Assuming you haven’t locked out OpenFirmware, it’s a pretty simple task to change your password back to something you know.
Here’s how:

  • Hold Apple+S when booting to enter single user mode
  • #sh /etc/rc
  • #passwd yourusername
  • #reboot

If you can’t recall your user name, you can either look in the /Users folder (the directories are named by user), or run “niutil -list . /users”.
Also, on older systems the /etc/rc script isn’t available, apparently. If that second step fails, try mounting and starting the base services manually:

  • #/sbin/fsck -y
  • #/sbin/mount -uw /
  • #/sbin/SystemStarter

I’ve had to do this a couple of times for friends when they’ve bought a second hand machine, and once when I had a momentary brain lapse and forgot my own password. Works like a charm, though you’ll loose any passwords stored in your keychain.

Categories: Uncategorized Tags:
Comments are closed.