macbookbro67

Q: You are unable to log in to the user account "xxxx" at this time. Logging in to the account failed because an error occurred - QUICK EASY FIX

YOU DO NOT HAVE TO RE-INSTALL MOUNTAIN LION -

 

If you find yourself locked out of your ML administrator account - and/or all other admin accounts and receive this message when entering the correct password: "You are unable to log in to the user account "xxxx" at this time. Logging in to the account failed because an error occurred" this is due to a misconfiguration in your server active directory set-up.

 

You need a new admin account - follow these directions to get yourself a new administrator level account on your mac with all your original files and settings intact - here we go:

 

STEP 1 BOOT INTO SINGLE USER MODE

 

Boot your affected Mac into Single User Mode by pressing Command + S at the chime

 

Note** if you are using rEFIt, highlight the icon which boots into the OSX installation you are currently locked out of and then press F2, nav down the menu options to Boot into single user mode and hit ENTER

 

STEP 2 MOUNT YOUR OS X INSTALLATION

 

Type: /sbin/mount -uw / at the prompt and hit enter.

 

STEP 3 TRICK OSX START UP INTO BELIEVING ITS BEING RUN FOR THE FIRST TIME

 

Type: rm /var/db/.applesetupdone

 

What this does is deletes a specific file OSX checks each time it runs to determine whether its running for the first time or if accounts have already been set up. By removing this file, when we reboot, OSX will assume this is a brand new set-up and will allow us to create new accounts.

 

STEB 4 REBOOT

 

Type: reboot

 

STEP 5 - SET UP A NEW ADMIN ACCOUNT --- BUT DO NOT USE THE SAME NAME AS ANY EXISTING ACCOUNT

 

If you use the name of an existing account, you will overwrite the files of that account. Just set up a new unique admin account and then log in.  once you are logged back into your Mac with administrator access, you can correct the issues which locked you out in the first place.

 

 

 

If this fails or you prefer another method of gaining access - I recommend the open source ophcrack application - it works pretty well too and detailed instructions can be found at SourceForge.

 

Hope this helps some of you experiencing some of the same ML and ML Server issues I am run into. Reformatting a partition is a last ditch solution.

iMac, OS X Mountain Lion (10.8.2), Works for Administrator Lock-Outs

Posted on Sep 21, 2012 7:21 PM

Close

Q: You are unable to log in to the user account "xxxx" at this time. Logging in to the account failed because an error occurred - QUI ... more

  • All replies
  • Helpful answers

