Monday, 2 December 2019

How to create a bootable installer for macOS

How to create a bootable installer for macOS

You can use an external drive or secondary volume as a startup disk from which to install the Mac operating system.
These advanced steps are primarily for system administrators and others who are familiar with the command line. You don't need a bootable installer to install macOS, but it can be useful when you want to install on multiple computers without downloading the installer each time. 

Download macOS

Download a macOS installer.* You can find the appropriate download link in the upgrade instructions for macOS CatalinamacOS MojavemacOS High SierramacOS Sierra, and OS X El Capitan.
  • If the macOS installer opens after downloading, quit it without continuing installation. 
  • macOS Sierra and El Capitan download as a disk image that contains an installer named InstallOS.pkg or InstallMacOSX.pkg. Run this installer before continuing.
  • If downloading macOS Catalina, macOS Mojave, or macOS High Sierra for the purpose of creating a bootable installer, your Mac must be using macOS Sierra 10.12.5 or later, or El Capitan 10.11.6. Enterprise administrators, please download from Apple, not a locally hosted software-update server.
Then find the installer in your Applications folder as a single ”Install” file, such as Install macOS Catalina.

Use the 'createinstallmedia' command in Terminal

  1. Connect the USB flash drive or other volume you're using for the bootable installer. Make sure that it has at least 12GB of available storage and is formatted as Mac OS Extended.
  2. Open Terminal, which is in the Utilities folder of your Applications folder.
  3. Type or paste one of the following commands in Terminal. These assume that the installer is still in your Applications folder, and MyVolume is the name of the USB flash drive or other volume you're using. If it has a different name, replace MyVolume in these commands with the name of your volume.

    Catalina:*
    sudo /Applications/Install\ macOS\ Catalina.app/Contents/Resources/createinstallmedia --volume /Volumes/MyVolume
    

    Mojave:*
    sudo /Applications/Install\ macOS\ Mojave.app/Contents/Resources/createinstallmedia --volume /Volumes/MyVolume
    

    High Sierra:*
    sudo /Applications/Install\ macOS\ High\ Sierra.app/Contents/Resources/createinstallmedia --volume /Volumes/MyVolume
    

    Sierra:
    sudo /Applications/Install\ macOS\ Sierra.app/Contents/Resources/createinstallmedia --volume /Volumes/MyVolume --applicationpath /Applications/Install\ macOS\ Sierra.app
    

    El Capitan:
    sudo /Applications/Install\ OS\ X\ El\ Capitan.app/Contents/Resources/createinstallmedia --volume /Volumes/MyVolume --applicationpath /Applications/Install\ OS\ X\ El\ Capitan.app
    
  4. Press Return after typing the command.
  5. When prompted, type your administrator password and press Return again. Terminal doesn't show any characters as you type your password.
  6. When prompted, type Y to confirm that you want to erase the volume, then press Return. Terminal shows the progress as the bootable installer is created.  
  7. When Terminal says that it's done, the volume will have the same name as the installer you downloaded, such as Install macOS Mojave. You can now quit Terminal and eject the volume.
* If your Mac is using macOS Sierra or earlier, include the --applicationpath argument, similar to the way this argument is used in the commands for Sierra and El Capitan.

Use the bootable installer

After creating the bootable installer, follow these steps to use it.
  1. Connect the bootable installer to a compatible Mac. 
  2. Use Startup Manager or Startup Disk preferences to select the bootable installer as the startup disk, then start up from it. Your Mac will start up to macOS Recovery.
    Learn about selecting a startup disk, including what to do if your Mac doesn't start up from it.
  3. Choose your language, if prompted.
  4. A bootable installer doesn't download macOS from the Internet, but it does require the Internet to get information specific to your Mac model, such as firmware updates. If you need to connect to a Wi-Fi network, use the Wi-Fi menu  in the menu bar. 
  5. Select Install macOS (or Install OS X) from the Utilities window, then click Continue and follow the onscreen instructions.

How to Clean Install macOS / OS X Without a USB Drive

Here's how you can clean install macOS or OS X on your iMac, MacBook, MacBook Pro without bootable USB drive, external storage medium.

Clean Install macOS / OS X Over the Air, Completely Untethered - All You Need is an Internet Connection

When it comes to installing a fresh copy of macOS or OS X, we immediately divert our minds toward a bootable USB drive from which we will take things off. But really, you don't have to follow the traditional way in order to do a clean installation of Apple's desktop operating system onto your Mac. Everything can be done over the air, completely untethered, and all you need to have at hand is a fast working Internet connection.
But why would you want to take the untethered route? There are a lot of reasons behind it, but I'll focus on only three.
  • A USB drive isn't available at all times for everyone.
  • Internet speeds are fast enough to get things done at a quick pace.
  • You don't have a dongle to connect your USB drive with your (new) Mac.

Tutorial

Before you go ahead with the installation it's worth mentioning here that you will lose your files, therefore make a backup of everything on an external USB drive or iCloud before proceeding. All set? Let's jump into the installation process.
1. Restart your Mac, or power it on, while holding down the Command + R key combination.
2. Release the Command + R key combination once you see the Apple logo on display. In a few short seconds, you'll boot straight into Recovery.
3. Once you see a window like the one below, click on Disk Utility and Erase your main Mac HDD (or SSD). Make sure it's the drive on which you want to install macOS or OS X on.
4. Once the disk is done erasing, close the Disk Utility window. You'll be taken back to the main Utilities page.
5. At this point connect your Mac to a WiFi network by clicking on the WiFi button in the menu bar. Select the network you wish to connect to and enter its password. If you have a the option to connect to the Internet using an Ethernet cable, then you can take that route as well.
6. In Utilities, click on Reinstall macOS or Reinstall OS X.
7. Follow the on-screen prompts for installation and make sure you choose the drive you erased in step 3. This is the target drive where macOS / OS X will boot off from.
8. The process will now begin, but Recovery will first download macOS or OS X from Apple's servers before the actually installation takes place. This may take a while depending on the speed of your Internet connection. It can take as little as twenty minutes all the way up to a few hours.
Once you are done, simply set up macOS or OS X as you normally would.