High Sierra: qmasterd/opendirectoryd: Too many corpses being created

Hi all, on our family white Macbook (2009), which used to work fine, we have since yesterday a spinning boot.


In verbose mode can be seen:


Waiting for DSMOS...

Process[187] crashed: qmasterd. Too many corpses being created.

Process[188] crashed: opendirectoryd. Too many corpses being created.


Disk tool first help and fsck are ok, I did not see errors in the details when I ran it.

I can also find thru the harddisk without issues at the recovery console.

So the filesystem is ok, and since it can boot in recovery mode, I assume hardware and filesystem are generally ok. Disk space is plenty.


Creating rc.server did not help. I reinstalled OS without a resulting change.

/var link also seems ok. I can change directories and ls in single-user mode, but not create files since mounted in read-only.

I removed the Mac from my WLAN (Fritzbox), so it cannot connect any more. No change.

I renamed the directores of the virus scanner as an attempt to isolate that. No change.


Attempts to start in safe mode are also unsuccessful. If anyone has a hint to start in safe mode with verbose, appreciated.


I don´t want to USB attach the disk to my other MPB to backup, and to later reformat/reinstall, without understanding the root cause of this.


I saw quite few other discussions on similar topics, without having found the right hint or solution.


Can you please help?


Many thanks / Stefan

VIN, MacBook (13-inch Late 2009), macOS High Sierra (10.13.2), Assume it is 10.13.2 - cannot check

Posted on Jan 10, 2018 9:14 AM

Reply
Question marked as Top-ranking reply

Posted on Feb 17, 2018 7:41 AM

This should solve the problem:

If you want to remove all users (without removing home folders)

If you suspect that the local database which stores user accounts is damaged, follow the steps for the version of OS X you're using below. These steps remove all user accounts without removing their related Home folders, and make Setup Assistant open again.


Start up in Single-User Mode by holding Command-S when you turn on the computer. Wait until white text appears.

At the prompt, type each of these commands on single line as they appear below, and press Return at the end of each line.


mount -uw /

cd /var/db

mv dslocal dslocal.old

mkdir -p dslocal/nodes

cp -Rp /System/Library/DirectoryServices/DefaultLocalDB/Default dslocal/nodes/

rm .AppleSetupDone

reboot


Once the computer restarts, complete Setup Assistant to create the administrator user account again. When creating the account, the short name entered into the Account Name field should match the name of the user's home folder in /Users, so that the new user will use the existing home folder.

After Setup Assistant, open Terminal and type this command:


sudo chown -R username:staff /Users/username


Note: There is a space before "/Users/". Replace "username" with the user's short name that was entered in Account Name field during the previous step.


If there was more than user on the computer, use the Accounts pane of System Preferences to re-create any remaining users. When creating each account, the short name entered into the Account Name field should match the name of that user's home folder in /Users, so that the new user will use the existing home folder.

42 replies
Question marked as Top-ranking reply

Feb 17, 2018 7:41 AM in response to kraemies

This should solve the problem:

If you want to remove all users (without removing home folders)

If you suspect that the local database which stores user accounts is damaged, follow the steps for the version of OS X you're using below. These steps remove all user accounts without removing their related Home folders, and make Setup Assistant open again.


Start up in Single-User Mode by holding Command-S when you turn on the computer. Wait until white text appears.

At the prompt, type each of these commands on single line as they appear below, and press Return at the end of each line.


mount -uw /

cd /var/db

mv dslocal dslocal.old

mkdir -p dslocal/nodes

cp -Rp /System/Library/DirectoryServices/DefaultLocalDB/Default dslocal/nodes/

rm .AppleSetupDone

reboot


Once the computer restarts, complete Setup Assistant to create the administrator user account again. When creating the account, the short name entered into the Account Name field should match the name of the user's home folder in /Users, so that the new user will use the existing home folder.

After Setup Assistant, open Terminal and type this command:


sudo chown -R username:staff /Users/username


Note: There is a space before "/Users/". Replace "username" with the user's short name that was entered in Account Name field during the previous step.


If there was more than user on the computer, use the Accounts pane of System Preferences to re-create any remaining users. When creating each account, the short name entered into the Account Name field should match the name of that user's home folder in /Users, so that the new user will use the existing home folder.

Feb 22, 2018 12:05 PM in response to masthax

No need to rant about the support forum! At least it provides a quick solution without data loss. Apple should be blamed for not fixing it or pubicize it on its websites.

See a solution to the issue from frankv or another similar from rew10000, also look at: http://capitoladesign.com/2018/02/10/osx-too-many-corpses-the-30-minute-fix-no-d ata-loss/

Here is probably the quickest solution from frankv:

If you want to remove all users (without removing home folders)

If you suspect that the local database which stores user accounts is damaged, follow the steps for the version of OS X you're using below. These steps remove all user accounts without removing their related Home folders, and make Setup Assistant open again.


