2 Replies Latest reply: Mar 18, 2013 5:51 PM by robemmerson
kimatx Level 1 Level 1 (0 points)

Does anyone know how to recover this or change it? I have a "hint" but I just can't remember they way I entered it for the life of me. I have several software updates and I can't do them without this. Can someone help?


MacBook Air (13-inch Late 2010)
  • 1. Re: Can't remember my admin password
    Kappy Level 10 Level 10 (226,690 points)

    Forgot Your Account Password

     

    For Snow Leopard and earlier

     

         Mac OS X 10.6- If you forget your administrator password

     

    For Lion/Mountain Lion

     

        Boot to the Recovery HD:

     

    Restart the computer and after the chime press and hold down the COMMAND and R keys until the menu screen appears. Alternatively, restart the computer and after the chime press and hold down the OPTION key until the boot manager screen appears. Select the Recovery HD and click on the downward pointing arrow button.

     

         When the menubar appears select Terminal from the Utilities menu.

         Enter resetpassword at the prompt and press RETURN. Follow

         instructions in the dialog window that will appear.

     

         Or see Reset a Mac OS X 10.7 Lion Password and

         OS X Lion- Apple ID can be used to reset your user account password.

     

    If you are unable to boot from an installer DVD:

     

    (these will only work on Snow Leopard or earlier)

     

      1. Boot to Safe Mode by restarting and after the chime press and hold down

          the COMMAND-S keys until a black screen with white type appears.

     

      2. At the prompt, type the following commands pressing return after each

          command line:

     

         /sbin/fsck -yf

     

         If you do not receive a "Filesystem OK" message then repeat this command

         until you do.  If after seven tries you still do not receive a "Filesystem OK"

         message, then the system is corrupted and needs to be reinstalled.

     

         mount -uw /

         cd /private/var/db/netinfo

         mv local.nidb local.old

         rm ../.AppleSetupDone

         shutdown -r now

     

    The second-to-last command above will cause OS X to think that the operating system is newly installed, and when the new owner starts up the computer it will send him/her to the startup wizard where he/she can start a new user without reinstalling.

     

    This last method does not actually change a password. It simply removes the user accounts and lets you create an initial admin account as if the computer were new out of the box.

     

    Reset Admin Password Using The Terminal

     

    You can reset the password by printing out (or writing down) and carefully following these steps.

     

    First, find the short name of the admin user on the machine. The easiest way of doing this is by looking at what the directory is called in the Users folder.

     

    Now, start in Single-user Mode. It should boot into a command line.

     

    Enter these exact lines. Press RETURN after each.

     

    mount -uw /

    ifconfig lo0 up

    cd /var/db/netinfo

    netinfod -s local

     

    Now you'll need that short name. Enter "passwd", a space, and the short name of the admin. For example, if the admin was rather prosaically called "imadmin", you would enter "passwd imadmin".

     

    The computer will now prompt you to change the password for "lmadmin" (or whatever the short name was). Go ahead and enter a new password.

     

    Now, enter:

     

    sync

    reboot

     

    and the machine will reboot. The admin password should now be changed.

  • 2. Re: Can't remember my admin password
    robemmerson Level 1 Level 1 (5 points)

    You should be able to just reset the root password, then login as root and reset your own password.

     

    To reset the root password on Mountain Lion (10.8) (not tested with other OS's) follow these instructions.

     

     

    Shutdown your Mac, then turn it on. Immediately after pressing the power button press and hold 'Command (Apple) key + S'. This will boot you into single user mode.

     

    Enter the following commands exactly as written here and press enter at the end of every line:

     

    /sbin/mount -uw /

    launchctl load /System/Library/LaunchDaemons/com.apple.opendirectoryd.plist

    passwd

     

     

    then enter the new password for the root account twice. After this just enter 'reboot' and your system will start normally, then login as root on the login window. Once logged in as root, open System Preferences -> Users & Groups -> Unlock -> Your Account -> Reset Password.

     

    Message was edited by: robemmerson to tidy up formatting