Macs getting stuck in boot loop

mconners
Valued Contributor

Hello Everyone,

Sporadically, we are seeing some of our Macs getting stuck in a boot loop. This manifests itself after the Mac has run some OS updates. In the latest case, the updates appear to be the security update 2018-001, iTunes, Safari updates. I have seen this before and I just don't understand what is causing this.

In all cases, disk utility doesn't find a problem. Reinstalling the OS doesn't remedy it either.

The only way we can recover from this is to wipe the drive and image it over.

Anyone else seeing this? If you have, do you have a fix or something else I can try? Very frustrating to have this occur and we have to backup the drive, wipe the internal drive, install the OS, applications and settings and recover from the backup.

Seems like something is amiss, I just don't know what it is.

21 REPLIES 21

jwojda
Valued Contributor II

have you looked at this?

howie_isaacks
Valued Contributor II

How are these Macs getting their software updates? It sounds like the update packages are getting corrupted. It's likely that the security update is the issue since iTunes and Safari don't require a reboot. I recently had a user with this problem. I booted her Mac off of an external boot drive, and I was able to go into the internal hard drive and remove the offending update files. After that, the system booted up normally.

mconners
Valued Contributor

Thank you for the quick responses @jwojda and @howie_isaacks. I do believe it is the security update.

As for us, we are simply issuing a command, software update -i -a and this has worked flawlessly in the past. I have not had any success with re-installing the OS. In all of our cases, we had to backup, reimage and restore to get the Mac back to booting.

Let me ask. We use a firmware password on all of our Macs. I wonder if this could be interfering in some way, doubtful, just curious if you are using firmware passwords too? We also have Avast installed. Perhaps Avast is interfering with things?

mconners
Valued Contributor

Hey @howie_isaacks when you mentioned, remove the offending files, how would you find those files? What folder would I look into for these? I believe it was the security update that did it, but I want to make sure where I would look for those files. Thanks again!!

Look
Valued Contributor III

We have had a few machines get stuck in an update loop.
The fix was to hold option on boot and manually select the boot drive again while holding control to set it as default (they were endlessly booting of an update image file, failing to update and rebooting of the image file again).
Re-applying the update afterwards worked fine as well so no idea as to the original cause, this was particularly bad with the 10.13.2 supplemental update.

milesleacy
Valued Contributor

If you encounter this after/during a macOS Mojave upgrade, resetting the SMC may help.

How to reset the System Management Controller (SMC) on your Mac

joshuaaclark
Contributor

We are also experiencing this. Our organization caches apple updates during the week. On Thursdays, we have a logout policy that triggers the installations. They have been failing lately causing the stuck boot loop.

nwagner
Contributor

Same here @joshuaaclark

We are still on 10.12.6 and installed the SecUpdate2019-001 update and now we have a bunch of machines that are bootlooping.

@howie_isaacks How did you fix the problem? I don't know what update files to remove? I've never had this happen before.

stevewood
Honored Contributor II
Honored Contributor II

@nwagner fix for us has been to simply boot into recovery and choose the startup disk. Might try the boot loader (option key during boot) to see if that works.

nwagner
Contributor

Thanks @stevewood I did try that.
Actually, I should probably state what I've already tried.
- Selecting the startup disk from option boot.
- Selecting the startup disk from recovery. - Safe Boot did not work at all.
- Single user boot does not work.
- SMC reset.
- PRAM reset.
- I booted into recovery and repaired the disk. - I tried deleting cache files, while in recovery.

And I've tried these various troubleshooting tactics on more than one machine. Usually, the user has to get back to work so we have to re-image the machine and get them back up and running. These boot loops happen on the old MacPro trashcans, MacBook Air, 2015 MacBook Pro's, 2017 MacBook Pro's, just the whole spectrum of hardware (i think there was even one MacBook).

We had one policy cached the update package (SecUpdate2019-001Sierra.pkg) on our users machines for roughly a week to try and catch everyone. Created a Smart Computer Group of machines that have the package cached. Scoped a separate policy to that smart group, then used the package payload to run "install cached". The policy does allow deferrals, because we can't place an undue burden on our users. It's set to run "once per computer" with "Check In" as the only trigger.

The best i've been able to do is get into recovery, and pull the complete /private/var/log folder to an external drive. I'm comparing those logs to logs from a machine that had no problem with this update process.

Some machines are super borked. One machine the JAMF admin user was just gone. On another machine we couldn't unlock the disk to mount it.

