You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

administrator changed to standard: cannot log in without details: single user mode fix does not work for me...

Before anyone tells me or links me to the Single User Mode fix solution, please don't. It does not work for me for whatever reason and I have watched videos and read forums, tried it multiple times with no success. So much that the file I'm trying to remove doesnt even exist anymore so it doesn't work.


I was changing the name of my administrator account and for some reason the entire account was switched to standard. I did not mean for it to happen and Im baffled as to why it did that.


Is there any other solution to this besides rebooting into Single User Mode and doing the 3 commands? Im at a loss here and I really don't have time for this nonsense. If anyone has a proper solution that will fix this for me please help. I will be forever grateful.


Im running High Sierra 10.13.2 if that helps.

MacBook Pro TouchBar and Touch ID, macOS High Sierra (10.13.2)

Posted on Jan 28, 2018 2:32 PM

Reply
Question marked as Top-ranking reply

Posted on Jan 28, 2018 3:23 PM

The file is definitely present, which is the reason your Mac is booting normally without prompting you to create an account.


You wrote that you do not want instructions you found repeated elsewhere, but I don't know what those instructions were. The following is the only method I use. If it does not work I'm out of ideas.



Read the lengthy procedure that follows. You should probably print it vs. writing down the steps or trying to repeat it from memory. Don't be put off by the length of the instructions. Some of the steps are optional. It's very easy and will only take a few moments.


It is also overly conservative, but I have used it myself recently and I know it will work.



First please tell me that you have not enabled FileVault. If you don't know, open System Preferences > Security & Privacy > FileVault. If it says "FileVault is turned on for the disk ..." then you won't be able to fix it and you might as well stop reading. Write back for recommendations.


Then, please make sure you have a reliable backup in the event something unexpected occurs. To learn how to use Time Machine please read Use Time Machine to back up or restore your Mac - Apple Support.


Confirm both of those before proceeding.


Then: Read and follow the instructions below with care.



As I understand it, you have a Mac with no Administrator accounts. Of course that is not supposed to be possible, but if that really is the case you can use the following technique to create a new, temporary Administrator account, the sole purpose of which will be to log in as an Administrator that can give your normal account Admin privileges.


There may be other techniques to recover from the "impossible" circumstance in which you find yourself, but the following is one that I have successfully used in the past.


It will not work in the following circumstances:


  • If you configured an EFI Firmware Password that will preclude recovery, unless you know that password.
  • It won't work if you encrypted your startup volume with FileVault.

Please read everything that follows before continuing. If you have only the one computer you will need to print this for reference.


  • Power on or restart your Mac.
  • At the chime or grey screen, hold and S on your keyboard (two fingers) to enter single-user mode.
  • At the localhost:/ root# prompt, type


fsck -fy

...and press Return.

This is a simple check for file system integrity and is optional. It may take a few minutes to complete during which time various messages will appear. None of them are relevant unless they indicate some unrecoverable error. Be patient. If you get concerned that the system has stalled or become unresponsive press the Return key. Nothing will happen other than to echo the Return character, advancing the text on the screen, confirming your Mac has not completely frozen.

When the integrity check completes pressing the Return key will result in the localhost prompt again, waiting for your input.


At the localhost:/ root# prompt, type each of the following lines, exactly as written, including capitalization, one line at a time, each line followed by the Return key. There is a single space preceding the first "slash" ( / ) character in each line:


mount -uw /

rm /var/db/.AppleSetupDone

reboot


The Mac will restart, and then take you through the entire setup and registration process that you have not seen since you originally unboxed it. Do not be concerned—none of the above deletes any information. All your pre-existing user accounts will still available, assuming they were not already erased prior to beginning this procedure.


Do not elect to transfer your information from another Mac: When you get to the "Transfer Information to This Mac" screen, select "Do not transfer any information now" and press Continue. Have your existing Apple ID and password ready. At the "Create a Computer Account" screen, create the new, temporary account using a different "Full name" and "Account name" than the one you already use. Remember the password you select. You don't have to sign in to iCloud or anything else you might decide to do if you wanted to use that User Account for anything else.


When it completes, log in under that new account. Use System Preferences to change your normal account to "Allow user to administer this computer". Log out, log in under your normal account and verify you can use it without restriction.


After that, you can safely delete the temporary account you just created by following these instructions: Delete a user or group - Apple Support. Before removing it, confirm you don't need any of the files you might have created in that Account.

Similar questions

12 replies
Question marked as Top-ranking reply

Jan 28, 2018 3:23 PM in response to gyasikn

The file is definitely present, which is the reason your Mac is booting normally without prompting you to create an account.


You wrote that you do not want instructions you found repeated elsewhere, but I don't know what those instructions were. The following is the only method I use. If it does not work I'm out of ideas.



Read the lengthy procedure that follows. You should probably print it vs. writing down the steps or trying to repeat it from memory. Don't be put off by the length of the instructions. Some of the steps are optional. It's very easy and will only take a few moments.


It is also overly conservative, but I have used it myself recently and I know it will work.



First please tell me that you have not enabled FileVault. If you don't know, open System Preferences > Security & Privacy > FileVault. If it says "FileVault is turned on for the disk ..." then you won't be able to fix it and you might as well stop reading. Write back for recommendations.


Then, please make sure you have a reliable backup in the event something unexpected occurs. To learn how to use Time Machine please read Use Time Machine to back up or restore your Mac - Apple Support.


Confirm both of those before proceeding.


Then: Read and follow the instructions below with care.



As I understand it, you have a Mac with no Administrator accounts. Of course that is not supposed to be possible, but if that really is the case you can use the following technique to create a new, temporary Administrator account, the sole purpose of which will be to log in as an Administrator that can give your normal account Admin privileges.


