Lesson 3. Use macOS Recovery


Goals

Image Access the utilities available in macOS Recovery

Image Reinstall macOS from macOS Recovery

Image Create an external macOS Recovery Disk


From a troubleshooting viewpoint, one of the most useful macOS features is macOS Recovery. Via macOS Recovery, you can not only reinstall macOS but also access a variety of administration and troubleshooting utilities. macOS Recovery is, by default, located on the primary system disk. This allows easy access to recovery utilities without the need for additional media.

In this lesson, you will learn how to access macOS Recovery both on new Mac computers that came with macOS preinstalled and on computers that have been upgraded to macOS Sierra. You will also briefly explore the utilities available from macOS Recovery. As long as you don’t make any permanent changes using the utilities in macOS Recovery, you can safely explore without damaging your primary macOS system. Finally, you will learn how to create an external macOS install disk that can be used in cases where local macOS Recovery isn’t available.

Reference 3.1 Start Up from macOS Recovery

Mac computers running macOS Sierra, including both computers that shipped with macOS Sierra and upgraded computers, include a hidden macOS Recovery system on the local system disk. This hidden partition, dubbed Recovery HD, does not appear when a Mac is running macOS. The Recovery HD partition is automatically created during macOS installation from the last 650 MB or so of the system volume.


More Info

You can verify the existence of the Recovery HD partition by examining the internal disk using the System Information application. This is detailed further in Lesson 9, “Manage File Systems and Storage.”


To start up from macOS Recovery on the local system disk, simply restart the computer while holding down Command-R. In most cases, once macOS Recovery fully starts, the macOS Utilities window appears. From there you can install (or reinstall) macOS and choose from a variety of maintenance applications. If, however, the macOS Installer appears, you can continue with the installation if you need to, or quit the Installer (using the Command-Q keyboard shortcut) to return to the macOS Utilities window.

If for some reason macOS Recovery doesn’t start or isn’t installed on the local system disk, you have three alternatives for accessing it:

Image If you have a Mac model released in mid-2010 or later—If your Mac has the latest firmware updates, it can access macOS Internet Recovery. If the local Recovery HD partition is missing, late-model Mac computers should automatically attempt to access macOS Internet Recovery. You can also force a system to start up to macOS Internet Recovery by holding down Command-Option-R. When you do this, your Mac tries to redownload macOS Recovery from Apple servers. If successful, this process re-creates the local Recovery HD partition.


More Info

For more about using macOS Internet Recovery, see Apple Support article HT201314, “About macOS Recovery,” and article HT202313, “Computers that can be upgraded to use OS X Internet Recovery.”


Image If you have an external macOS Recovery Disk—Connect the Recovery Disk to your Mac, and restart while holding down the Option key. This opens Startup Manager, where you can use the arrow and Return keys or the mouse or trackpad to select the external macOS Recovery Disk. The default name for an external macOS Recovery Disk created using the methods outlined in this lesson is “Install macOS Sierra.” Reference 3.3, “Create a macOS Recovery Disk,” and Exercise 3.2, “Create a macOS Install Disk,” cover creating this disk in greater detail.

Image If you have a local Time Machine backup disk—The Time Machine backup service automatically creates a hidden macOS Recovery partition on local backup disks. To access macOS Recovery, connect the Time Machine backup disk to your Mac and restart while holding down the Option key. This opens the Mac computer’s Startup Manager, where (as earlier) you can use the arrow and Return keys or the mouse or trackpad to select the Time Machine backup disk. Lesson 15, “Manage Time Machine,” covers this topic in greater detail.


Note

If the Time Machine backup disk is encrypted, you need to enter the disk encryption password to successfully start up macOS Recovery. This password is unique to the encrypted backup disk and is not associated with or synchronized to any user account passwords. Again, Lesson 15, “Manage Time Machine,” covers this topic in greater detail.


Reference 3.2 About macOS Recovery Utilities

When you start up from macOS Recovery, you have access to several system administration and maintenance tools. The recovery system even has a few utilities you cannot find anywhere else in macOS. Again, in most cases, when you first start macOS Recovery you see the macOS Utilities window.

Image

When a Mac is started up from macOS Recovery, Ethernet and Wi-Fi networking are available if the network provides DHCP services. Ethernet is automatically enabled if the Mac is physically connected to the network. If a Wi-Fi network isn’t automatically connected, you can select one from the Wi-Fi menu item.


Note

If manual network setup is required during use of macOS Recovery, refer to instructions in Apple Support article HT200168, “Using Lion Recovery when no DHCP service is available.”



