The Repair functions of Disk Utility: what's it all about?

This FAQ provides a brief overview of the Repair Disk and Repair Disk Permissions functions of Disk Utility in Mac® OS X. It is a subset of the more comprehensive information on these topics from our book, Troubleshooting Mac OS X. The following topics are addressed:

The Repair functions of Disk Utility

Disk Utility can perform two types of repairs via the following choices in the First Aid tab:

The Repair Disk function

Repair Disk verifies and, if problems are found, corrects issues with the directory on a disk or volume.

The directory is analogous to a combined address book and road map to where data is stored on a disk or volume. A volume, also known as a partition, is section of a physical hard disk which, from the perspective of the operating system, works like a separate disk. All hard disks have one or more volumes or partitions.

Keep in mind the following key points about Repair Disk:

  1. You cannot use Repair Disk to repair your Mac OS X startup disk — for example, Macintosh HD — while your Mac is started up (booted) from such. To repair your startup disk, you must startup from your Mac OS X Install disc or another drive on which Mac OS X is installed. See Steps 1-2 of the Procedure specified in our "Resolving Disk, Permission, and Cache Corruption" FAQ for step-by-step instructions on repairing your startup disk using your Mac OS X Install disc.
  2. If you are running Mac OS X 10.4.3 or later and your startup disk is in Mac OS X Extended (Journaled) format — the default format for Mac OS X 10.3 Panther® and later — you can use Verify Disk to verify the directory of your startup disk while your Mac is started up from such. This is known as Live Verification. If Verify Disk finds errors on your startup disk, you must repair the disk as noted in point 1.

While Repair Disk can correct a variety of directory problems, it is generally incapable of repairing severe directory corruption. Severe directory corruption can often be repaired by third-party disk utilities. See the "Disk Utility cannot repair the disk" section of our "Resolving Disk, Permission, and Cache Corruption" FAQ for our advice in dealing with severe directory corruption that Repair Disk cannot correct. If you are running Mac OS X 10.4 Tiger™ or later, only use disk utilities which are compatible with that version of Mac OS X. See the AppleCare® Knowledge Base document "Only use Mac OS X 10.4-compatible disk utilities with Mac OS X 10.4 volumes."

The following AppleCare Knowledge Base documents discuss Repair Disk and the concept of partitions in more detail:

To delve into the technical details of the directory and volume structure of the Mac OS Extended disk format, aka HFS Plus or HFS+, see the Apple® Developer Connection document "Technical Note TN1150: HFS Plus Volume Format."

The Repair Disk Permissions function

Repair Disk Permissions verifies and, if problems are found, resets (repairs) the permissions on Apple-originated files and folders (objects), i.e. Mac OS X system-related objects and Apple-provided applications bundled with Mac OS X. This is described in more detail in the AppleCare Knowledge Base document "About Disk Utility's Repair Disk Permissions feature."

Verification compares the current permissions settings of an Apple-originated object against those specified for that object in its associated installation receipt. Receipts are files saved in the Macintosh HD > Library > Receipts folder, i.e. the /Library/Receipts directory. If the permissions of an object differ from those specified in its associated receipt, its permissions are reset to the values specified in the receipt.

It is important to understand that Repair Disk Permissions only verifies and repairs the permissions of Apple-originated objects whose receipts are in the /Library/Receipts directory. This means that Repair Disk Permissions will not correct permissions problems on:

  • Third-party software, even if that software was installed using the Mac OS X Installer and created a receipt in /Library/Receipts. This is because the software was not "Apple-originated." [1]
  • Objects in the Macintosh HD > Users folder, such as your Home folder or its contents.

Repair Disk Permissions is only available for volumes on which Mac OS X is installed.

Repair Disk Permissions often produces messages while it is running. These messages are generally of an informational nature and can usually be ignored. Some of these messages may be repeated every time Repair Disk Permissions is run as the receipt for the object in question is forcing the setting of specific permissions, even if no correction is required. Again, these can also be ignored. Only messages indicating the failure of the Repair Disk Permissions process, or the inability to correct permissions on a specific file or folder, should be of concern. [2]

The AppleCare Knowledge Base document "Troubleshooting permissions issues in Mac OS X" provides some important background information about permissions. You can find additional information about permissions in the educational resources recommended in our "Learning about Mac OS X FAQ".

Why are repairs needed? When should I use these functions?

Repair Disk

Power outages, hard restarts, and system crashes can lead to disk directory corruption, requiring the use Repair Disk to correct such. File System Journaling, introduced in Panther as a default setting for your Mac OS X startup disk, can help minimize the impact of such events on the disk's directory. However, even journaling is not foolproof. For additional details, see our "Data corruption and loss: causes and avoidance" FAQ.

Run Repair Disk:

  • After a power outage, hard restart, or system crash — especially if your Mac behaves anomalously thereafter.
  • Periodically, as part of your regular maintenance routine, to identify any hidden directory corruption before it becomes a problem. See our "Maintaining Mac OS X" FAQ for our recommended regular-maintenance routine.
  • Before installing software, particularly Mac OS X Updates: see our "Installing software updates" FAQ for details.
  • Before reinstalling Mac OS X via Archive and Install process: see our "General advice on performing an Archive and Install" FAQ for details.

Repair Disk Permissions

Rogue installers — applications that temporarily change, but fail to reset, permissions on System-related files or folders during a software installation — are a primary cause of permissions-related problems. Accordingly, you should run Repair Disk Permissions after installing any third-party software that employs its own installer.

Verify or Repair?

In general, given the choice between the Verify or Repair buttons in Disk Utility, select Repair to save time. Verify only checks for problems. If problems are found, you then need to run the corresponding Repair. Repair both verifies and, if problems are found, attempts to perform the required repair. Accordingly, selecting the Repair button is more efficient. Note again that you cannot use Repair Disk to repair your Mac OS X startup disk while your Mac is started up from such: see "The Repair Disk function" section earlier in this FAQ.

Related links

Notes

[1] We suspect that Repair Disk Permissions checks the CFBundleIdentifier property in the receipt package's Info.plist file to determine if the software was "Apple-originated."

[2] A change in Mac OS X 10.4.6 resulted in the suppression of informational messages of the "We are using special permissions…" type, which often concerned users unfamiliar with the intent of such.

Did you find this FAQ helpful? You will find a wealth of additional advice for preventing or resolving Mac OS X problems in Dr. Smoke's book, Troubleshooting Mac® OS X.
Use of this site signifies your agreement to the terms of use.
Copyright © 2003-2008 The X Lab. All rights reserved.