Only guest user showing .main account not showing

I have retina Mac 27inch 5k 2017 model.while i tried to copy larger files from my phone to imac it went to sleep mode and after that my password dint work for login again.then i tried restarting the imac,only guest user shows.now im unable to get my main user account.only guest user showing .pls help

Posted on Dec 12, 2025 10:25 PM

Reply
Question marked as Top-ranking reply

Posted on Dec 14, 2025 10:48 PM

19 replies

Dec 14, 2025 2:15 PM in response to gowtham251

Your big problem is you only have about 2.43GB of Free storage space as of the picture of Disk Utility First Aid. With the macOS Extended file system bad things happen when it runs out of Free storage space.....it can corrupt the files on the drive and other problems. It is also interesting that the First Aid portion you pictured, shows it resizing the Core Storage Logic Volume......that is bad and indicates a bigger problem with this volume/drive.


Try running First Aid on the Fusion Drive item.

I wonder if the Hard Drive portion of the Fusion Drive is failing.


See if you can create a new macOS admin user account using these instructions:


If you don't have another macOS admin user account, then you will need to trick macOS into running Setup Assistant again. This will involve using the command line. These particular instructions will only work on macOS up until about macOS 10.14 Mojave....different instructions are needed for macOS 10.15 to 13.x.....it is impossible to do this with macOS 14.x+.


You can do this by booting into Single User Mode by holding the Command + S keys just after powering on the computer & hearing the startup chime (hold it immediately after the chime...it may not work holding it sooner). Then at the command prompt enter the following commands making sure to press the "Return" key at the end of each line to execute each command:



fsck  -fy
mount  -uw  /
rm  -i  /var/db/.AppleSetupDone
reboot


If all these commands complete without any errors when you reboot the computer Setup Assistant should run where you can create a new admin user account. Report back here afterwards before doing anything else.


*****


If you can at least boot into macOS with an admin user account, then we have some more options available to attempt to understand what is happening here.


Do you have a good backup of this system? If not, then you that is a high priority. The easiest method may be to install a full version of macOS onto an external USB3 SSD & booting from that external drive. This would make it easier to backup of the data if needed and to try to troubleshoot a few things as well. It also gives you the option to perform a clean install. If the internal Hard Drive portion of the Fusion Drive is failing, then you will need to boot from an external USB3 SSD if you want to continue using this iMac anyway.


Dec 13, 2025 7:48 AM in response to D.I. Johnson

Follow up:


And I hope I'm not too tardy with this suggestion,

Before you boot into recovery to reinstall the OS, try booting your Mac in safe mode and see if you get the proper options for user login.


Safe mode will often correct weird software behavior by forcing the OS to clear caches, do disk repair and other self-maintenance and housekeeping and temporarily disables third-party mods.

How to use safe mode on your Mac - Apple Support 


You can exit safe mode by restarting your Mac normally, then reevaluate the problem.


Dec 14, 2025 7:21 PM in response to gowtham251

I see that our colleague @HWTech has spotted a very important detail that I missed.

Your drive appears to have only 2.43 GB available space.

It appears that there is simply not enough free space for the OS to run the Mac properly.


They have suggested that you use an external USB-3 SSD with a compatible macOS installed to boot your Mac, copy files and continue to troubleshoot the problem with the internal drive. I agree with them.


To do that you're going to need access to another Mac, released between 2017 and 2023, that can run a macOS between 10.12 Sierra and OS 13 Ventura.

If you have access to such a Mac and an external drive please let us know and we can guide you in installing macOS on that. Maybe you know someone else with an iMac, Mac mini or MacBook that falls in that range?


At this point I would not spend any more time trying to boot this iMac. Until you can access the drive and relocate a good chunk of the files that are on it you're going to be stuck.


The only option to booting from an external drive that I see is to erase your internal drive and then reinstall macOS. The problem with that is you erase all your files, and you still have the trouble contacting the server to download and install High Sierra.

Dec 14, 2025 9:58 PM in response to gowtham251

gowtham251 wrote:

2.I do not want to delete all the files,since I have important files in my main user account .

That is important & critical information since it does severely limit your options here.


3.Before posting in this community ,I tried command + r + shift key hard browser login and there I don't see" could not contact the recovery server " error .but got the error that storage is less to install Mac .is there any other ways to delete the part of the files at this stage to free up space using terminal ? .Or any other methods .

If your login user is not visible, then your files may not be visible either. We have no idea what has caused this situation, or the extent of the issue. When you need to recover critical files, then things get really complicated since you must proceed with extreme caution. First rule of data recovery is not to modify the drive containing the missing or inaccessible files or you risk destroying them.


4.
fsck -fy
mount -uw /
rm -i /var/db/.AppleSetupDone
reboot
What these commands will do ? .@HW tech asked me to do this.still I dint try this

It runs a file system check so that you can then remount the root file system as Read+Write (it is read only until then). The "rm" line deletes a macOS file which tells macOS that Setup Assistant has already been run & is no longer needed......in your case with no current macOS admin users you need Setup Assistant to run again when you reboot the system.


Since data recovery of critical files is necessary, that makes using that step to create a new macOS admin user account very risky since we have no idea what has occurred on your system to cause this problem(s). Plus with so little Free storage space, creating a new user account risks ending up with no space (less of a problem when a clean install was an option).