Note

While running from macOS Recovery, if the Mac computer’s system disk is protected by FileVault, any access to this disk first requires that you unlock the disk. In most cases, any local user’s password on the system will unlock the system FileVault disk. Lesson 10, “Manage FileVault,” covers this topic in greater detail.


From the macOS Utilities window in macOS Recovery, you can access the following functions:

Image Restore From Time Machine Backup—Use this option to restore a full Mac Time Machine backup from either a network or a locally connected disk. Lesson 15, “Manage Time Machine,” covers this topic in greater detail.

Image Install macOS or Reinstall macOS—As the name implies, this option opens the macOS installer. If you are running from a macOS install disk, the disk contains all the macOS installation assets. However, the local hidden Recovery HD does not contain the installation assets and thus requires Internet access to reinstall macOS. Further, the macOS installer must verify that the user is allowed access to the macOS Sierra assets. On older Mac computers that have been upgraded to macOS Sierra, you must verify the installation by providing the Apple ID used to purchase macOS. For Mac computers that shipped with macOS Sierra, this verification is automatic. Lesson 1, “Install macOS Sierra,” covers this topic in greater detail.

Image Get Help Online—This option opens Safari, taking you directly to the Apple Support website.

Image Disk Utility—This application handles storage-related administration and maintenance. It is especially useful when the Mac has started up from macOS Recovery, because Disk Utility can be used to manage a system disk that otherwise can’t be managed when in use as the startup disk. Specifically, Disk Utility can be used to prepare a disk for a new installation of macOS or to attempt repairs on a disk that fails installation. Lesson 9, “Manage File Systems and Storage,” covers this topic in greater detail.

Image Startup Disk (by clicking the close button or quitting)—If you attempt to quit the macOS Utilities window, you will see a prompt to start the Startup Disk utility. From this utility you can select the default system startup disk. The default startup disk can be overridden using any of the alternative startup modes discussed in Lesson 26, “Troubleshoot Startup and System Issues.”

Image

Wait, there’s more! macOS Recovery has a few extra features tucked away in the Utilities menu at the top of the screen:

Image

Image Firmware Password Utility—This utility allows you to secure the Mac computer’s startup process by disabling all alternate startup modes without a password. You can disable or enable this feature and define the required password. Learn more about firmware passwords in Lesson 8, “Manage Password Changes.”

Image Network Utility—This is the main network and Internet troubleshooting utility in macOS. Its primary use in macOS Recovery is to troubleshoot any network issues that could prevent the download of macOS installation assets. Network Utility is further discussed in Lesson 21, “Troubleshoot Network Issues.”

Image Terminal—This is your primary interface to the UNIX command-line environment of macOS. The most useful command you can enter from here is resetpassword followed by pressing the Return key.

Image Reset Password assistant opened via Terminal—This utility allows you to reset the password of any local user account, including the root user’s, on a selected system disk. Obviously, this utility can pose a serious security threat, and consequently it can be run only from macOS Recovery. Further, it’s hidden from plain view—you can only open it by entering the resetpassword command in Terminal. You can find out more about the Reset Password assistant in Lesson 8, “Manage Password Changes.”


Note

The utilities available from macOS Recovery can certainly be used to compromise system security. Then again, any system whose default startup disk can be overridden during startup is wide open to compromise. Therefore, in secured environments, it’s often necessary to use the Firmware Password Utility to help protect your systems, as covered in Lesson 8, “Manage Password Changes.”


Reference 3.3 Create a macOS Recovery Disk

In some cases, a Mac with macOS installed does not have a local Recovery HD. For example, if you just replaced the internal disk with a new disk, nothing will be on the new disk. Also, macOS systems on RAID (Redundant Array of Independent Disks) sets and disks with nonstandard Boot Camp partitioning will not have a local Recovery HD. In these cases, you would need to start up from an external Recovery Disk. Also, having an external Recovery Disk handy can be a real lifesaver should you come across a Mac with a dysfunctional system disk.


Note

When creating your own macOS Recovery Disks, be sure to keep track of the specific version of macOS you are using. As covered in Lesson 1, “Install macOS Sierra,” newer Mac computers do not support older versions of macOS and may require computer-specific builds of macOS. Thus, you should always keep your macOS Recovery Disk updated to the latest version of macOS available from the Mac App Store.