Start up in Single-User Mode by holding Command-S when you turn on the computer. Wait until white text appears.

At the prompt, type each of these commands on single line as they appear below, and press Return at the end of each line.


mount -uw /

cd /var/db

mv dslocal dslocal.old

mkdir -p dslocal/nodes

cp -Rp /System/Library/DirectoryServices/DefaultLocalDB/Default dslocal/nodes/

rm .AppleSetupDone

reboot


Once the computer restarts, complete Setup Assistant to create the administrator user account again. When creating the account, the short name entered into the Account Name field should match the name of the user's home folder in /Users, so that the new user will use the existing home folder.

After Setup Assistant, open Terminal and type this command:


sudo chown -R username:staff /Users/username


Note: There is a space before "/Users/". Replace "username" with the user's short name that was entered in Account Name field during the previous step.


If there was more than user on the computer, use the Accounts pane of System Preferences to re-create any remaining users. When creating each account, the short name entered into the Account Name field should match the name of that user's home folder in /Users, so that the new user will use the existing home folder.

Feb 26, 2018 4:18 AM in response to GLaker33

There is a fix if this happens without data loss. It takes about 30min. Newer Macs are affected as well. The Apple Helpdesks should know about the solution and not have to spend 5h on it an d Apple should fix the issue.

See a solution to the issue from frankv or another similar from rew10000, also look at: http://capitoladesign.com/2018/02/10/osx-too-many-corpses-the-30-minute-fix-no-d ata-loss/

Here is probably the quickest solution from frankv:

If you want to remove all users (without removing home folders)

If you suspect that the local database which stores user accounts is damaged, follow the steps for the version of OS X you're using below. These steps remove all user accounts without removing their related Home folders, and make Setup Assistant open again.


Start up in Single-User Mode by holding Command-S when you turn on the computer. Wait until white text appears.

At the prompt, type each of these commands on single line as they appear below, and press Return at the end of each line.


mount -uw /

cd /var/db

mv dslocal dslocal.old

mkdir -p dslocal/nodes

cp -Rp /System/Library/DirectoryServices/DefaultLocalDB/Default dslocal/nodes/

rm .AppleSetupDone

reboot


Once the computer restarts, complete Setup Assistant to create the administrator user account again. When creating the account, the short name entered into the Account Name field should match the name of the user's home folder in /Users, so that the new user will use the existing home folder.

After Setup Assistant, open Terminal and type this command:


sudo chown -R username:staff /Users/username


Note: There is a space before "/Users/". Replace "username" with the user's short name that was entered in Account Name field during the previous step.


If there was more than user on the computer, use the Accounts pane of System Preferences to re-create any remaining users. When creating each account, the short name entered into the Account Name field should match the name of that user's home folder in /Users, so that the new user will use the existing home folder.

Apr 28, 2018 1:20 PM in response to kraemies

I'm a very experienced Mac tech support consultant, yet I've been grappling with the "too many corpses" problem since yesterday. I tried a number of approaches, but was confident that a simple solution existed. YOU MAY NOT HAVE TO ERASE YOUR HARD DRIVE, or reinstall Mac OS. I found a couple of postings that explain this surprisingly quick solution. If you're able to get into Recovery Mode utilizing CMD-R, and you're not afraid to work in the Terminal program, THIS WORKS! If you follow these steps EXACTLY, a bad file named "mbr_cache" will be rebuilt and your Mac will reboot successfully (slowly the first time as the rebuild happens, then normal speed after that). This solution worked on my 2011-vintage 21-inch iMac (iMac 12,1) with Mac OS High Sierra. Someone should tell the Apple Geniuses and Tech Support Specialists about this. Or, better yet, they should be able to find these types of solutions themselves. Good luck!

The two articles where I found this solution are:

macos - Opendirectoryd too many corpses being created - Ask Different

https://mrsystems.co.uk/blogs/news/too-many-corpses-being-created


Steps from the articles:

  1. Boot and hold CMD-R to start up from macOS Recovery
  2. If Filevault is on, mount the disk with Disk Utility and enter password
  3. Enter these two commands in Terminal
  4. cd /Volumes/Macintosh\ HD/var/db/caches/opendirectory
  5. mv ./mbr_cache ./mbr_cache-old
  6. Exit from Terminal
  7. Restart the computer

Feb 13, 2018 6:25 AM in response to Stephan Graf

In case it helps anyone else, here's how I resolved the issue of a stuck progress bar on boot after 10.13.3 update, without wiping drive or losing data. (Based on a fusion of several of the links above). My Time Machine backup was stale and configured weirdly, so I wanted to avoid going back to that. I also didn't want to wipe the hard drive if I didn't have to.


1. Hold down power button to shut down

2. Boot in verbose mode (hold down ⌘V, press power)