Page 1 Next
  • by AliBrownster,

    AliBrownster AliBrownster Apr 25, 2013 11:21 AM in response to macbookbro67
    Level 1 (0 points)
    Apr 25, 2013 11:21 AM in response to macbookbro67

    Oh man, you are awesome!  Searched all over the net and tried countless other solutions, but this was the only one that worked!

     

    Little tip for those who use wireless keyboard (which doesn't work for logging into single user mode at startup).  If you have a PC keyboard then use the Windows key + s at startup.

  • by kingfisher500,

    kingfisher500 kingfisher500 Apr 7, 2014 9:11 AM in response to macbookbro67
    Level 1 (0 points)
    Apr 7, 2014 9:11 AM in response to macbookbro67

    Do you know how to do this in Mavericks?

     

    The command "rm /var/db/.applesetupdone" gets the response "no such file or directory.

  • by baltwo,

    baltwo baltwo Apr 7, 2014 3:55 PM in response to kingfisher500
    Level 9 (62,256 points)
    Apr 7, 2014 3:55 PM in response to kingfisher500

    It should be the same. BTW, the file's named .AppleSetupDone, but case shouldn't be an issue. If you're getting that message, then the you don't have to remove it.

  • by baltwo,

    baltwo baltwo Apr 7, 2014 3:57 PM in response to baltwo
    Level 9 (62,256 points)
    Apr 7, 2014 3:57 PM in response to baltwo

    ls -al /var/db/ should show everything in the folcer.

  • by kingfisher500,

    kingfisher500 kingfisher500 Apr 8, 2014 7:15 AM in response to baltwo
    Level 1 (0 points)
    Apr 8, 2014 7:15 AM in response to baltwo

    I tried again. I had left a space after "db/" and ".applesetupdone"

     

    I eliminated the space and changed the filename to ".AppleSetupDone" and it worked.

     

    I was unable to use my original password but, with a new one, I was able to log in. I was not, however, able to change the Home Folder, which is what I was trying to do when things went wrong.

     

    I have installed Mavericks on an external drive, which houses my Home Folder, and then do a clean install on this internal drive and use it as aan emergency startup drive.

     

    Thanks for your help.

  • by baltwo,

    baltwo baltwo Apr 8, 2014 12:13 PM in response to kingfisher500
    Level 9 (62,256 points)
    Apr 8, 2014 12:13 PM in response to kingfisher500

    thumbsup.gif

  • by LauraleeG,

    LauraleeG LauraleeG May 3, 2015 12:59 PM in response to macbookbro67
    Level 1 (0 points)
    May 3, 2015 12:59 PM in response to macbookbro67

    Hello. I tried this message to but the error transferred over to the new admin acct i created. I think the bug/error is on my time machine backup becaus i restored the files there ( so i coould have access to my files) and then i couldnt sign back in!!!  I wont do that again (restore from time macjine) but how do i "correct the issue that caused the error in the first place" when i dont know what that was?!?  Any help you could provide would be appreciated. Thank you.  

  • by Zorro21c,

    Zorro21c Zorro21c Nov 3, 2015 10:26 PM in response to macbookbro67
    Level 1 (14 points)
    Nov 3, 2015 10:26 PM in response to macbookbro67

    "...once you are logged back into your Mac with administrator access, you can correct the issues which locked you out in the first place..." The question is how to correct the issues?  I have three admin accounts in my mac.  Two accounts have no problem to log in so I can still use any as an admin account, but my main admin account is blocked.  It has iPhoto and Aperture albums which I like to retrieve. I used Time Machine to go bak but that still blocked me out of the main admin account. The photo albums in all I want.  Do you have any other tricks up your sleeve?  Thanks.

  • by Ian creating problems,

    Ian creating problems Ian creating problems Dec 31, 2015 7:32 AM in response to macbookbro67
    Level 1 (0 points)
    Dec 31, 2015 7:32 AM in response to macbookbro67

    I had moved my home directory to an external hard drive. A few years later, I changed to name of the hard drive using 'get info.' This is when things got screwed up and I started getting the frustrating message that I cannot log in to my account (Admin). However, when I log in as a Guest, I can make changes using my admin ID. So the computer recognizes my admin privileges under the Guest account!

     

    Solution: Revert the name of the hard drive back to the original name and everything worked as before. I guess I could have, instead, updated the file path but I was too frustrated to try anything new and adventurous.

  • by adams_l,

    adams_l adams_l Aug 4, 2016 9:49 PM in response to macbookbro67
    Level 1 (8 points)
    Notebooks
    Aug 4, 2016 9:49 PM in response to macbookbro67

    Can anyone explain why this error happens in the first place? Is there a way to correct it other than just starting over? I'd like to have all my preferences back.

  • by Eric Root,

    Eric Root Eric Root Aug 5, 2016 8:27 AM in response to adams_l
    Level 9 (69,659 points)
    iTunes
    Aug 5, 2016 8:27 AM in response to adams_l

    You might want to consider starting a new discussion. Since this one is a couple of years old, less people are likely to look at it. A new post would be much more visible. You can link to this one.

  • by vsithape,

    vsithape vsithape Aug 10, 2016 5:32 PM in response to Eric Root
    Level 1 (12 points)
    Mac OS X
    Aug 10, 2016 5:32 PM in response to Eric Root

    I have created new thread but no one responded for same issue. If you know what are those errors n how to fix them then comment here as it will pop up in any search.

  • by vsithape,

    vsithape vsithape Aug 10, 2016 6:17 PM in response to macbookbro67
    Level 1 (12 points)
    Mac OS X
    Aug 10, 2016 6:17 PM in response to macbookbro67

    whats this error and how to rectify it after regaining new admin account access to computer. please add your inputs on how to get in to old account as even master password or applied  password reset help does not work  and also files and information under that user account is inaccessible

Page 1 Next