macOS Sierra includes a do-it-yourself solution to convert a standard disk into a macOS Recovery Disk. This method involves using a special command-line tool, named createinstallmedia, found in the Install macOS Sierra application. This tool copies both a macOS Recovery system and the full macOS installation assets to an external disk. Consequently, this method requires a disk of at least 8 GB, which is a common size for a small USB flash drive. Exercise 3.2, “Create a macOS Install Disk,” outlines the steps necessary to create this type of disk.


Note

It’s not recommended to use the legacy Recovery Disk Assistant method to create external macOS Recovery Disks for macOS Sierra.


Exercise 3.1 Use macOS Recovery


Image Prerequisite

Image Your computer must have a local hidden Recovery HD partition. This partition is normally created by the macOS Sierra installation process.


In this exercise, you will start up your computer in macOS Recovery. macOS Recovery is stored on a hidden partition named Recovery HD that is created automatically when macOS is installed on the hard disk. You will review the included utilities and how macOS Recovery can reinstall the system.


Note

You will not perform an installation, but you will get an opportunity to look at the steps leading up to the installation.


Start Up Using macOS Recovery

To access the installer and other utilities in macOS Recovery, you need to start up from the hidden Recovery HD partition.

1 If your computer is on, shut it down by choosing Shut Down from the Apple menu.

2 Press the power button on your computer, and then hold down Command-R until the Apple logo appears on the screen.

When you hold down Command-R during startup, the computer attempts to start up using a recovery partition on the hard disk.

If no recovery partition is available, Mac computers with newer firmware can start up from an Apple server over the Internet and get access to the macOS Recovery utilities.

If your computer starts up to the login or Welcome screen instead of macOS Recovery, you may not have held Command-R long enough. If this happens, click the Shut Down button (at the login screen) or press Command-Q (at the Welcome screen) and try again.

3 If a language selection screen appears, select your preferred language and click the right-arrow button.

4 After macOS Recovery starts up, you see a “macOS Utilities” window. This window is the primary interface for macOS Recovery.

Image

Examine the macOS Recovery Utilities

While using macOS Recovery, you have access to utilities for recovering, repairing, and reinstalling macOS. In this part of the exercise, you will get to know some of these utilities.

View macOS Recovery Help

You can use Safari to view the built-in instructions of macOS Recovery and to browse the web.

1 Select Get Help Online, and then click Continue.

Safari opens and displays a document with information about how to use macOS Recovery. Take a moment to skim the document.

This document is stored on the Recovery HD partition, but as long as you have an Internet connection available, you can also use Safari to view online documentation such as the Apple Support articles.

2 If a dialog indicates that Safari wants to use the “login” keychain, leave the Password field blank and click OK.

3 Click in the “Search or enter website name” field, enter apple.com, and press Return.

Image

Safari now displays the Apple website.

4 If Safari displays a message that says “You are not connected to the Internet,” you can join a wireless network using the Wi-Fi icon near the right side of the menu bar.

5 Click the Support link near the top right of the page.

You are taken to the Apple Support site. If you were experiencing a problem with your computer, this would be a good place to look for solutions and information. You will use some of the Apple Support resources later in this guide.

6 From the menu bar, choose Safari > Quit Safari (or press Command-Q) to return to the main utilities screen.

Note that closing the Safari window does not quit Safari. This is common among Mac applications, but if you are accustomed to using Microsoft Windows, it may be contrary to your expectations. Generally, the best way to quit a Mac application is to choose Quit <Application Name> from the application menu (the menu next to the Apple menu, named for the current application). Or you can use the keyboard shortcut Command-Q.

Examine Disk Utility

Disk Utility lets you repair, image, reformat, or repartition your computer’s disk.


Note

If the Mac computer’s system disk is protected by FileVault, any access to this disk will require the disk to be unlocked first. In most cases, any local user’s password on the system should be allowed to unlock the system FileVault drive. Lesson 10, “Manage FileVault,” covers this topic in greater detail.


1 Select Disk Utility, and then click Continue.

In the device list on the left, you see your startup disk and a Base System disk image. You may also see several untitled volumes. Note the primary entry for each disk device and an indented list of volumes on each device (this is discussed in more detail in Lesson 9, “Manage File Systems and Storage).

2 Select the lower entry for your startup volume. Typically, it is named Macintosh HD.

Image

Note the buttons in the Disk Utility toolbar. These buttons represent functions that are discussed in detail in Lesson 9.

With Disk Utility you can verify or repair the startup volume file structure or, if necessary, erase the volume before reinstalling macOS.

3 Select the upper entry that represents your startup disk (just above the startup volume), and note that the partition option is now available.

