Reinstall macOS Mojave fails

Hi,


I'm trying to recover MacBook Pro 2018 model using recovery mode. Recovery offers an option to reinstall macOS Mojave into the computer. When I try to install the OS, it hangs when 2 minutes is left of the installation and finally fails with following error message:


"The file couldn't be opened because it isn't in the correct format.
The file might be corrupted, truncated, or in an unexpected format."


Here's an image (sorry, I had to take it with phone, I wasn't able to screenshot it):


Here's the recovery log. I have made it shorter by removing repeating lines:



There are multiple instances of errors like these:


Jan 18 09:02:05 MacBook-Pro osinstallersetupd[603]: IFJS: Package Authoring Error: access to path "/private/var/db/gkopaque.bundle" requires <options allow-external-scripts='true'>


Jan 18 09:40:37 MacBook-Pro osinstallersetupd[603]: PackageKit: Failed to verify InstallESDDmg.pkg: xar_verify failed


I've tried downloading the same files as installer with cURL in recovery terminal and there has been no problems.


Any suggestions what I should try? Bootable USB is not an option because the Startup Security Utility prevents booting from external media and the computer does not have an administrator account.

Posted on Jan 18, 2021 5:00 AM

Reply

Similar questions

10 replies

Feb 8, 2021 11:25 PM in response to Eau Rouge

It had produced error messages when opening programs and while running them for some time. I started suspecting hardware issues when every attempt at reinstalling the OS failed. I tried Big Sur, Catalina and Mojave. Tried regulard recovery, internet recovery & bootable USB. Bootable USB didn't work due to Startup Security Utility. Other recovery modes failed to verify downloaded OS packages (or that's how I interpreted the recovery log). When I could not figure out any other way of restoring it, I took it to the shop. Luckily the warranty still applied.

Feb 8, 2021 4:14 PM in response to latape

Is your data backed up?


If it isn't backup, backup your data first to two different places.


Then use Internet recovery, command-option-shift-R to recover Mojave after reformatting the hard drive with Disk Utility.


The problem is, you can't install Mojave on top of Catalina or Big Sur. The drive must be wiped, or a partition large enough must be set aside.


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.

Reinstall macOS Mojave fails

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