Installing Packages through Recovery Mode

bashinstallrecoveryterminal

Alright so at this moment my Mac only boots in recovery mode and I need to install a package (.pkg) before attempting to reinstall the OS. The package is located on a usb drive named "Package".

I have been looking into several ways to do this but so far had no luck.

I tried running the installer command through terminal:

installer -pkg /Volumes/Package/FirmwareUpdate.pkg -target /

But got an error claiming the install failed because the installer can't create the folder "//Install.6733yhGK6"

I also tried directing the target to Applications as so:

installer -pkg /Volumes/Package/FirmwareUpdate.pkg -target /Applications/

But only get "Error trying to locate volume at /Applications/"

Can anyone help me?

Best Answer

I haven't tried installing a package from Recovery, so this might not be the entire solution, but I've spotted something for you to try differently:

When you're in recovery, / is the root of the Recovery volume, not your own Mac's volumes. Recovery volumes are read only and you can't install things to that, not that I think you're wanting to anyway.

In recovery, your normal volumes are mounted to folders within /Volumes/. List that folder (ls /Volumes) to see the names of the volumes that are mounted, and choose the correct volume for -target.