Image

4 Quit Disk Utility by choosing Disk Utility menu > Quit Disk Utility or by pressing Command-Q.

You are returned to the macOS Utilities window.

Examine Time Machine Restoration

If you backed up your computer with Time Machine, macOS Recovery has the capability to do a full system restoration from that backup. Reference 15.2, “Configure Time Machine,” covers setting up Time Machine.

1 Select Restore From Time Machine Backup, and then click Continue.

A “Restore from Time Machine” screen appears, with notes on the restoration process. It is important to realize that this restoration interface erases all current data and replaces it from the backup; Reference 15.3, “Restore from Time Machine,” examines other restoration interfaces that let you control which files or folders are restored.

2 Click Continue.

A “Select a Backup Source” screen appears. If you had configured a Time Machine backup target, it would be available here as a source for restoring your system.

3 Click Go Back to return to the “Restore from Time Machine” screen.

4 Click Go Back again to return to the macOS Utilities screen.

Examine the macOS Installer

Now you will examine the reinstallation process, but you will not perform the installation. By going through the following steps, you can experience the configuration of an installation without actually waiting for the macOS software to be copied to your Mac.

1 Select Reinstall macOS, and then click Continue.

The Installer application opens.

2 Click Continue.

A dialog appears indicating that this computer’s eligibility will be verified with Apple.

3 Click Continue.

4 At the license agreement, click Agree.

5 In the license confirmation dialog, click Agree again.

The installer displays a list of partitions where you could install or reinstall macOS.


Note

Do not click the Install button. If you do, the installer reinstalls macOS.


6 Quit the installer.

Verify Your Startup Disk and Restart

The Startup Disk utility lets you select the volume from which to start up. If you encounter problems during startup from your Mac computer’s internal disk, you could connect a second disk, with macOS installed, and use Startup Disk to configure your Mac to start up from the new disk.

1 From the Apple menu, choose Startup Disk.

Startup Disk lists all available startup volumes. The options may include Network Startup or one or more NetBoot images, depending on what Startup Disk finds on your network.

2 Verify that your computer’s normal startup volume (typically named Macintosh HD) is selected; if necessary, select it.

Image

3 Click Restart.

4 In the confirmation dialog, click Restart.

You could also restart without using the Startup Disk utility by choosing Apple menu > Restart.

Exercise 3.2 Create a macOS Install Disk


Image Prerequisites

Image You need an erasable external disk with a capacity of at least 8 GB.

Image You must have created the Local Admin account (Exercise 2.1, “Configure a New macOS System for Exercises,” or Exercise 2.2, “Configure an Existing macOS System for Exercises”).


In this exercise, you will create a macOS install disk, which includes not only the macOS Recovery environment and tools but also a full set of installation assets. With a disk created by this method, you can reinstall macOS without needing to redownload the installer application from the Internet.


Note

When you create your own macOS install disk, record the macOS version you’re using. Newer Mac computers don’t support older macOS versions. (See Exercise 1.3, “Erase a Mac System and Install macOS Sierra.”) Always keep your macOS install disks updated to the latest macOS version, which is available from the App Store.


Get a Copy of the Install macOS Sierra Application

If you upgraded to Sierra following the instructions in Exercise 1.2, “Upgrade to macOS Sierra,” and saved a copy of the installer application, you may use it and skip this section.

If you are performing these exercises as part of a class, the instructor may have provided a copy in the StudentMaterials/Lesson3 folder. Otherwise, you can redownload the installer with the following procedure:

1 Log in as Local Admin (password: ladminpw, or whatever you chose when you created the account).

2 From the Apple menu, choose App Store. For more about the Mac App Store, see Lesson 16, “Install Applications.”

3 In the search field of the App Store window, enter Sierra and press Return.

Image

4 Find macOS Sierra in the search results, and click the DOWNLOAD or GET button under its name.

Image

5 If a confirmation dialog appears, click Continue.

6 If a dialog appears asking you to sign in, you will need to either sign in to an Apple ID account or create a new Apple ID to download Sierra. See Lesson 16, “Install Applications (Reference 16.1, “Use the Mac App Store,” and Exercise 16.1, “Use the Mac App Store), for more information about using Apple IDs with the App Store.

When the installer application finishes downloading, it will open automatically.

7 Quit both Install macOS Sierra and the App Store.

Reformat the External Disk