There may be other techniques to recover from the "impossible" circumstance in which you find yourself, but the following is one that I have successfully used in the past.


It will not work in the following circumstances:


  • If you configured an EFI Firmware Password that will preclude recovery, unless you know that password.
  • It won't work if you encrypted your startup volume with FileVault.

Please read everything that follows before continuing. If you have only the one computer you will need to print this for reference.


  • Power on or restart your Mac.
  • At the chime or grey screen, hold and S on your keyboard (two fingers) to enter single-user mode.
  • At the localhost:/ root# prompt, type


fsck -fy

...and press Return.

This is a simple check for file system integrity and is optional. It may take a few minutes to complete during which time various messages will appear. None of them are relevant unless they indicate some unrecoverable error. Be patient. If you get concerned that the system has stalled or become unresponsive press the Return key. Nothing will happen other than to echo the Return character, advancing the text on the screen, confirming your Mac has not completely frozen.

When the integrity check completes pressing the Return key will result in the localhost prompt again, waiting for your input.


At the localhost:/ root# prompt, type each of the following lines, exactly as written, including capitalization, one line at a time, each line followed by the Return key. There is a single space preceding the first "slash" ( / ) character in each line:


mount -uw /

rm /var/db/.AppleSetupDone

reboot


The Mac will restart, and then take you through the entire setup and registration process that you have not seen since you originally unboxed it. Do not be concerned—none of the above deletes any information. All your pre-existing user accounts will still available, assuming they were not already erased prior to beginning this procedure.


Do not elect to transfer your information from another Mac: When you get to the "Transfer Information to This Mac" screen, select "Do not transfer any information now" and press Continue. Have your existing Apple ID and password ready. At the "Create a Computer Account" screen, create the new, temporary account using a different "Full name" and "Account name" than the one you already use. Remember the password you select. You don't have to sign in to iCloud or anything else you might decide to do if you wanted to use that User Account for anything else.


When it completes, log in under that new account. Use System Preferences to change your normal account to "Allow user to administer this computer". Log out, log in under your normal account and verify you can use it without restriction.


After that, you can safely delete the temporary account you just created by following these instructions: Delete a user or group - Apple Support. Before removing it, confirm you don't need any of the files you might have created in that Account.

Feb 12, 2018 11:00 AM in response to gyasikn

The only things you should be typing into the localhost:/ root# prompt are the commands I specified. There are four in all:


fsck -fy

mount -uw /

rm /var/db/.AppleSetupDone

reboot

Type nothing else other than those four, in that order, each one followed by the Return or Enter key. Type each one of them only after the localhost:/ root# prompt appears.


Describe where you get stuck.

Jan 28, 2018 2:49 PM in response to gyasikn

So much that the file I'm trying to remove doesnt even exist anymore so it doesn't work.


The purpose of booting Single User Mode is to delete that file. The lack of it initiates the "new user setup" procedure. Its presence tells the system not to do that so it boots normally. So, something doesn't make sense to me.


Please confirm its absence by copying and pasting the following line in a Terminal window. You do not require Administrator privileges for it to work.


ls /var/db/.AppleSetupDone


If the file exists, you will see something like the following:


iMac11:etc john$ ls /var/db/.AppleSetupDone

/var/db/.AppleSetupDone

iMac11:etc john$


If the file does not exist, you will see something like the following:


iMac11:etc john$ ls /var/db/.AppleSetupxxx

ls: /var/db/.AppleSetupxxx: No such file or directory

iMac11:etc john$


If what you're describing is correct, that's the result you will get: "No such file or directory".


I was changing the name of my administrator account and for some reason the entire account was switched to standard.


That will do it. Changing the name of an Administrator account requires adherence to these instructions: Change the name of your macOS user account and home folder - Apple Support.

Apr 7, 2018 8:02 PM in response to John Galt

Dear Mr.John! I have made all what you wrote and got a message "No such file or directory". And after you recommend to do this: That will do it. Changing the name of an Administrator account requires adherence to these instructions: Change the name of your macOS user account and home folder - Apple Support.

Sorry, but it is not possible for me, because at the moment i can go inside of the system only on guest mode. And i can not change the name of my macOs user account, because its blocked by lock, for unblocked i need to put a name of administrator and password. What can i do? Please help me!!! And if i go to the bash i can make operation there only in the guest mode too. When i put this command in terminal:

rm /var/db/.AppleSetupDone

The bush write:

rm: /var/db/.AppleSetupDone: Permission denied

mount -uw /

The bush write:

mount: illegal option -- / usage: mount [-dfruvw] [-o options] [-t external_type] special node mount [-adfruvw] [-t external_type] mount [-dfruvw] special | node

fsck -fy

The bash write:

ERROR: volume / is mounted with write access. Re-run with (-l) to freeze volume.

Jan 28, 2018 3:03 PM in response to John Galt

Hi John, thanks for replying.


So I ran the ls command and it is there. I originally said it was gone because upon executing the rm command it was giving me "no such file or directory" so I wasn't even able to continue trying that option. But yes it seems to be there.


~ ➤ ls /var/db/.AppleSetupDone

/var/db/.AppleSetupDone

~ ➤

Honestly I don't even want to change the name anymore because of this nightmare, but is there anything else I can try to do to reverse the issue and regain administrator control?

Feb 12, 2018 10:58 AM in response to John Galt

Ah the only reason I mentioned the password issue was because you mentioned the FileVault problem.


I just used the commands you gave me in your last message and I got it working again. The previous commands I used to boot into SUM we're different than the ones you gave me. I fixed the issue though, so I appreciate the help and thanks so much John!

administrator changed to standard: cannot log in without details: single user mode fix does not work for me...

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.