I think the next best step is to assess the health of the internal drives since you have critical files you need to recover. The safest way to do this is by using a bootable Knoppix USB stick. See my post here on how to create & use a Knoppix USB stick to check the health of the drives:

Create & Use a Bootable Knoppix USB Stick -- post by @HWTech - Apple Community


Once we confirm the health of the internal drives, it will make it easier to choose your next option. After thinking about things, I don't think it is a good idea at this point to even install macOS to an external SSD since you have critical files to recover and the default behavior of macOS may not be conducive to preserving the integrity of your internal Fusion Drive. I'm concerned Spotlight may default to indexing the Fusion Drive.


After your critical files are recovered, then & only then can we can proceed with various options to attempt to fix the system.


Dec 15, 2025 6:59 AM in response to gowtham251

  1. Yes, check with friends.
  2. I understand. You have important files on the drive that you did not back up. If you had a backup, then the fix here is easy - erase the drive and reinstall macOS.
  3. Yes, shift-command-R may offer a different OS version to reinstall, but no installation can take place when there is no space available on the internal drive. I don't know if even Terminal commands can delete files if there is no room for the OS to operate properly. As I posted previously, you can access the internal drive by booting from an external that has macOS installed or you might boot you Mac in target disk mode and access the files from another connected Mac.
  4. The commands provided by @HWTech will run a file system check (fsck) and attempt to fix directory problems. It's more or less the Terminal equivalent of Disk Utility First Aid. The mount command and rm command will access the drive and remove the AppleSetupDone file so that the Mac might run the initial setup program and let you create a new admin user. Unfortunately this won't fix the problem of lack of storage space.


If you can neither use an external SSD to boot your iMac nor access the iMac in target disk mode, then the only way to resolve this problem is to wipe the drive and reinstall macOS, probably from a bootable USB installer.



EDIT - I just saw that @HWTech has also addressed these points. I'm going to get more coffeee now.

Dec 13, 2025 7:41 AM in response to gowtham251

That 2017 iMac can run any version of macOS between 10.12 Sierra and macOS 13 Ventura.

Which OS is it running?


You were able to reboot the Mac in recovery mode to run the Disk Utility First Aid, yes?

If so, do so again and select "Reinstall macOS..." there on the main recovery screen. This process will simply lay a new copy of the existing OS on the startup drive, replacing any damaged or missing OS files. It should not affect your user files.

Dec 13, 2025 8:34 AM in response to gowtham251

gowtham251 wrote:
[...]
i tried reinstall mac os in recovery mode,it shows error "recovery server cannot be contacted "

This is a common occurrence with High Sierra downloads for some time, now, and Apple don't appear willing to put any effort into resolving the situation. You might find help for it here: https://mrmacintosh.com/how-to-fix-the-recovery-server-could-not-be-contacted-error-high-sierra-recovery-is-still-online-but-broken/

Look specifically at Fix #3.


Otherwise there are options for installing a macOS version newer than High Sierra.


Do you have backups of your data?


Dec 14, 2025 7:36 AM in response to gowtham251

You can set the date and time using the Terminal app when booted in recovery mode.

For example, this command:


sudo date 1214081025


– sets the time and date to Dec 14th, 08:10 a.m., 2025.

Adjust your input to match your current date and time.



You said previously that Disk Utility First Aid routine was not working.

Please tell us what happens when you run First Aid. Please post a pic of the screen results if you can.

Dec 14, 2025 9:27 PM in response to gowtham251

gowtham251 wrote:

Sir this is what I get if I run first aid for fusion drive .what shall I do next ?
https://discussions.apple.com/content/attachment/2dba1c03-5e81-4199-b187-f87606330a4e
https://discussions.apple.com/content/attachment/d9f0749f-943e-451e-9609-b000f3ae5d51


Unfortunately we are only seeing the final part of the First Aid report.....that window can be made larger. Perhaps the earlier portion will provide some other details.


Dec 14, 2025 8:51 PM in response to gowtham251

gowtham251 wrote:

Sir this is what I get for date time correction command .pls help
https://discussions.apple.com/content/attachment/49ad5351-5ffe-46a8-9aca-aa450a233a89

You cannot use "sudo" when you are already a root user indicated by the "#" prompt. Remove the "sudo " portion of the command.


Unless you are planning to perform a clean install of macOS High Sierra (to the internal drive or external), forget it since the internal drive doesn't currently have enough Free space. A clean install is when you first erase the destination drive, destroying all data on it.

Dec 14, 2025 9:12 PM in response to D.I. Johnson

Sir,


1.I do not have any other mac .I need to check on that with friends.


2.I do not want to delete all the files,since I have important files in my main user account .


3.Before posting in this community ,I tried command + r + shift key hard browser login and there I don't see" could not contact the recovery server " error .but got the error that storage is less to install Mac .is there any other ways to delete the part of the files at this stage to free up space using terminal ? .Or any other methods .


4.

fsck -fy

mount -uw /

rm -i /var/db/.AppleSetupDone

reboot

What these commands will do ? .@HW tech asked me to do this.still I dint try this




Only guest user showing .main account not showing

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