What drives me the most insane, is that we can't dependably reproduce the bootloops. Only ~300 machines got the security update, before we had to disable the policy and kill pending installs. I saw that about a 5% of those machines were bootlooping. We tried manually getting the bootloops, but only got like 1 in 3 machines to bootloop (and we kinda cheated on that cause we closed the laptop while the update was installing to force an error).

I can't tell if it's our methodology for installing the update, or if its just a random occurrence caused by the update itself.

Any suggestion or knowledge is welcome and appreciated.

Sorry for the wall of text.

Chris_Hafner
Valued Contributor II

@Look Has the solution that we used... mostly. We have also booted from an external drive and deleted the problem update files (Located at the root of the drive). I don't remember what they're called off the top of my head, but it's something super generic like "Installer Data" .

nwagner
Contributor

Thanks @Chris_Hafner I'm gonna try that.

nwagner
Contributor

I tried deleting what I thought were the offending files
.PKInstallSandboxManager-SystemSoftware
And there was something else that had 'install' in the label.

I also tried re-installing the security update while booted from an external drive.

Still no joy in mudville.

cburk2018
New Contributor II

Hey all,

Figured I'd throw my experience in on this topic.

While this may be related to a security patch, I'm finding in my environment it's related to the Jamf task for reboots, since I've got a policy to reboot some Macs twice a weekend and I've now seen the com.jamfsoftware.task.reboot.plist in /Library/LaunchDaemons in each of the accounts of this occurring.

The fix for this is simply to remove the com.jamfsoftware.task.* plists and reboot. Much faster than rebuilding, so maybe check that first? Just don't delete the jamf and management daemons!

Upon further digging, it appears that the com.jamfsoftware.task.reboot.plist might be calling a script that isn't present, as in the below screenshot. When I check the /Library/Application Support/JAMF/tmp/blah-numbers-blah, it references something that no longer exists (perhaps the reboot script itself?). 8440bc6d942f4353aeae19f52002cab2

bjiang
New Contributor

Per cburk2018's post. I deleted everything in /Library/LaunchDaemons

This helped stop the infinite restart loop. Thanks cburk2018

tcandela
Valued Contributor II

@bjiang glad i saw this post. I think im having this same issue. After a security update ive had 4 laptops go into what i been calling a login loop. The user logs in and the progress bar goes like 80% and then reboots and the process continues. The first couple times after booting into safe mode and rebooting into normal mode the issue was fixed.
The last 2 times its happened ive tried safe mode, repair disk, but issue not fixed, so i had to completely wipe and install everything fresh.
This login loop is happening to every account that is trying to login. Only 2 accounts are on each laptop.

Did you have this similar login loop issue?

You fixed it by deleting everything in /Library/LaunchDaemons?

Is this the main /Library/LaunchDaemons location that you deleted from? Or from the users ~/Library/LaunchDaemons ?

Did you also boot from an external drive to get to the computer drive?

NYBGIT
New Contributor III

to resolve the boot loop issue there is a plist in the LaunchDaemons that is causing the look. the command i use in recovery/terminal is "rm -rf com.jamfsoftware.task.reboot.plist." It seems Jamf does not remove this plist before triggering a reboot. This resolved my issue.

tcandela
Valued Contributor II

@NYBGIT did you remove it from here 'Library/LaunchDaemons'?

i call it 'login loop' because no matter who tries logging in it just brings the user back to login prompt after going about 80% through the progress bar.

This has happened to me on 4 laptops and twice it was resolved by booting into safe mode and then back into normal mode. The other 2 times i hade to wipe and freshly install everything again. If it happens again I'll try removing this com.jamfsoftware.task.reboot.plist

tcandela
Valued Contributor II

This happened to me again today.  Doing the boot into internet recovery then going to terminal and doing the rm -rf com.jamfsoftware..... stuff did not work.

what worked was booting into SAFE MODE and just like @bjiang  did I deleted everything in /Library/LaunchDaemons  then restarted into normal mode and i was able to get through to a successful login.

NYBGIT
New Contributor III

@tcandela rm -rf com.jamfsoftware.task.reboot.plist. - This file is located in the 'Library/LaunchDaemons' directory. There's no need to delete everything from that directory.

Sorry I should have been clear in my message. Once you cd to /Volumes/Macinstosh\ HD/Library/LaunchDeamons - execute this command "rm -rf com.jamfsoftware.task.reboot.plist." and reboot and everything should be fine. 

tcandela
Valued Contributor II

@bennyb  yep, i was thinking about just deleting the single  jamfsoftware entry in the LaunchDeamons but i just said to myself F*CK it i'm just deleting everything in it.

so happy it worked.  didn't want to lose what i had and re-install Big Sur