Unlike personal computers that run Microsoft Windows, it should not be necessary to completely reformat the hard drive, once a year, to reinstall the operating system. You will find that OS X is very stable in comparison, it defragments its hard drive on an ongoing basis and it does not get bogged down with additional software in the way that a Windows machine does.
There may be occasions, however, when you want to reformat your Mac's hard drive. In this tutorial, I will show you how to reformat the hard drive in your Mac and reinstall OS X for that factory fresh finish.
The Reasons for Reformatting
There may be times that you do wish to start again, from scratch. It may be that it is cathartic to get rid of a load of applications and just install the ones that you really need, or it may be that you are selling the machine – or passing it on – and you want to revert the machine to factory settings.
By doing this, you ensure that none of your personal data remains and the recipient is in receipt of a Mac with an operating system that is as fresh as when it first left the factory.
Backup, Backup, Backup Your Data!
I can not emphasise this strongly enough. Backup your data before proceeding. The instructions that I will give, in this tutorial, will have catastrophic consequences if you have data that you need to keep and do not backup first.
I recommend taking a Time Machine backup and, separately, cloning your hard drive. This ensures that you have two separate backups, thereby halving the chances of data loss.
Tip: There are plenty of tutorials on Mactuts+ to help you backup your data.
Launching OS X Utilities
I’m assuming that all of your important data has been backed up, already. More importantly, I am assuming that you have tested the integrity of your backup(s). There aren’t many things more frustrating than taking a backup only to find that you are unable to restore from it as it has been corrupted in some way.
Launching OS X Utilities depends on what version of OS X your Mac is running. For OS X 10.7 Lion, 10.8 Mountain Lion and 10.9 Mavericks, the necessary utilities are normally stored on a hidden recovery partition on your Mac. To access these, turn on your Mac and hold the Command and R keys, simultaneously, immediately after you hear the start-up chime.
Keep hold of them! Within around 10–15 seconds, you will be shown the OS X Utilities options.
For OS X versions preceding and including OS X 10.6 Snow Leopard, you will require either the grey OS X installation DVD that shipped with your Mac, or the retail DVD of an appropriate version of OS X for your Mac.
For Snow Leopard, or earlier, insert the appropriate DVD then press and hold the C key immediately after the start-up chime. The computer will start up using the install media. Alternatively, press and hold the Option key (sometimes marked ALT) at start-up to select the volume containing the installer.
Dealing With Partitions
If you have more than one partition, on the hard drive, you may wish to remove these and return the hard drive to a single partition, first.
From OS X Utilities, select Disk Utility. Select your Mac’s hard drive in the lefthand column, to reveal more options, then select the Partition button.
In the Partition Layout dropdown menu, select 1 Partition.
In the Partition Information box, enter an appropriate name for your Mac’s hard drive. I’ve chosen Macintosh HD.
Now click Apply. A dialogue box will pop up to confirm the actions you are taking. If you are happy with this, click Partition.
Erasure and Security
In Disk Utility, of OS X Utilities, select the partition (in the lefthand column) that you created in the previous step.
Select Erase and ensure that the Format is Mac OS Extended (Journaled). It should default to this option.
If you want to be super security conscious, you can select the Security Options button. This gives you a choice of how secure you’d like the erasure of the hard drive to be. The trade-off is time; the more secure it is, the longer it will take.
There are four security options, ranging from fastest and least secure to slowest and most secure.
- Fastest / Least Secure - this option does not securely erase the files on the disc. A disc recovery application may be able to recover the files.
- This option writes a single pass of zeroes over the entire disc. It erases the information used to access your files and writes over the data once.
- This option is a DOE-compliant 3-pass secure erase. It writes two passes of random data followed by a single pass of known data over the entire disc. It erases the information uses to access your files and writes over the data three times.
- Slowest / Most Secure - This option meets the US Department of Defense (DOD) 5220–22 M standard for securely erasing magnetic media. It erases the information used to access your files and writes over the data seven times.
Select the appropriate level of security / speed for deleting your data and click OK then Erase.
Tip: The more faster the erase, the less secure it is. There is a chance that data recovery software will be able to retrieve personal information. For maximum security, use an erase that writes more than once. Bear in mind, this can take a long time to complete.
Reinstallation of OS X
Following the erasing of your Mac’s hard drive, you are returned to the OS X Utilities options. From this you can select one of two options in order to restore the operating system:
- Restore from a Time Machine Backup
- Reinstall OS X
The first option allows you to restore your machine to the latest Time Machine backup, if you have one.
If you prefer to install the operating system afresh, select the second option.
Tip: If you attempt to reinstall OS X onto an existing partition without first erasing it, OS X will reinstall the operating system files and your user files will remain intact. If you wish to remove your data, you must erase the hard drive first.
Rebooting and Recovery
If your Mac originally shipped with OS X 10.7 Lion, 10.8 Mountain Lion or 10.9 Mavericks, and you have rebooted your Mac following the complete erasure of the hard drive, your Mac will not be able to boot.
Instead, a grey folder with a question mark will flash on the screen. You will see the same thing if your hard drive suffers a catastophic failure. It means that your Mac is unable to read any data from the hard drive. Either because there is no data to read, or the data that is there is corrupted.
In this case, reboot your Mac and hold down Command and R immediately following the start-up chime. Your Mac will then try to connect to the internet so that it can download the OS X Utilities back to the hard drive.
In the case of operating systems including and preceding OS X 10.6 Snow Leopard, you will need to have either the grey install DVD that shipped with your Mac or an appropriate OS X retail DVD in which to boot from. In this case, reboot and hold down C immediately following the start-up chime.
Factory Fresh Finish
If you are selling, or passing on your Mac to a friend or family member, it is a really nice touch to have the Mac ready to boot into the OS X set up for the first time just like it did when you bought it.
Following the downloading and installation of OS X, simply close down your Mac. The next time it is booted up, it will go straight into the set up routine and ask the new user for their AppleID(s) in order to set up the Mac for their use.
In this tutorial, I showed you how to reformat the hard drive in your Mac and how to reinstall OS X. I explained the differences between versions of OS X including and up to 10.6 Snow Leopard and 10.7 Lion onwards.
Whilst it is not normally necessary to reformat the hard drive and reinstall OS X from scratch, knowing how to if you need to, or if you want to, can be extremely useful. Especially if you are selling or passing on your Mac to someone else.