3. Confirmed that boot gets stuck with repeated "too many corpses being created" messages

4. Hold down power button to shut down

5. Boot in recovery mode (About macOS Recovery - Apple Support)

6. [Optional] From Recovery mode, Saved a backup image of Macintosh HD to an external drive using Disk Utility

7. From Recovery mode, using terminal, renamed all folders at the root level of Macintosh HD, except those with data I wanted to preserve, i.e. "Applications" and "Users"

cd /Volumes/Macintosh\ HD

ls -al (to see what's there)

mv System _System

mv Library _Library

...

I didn't bother renaming the files at the root level.

8. From Recovery mode, selected Reinstall macOS and installed on "Macintosh HD"

9. When asked to create a user, ensured that the short name (account name) matched my existing account name so that this user "inherits" the existing files in "Users".

10. Back in business! (I guess I'll go in and delete the old OS folders using terminal).

Apr 5, 2018 8:47 PM in response to kraemies

let's try this one on for size. the error tells us the problem is related to opendirectory(d), which appears to be cache related.


using your method of choice, let's remove the file that (hopefully) is the cause of the issues.


/StartupDisk/var/db/caches/opendirectory/mbr_cache


you could use terminal from the recovery partition, boot the problematic OS in single user mode, or do it all from a different OS if you happen to have one of those handy.


Good luck!

May 23, 2018 8:06 AM in response to kraemies

I had the same problem. I tried all of the fixes mentioned here and none of them worked for me. I tried FirstAid and reinstalling macOS and I got a message that it couldn’t find my server. I found this solution through a google search and it worked for me. When my laptop restarted, it went to the sign-in page. I entered my password and after a few minutes, Set-up started. I went through set-up, and when it finished, all of my files were there. Nothing was lost. I hope this helps someone else.

https://mrsystems.co.uk/blogs/news/too-many-corpses-being-created


By the way, I called Apple support and they got me into Terminal but I kept getting a message saying there was no server found (or something to that effect.). They said they couldn’t do anything beyond that and set up an appointment for me at the Apple store. When I did what was suggested in the link above for my hard drive name and just typed “Ma” for Macintosh and then hit “tab”, it filled in my hard drive name. Then the commands typed into Terminal worked.

Feb 2, 2018 1:48 PM in response to kraemies

I have had the same problem twice in the last four months and have tried everything you have. The only way I have been able to correct this problem is to keep a flash pen with a installation of as in my case High Sierra on it. All I do at present is to run the Mac from the flash pen which updates the current system correcting the error. I can then run system checks using a few programs but have never found anything wrong and then running Apple Updates to make sure everything is up to date before backing up with Time Machine to a external hard drive.

Feb 3, 2018 12:16 PM in response to kraemies

I confirm John Galt's post.


The solution for mine was to erase the disk and reinstall the OS. It did not work to reinstall the OS without erasing the disk. I also tried many simpler suggestions found in the web, but nothing worked. As I had a backup made using Time Machine, I did not lost data. But I lost MANY hours of work: looking for solutions and downloading the time machine (many hours to recover the backup...).

Feb 3, 2018 3:16 PM in response to Beauvoir17

I offer this that you all might want to have a look at.

I have always said the best way of updating is from a freshly formatted disk. As it seems updating is not removing old kext files

After a little more research I came across an article by Justin Silver (link below) that suggest a solution by removing out of date extension kexts in the System/Library/Extensions.

After looking at my own extensions I notices three extensions; two had old extension dates; two seemed to be duplicates with the usual added figure added to its name.

User uploaded file

One file had a date of 2016 and the other 2017 and two files are duplicates (last three files on pictured list).

I have since removed the two out of date files and now wait to see if I have any further corpse issues.


https://www.justinsilver.com/technology/os-x-el-capitan-10-11-1-hanging-on-boot- fixed/

Jan 13, 2018 12:48 PM in response to kraemies

I wish I knew what caused that lugubrious message. It's not very common. Other than the few reports I cited I know of no others, and at least one of them was reportedly solved by erasing the disk and reinstalling macOS. Presumably that was a permanent fix.


That's not as drastic a solution as it might seem, as long as you create a backup first (Time Machine or the equivalent).

Feb 28, 2018 8:02 AM in response to gabriele1973

Glad it worked for you.


To delete the old system folders, I booted into Recovery and used rm in terminal. (They're protected by System Integrity Protection About System Integrity Protection on your Mac - Apple Support but this isn't enforced in Recovery mode).


Be careful! Some of the folders are actually symbolic links (e.g. /etc links to /private/etc) so you should be sure you are removing the obsolete link and not the contents of the linked folder. In this case, I believe that rm -rf /etc would just remove the link but rm -rf /etc/ [with trailing slash] would remove the contents of /private/etc as well.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

High Sierra: qmasterd/opendirectoryd: Too many corpses being created

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