Most external disks come preformatted with the Master Boot Record (MBR) partition scheme. To allow a Mac computer to start up from it, you must reformat this disk with the GUID partition map (GPT) scheme. For more information about disk formats, see Lesson 9, “Manage File Systems and Storage.”


Warning

This operation erases all information on the external disk. Do not perform this exercise with a disk that contains any files you want to keep.


1 Open Disk Utility. It is located in the Utilities folder, which is in the Applications folder. You can navigate to this folder in Finder by using the Finder shortcut Command-Shift-U, or you can open Launchpad in the Dock and then click the Other icon in Launchpad.

2 Plug the external disk into your computer.

3 If you are prompted for a password to unlock the disk, click Cancel. You don’t need to unlock the disk to erase it.

4 Select the external disk device entry in the Disk Utility sidebar. Be sure to select the device entry, not the volume entry indented beneath it.

5 Check the partition map listed at the bottom of the window.

Image

Depending on what this disk was used for most recently, the partition scheme could be anything. To convert the disk to the GPT scheme, you will erase the disk. If it is already using the GPT scheme, this is not strictly necessary, but you should erase it just to be sure.

It is also possible to partition the disk and use only part of it for the installer volume. See Reference 9.4, “Manage File Systems,” for more information about the partitioning procedure.

6 Click the Erase button in the toolbar.

7 Give the disk a descriptive name, choose Mac OS Extended (Journaled) from the Format pop-up menu, and choose GUID Partition Map from the Scheme pop-up menu.

Image

8 Click the Erase button.

9 When the process finishes, click Done to dismiss the erase dialog.

10 Verify that the Partition Map entry is now GUID Partition Map.

Image

11 Quit Disk Utility.

Create a macOS Install Disk

1 Open Terminal from the Utilities folder.

2 Switch to the Finder, and then navigate to where the “Install macOS Sierra” application is:

Image If you are performing this exercise in a class and the instructor provided a copy of the installer application, open the Lesson3 folder in StudentMaterials. Remember that you created a shortcut to the StudentMaterials folder in your Dock.

Image If you downloaded the installer application with the App Store, open the Applications folder. You can do this in the Finder by choosing Go menu > Applications or by using the keyboard shortcut Command-Shift-A.

3 Control-click the “Install macOS Sierra” application, and choose Show Package Contents from the shortcut menu that appears.

For more about packages, see Reference 12.2, “Examine Bundles and Packages.”

4 Inside the installer package, open the Contents folder, and then open the Resources folder inside that.

5 Drag the file named “createinstallmedia” from the Finder window into the Terminal window.

This inserts the full path to createinstallmedia into Terminal.

6 Switch back to Terminal, and press Return.

This executes the createinstallmedia tool as a command-line program. It prints a usage summary, explaining how to use the tool.

7 Begin another command by typing sudo followed by a space, but do not press Return until step 13.

8 Drag createinstallmedia from the Finder window into the Terminal window again.

9 In Terminal, enter --volume (note that there are two dashes at the beginning) followed by a space.

10 Drag the Install macOS Sierra (or whatever you named it) volume icon from the desktop to the Terminal window.

11 In Terminal, enter the text --applicationpath (again, there are two dashes at the beginning) followed by a space.

12 In the Finder, navigate back to the Applications folder, and drag the “Install macOS Sierra” application to the Terminal window.

At this point, the Terminal command should look something like this (although the lines may wrap differently):

Image

13 Switch to Terminal, and press Return.

This operation requires admin access, so it prompts you for your password.

14 Enter the Local Admin account password (ladminpw, or whatever you chose when you created the account), and press Return. Note that nothing displays as you type.

15 Since this operation will erase the disk, you are prompted to confirm the operation. Verify that the volume name (listed after “/Volumes/”) is the one you intend to use; then enter Y and press Return.

16 Wait as the install disk is prepared. This may take several minutes, depending on the type of external drive you are using and its speed.

When the process is complete, it prints “Copy complete.” followed by “Done.”

17 Quit Terminal.

Test the macOS Sierra Install Disk

If you want, you can now test the installer disk, although you should not actually reinstall macOS.

1 Restart your computer by choosing Apple menu > Restart and then clicking Restart in the confirmation dialog.

2 Press and hold the Option key until you see a row of icons appear on the screen.

3 Click the install disk’s icon.

Image

4 Click the arrow that appears under the icon.

The Mac starts up into the installer environment, which is similar to the recovery environment. You can explore it as much as you want, but do not reinstall macOS at this time.

5 When you have finished, choose Apple menu > Restart to restart your computer normally.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.119.142.246