Deleting and merging a partition with diskutil from the command line
This is the most precise method I know of to remove the partition since it targets the recovery disk directly and merges it with the full Lion partition – if you’re not comfortable with the command line this is not for you.
This is the most precise method I know of to remove the partition since it targets the recovery disk directly and merges it with the full Lion partition – if you’re not comfortable with the command line this is not for you.
- Launch the Terminal and type the following into the command line:
- diskutil list
- This will print out your drives partition scheme and look something like this:
- Look for “Recovery HD” and see which identifier it is using, it this screenshot it’s disk0s4
- To remove that partition we use the following command (you can also use the volume name):
- diskutil eraseVolume HFS+ Blank /dev/disk0s4
- The partition will be erased, you might want to do this with your standard Lion partition as well since you’ll be wiping the entire thing anyway. Regardless, you’ll now have a blank partition sitting around, so you’ll want to merge that with your other Lion partition:
- diskutil mergePartitions HFS+ Lion disk0s3 disk0s4
- This will merge the two partitions, with disk0s3 absorbing the space from disk0s4 and expanding, it causes data loss so don’t expect this to preserve anything
The next approach is much more invasive because it formats the entire disk.
Removing the partition with Disk Utility by formatting the disk
Disk Utility will not display “Recovery HD” on it’s own because it’s a hidden partition, meaning you can’t just go into the app and delete it. What you can do though is format the entire drive though, which will then require a Lion clean install either starting from Snow Leopard or with a created installer DVD. This is sort of the nuclear approach but it works to delete the recovery partition too.
Removing the partition with Disk Utility by formatting the disk
Disk Utility will not display “Recovery HD” on it’s own because it’s a hidden partition, meaning you can’t just go into the app and delete it. What you can do though is format the entire drive though, which will then require a Lion clean install either starting from Snow Leopard or with a created installer DVD. This is sort of the nuclear approach but it works to delete the recovery partition too.
- Boot the Mac from a recovery DVD, USB key, or an attached drive
- Launch Disk Utility
- Right-click on the Disk (not the partitions) and select “Erase”
- Select the default Mac OS Extended (Journaled) as the file system, and give the drive a name
- Click on “Erase” to completely format the drive – you will lose all data on the drive and all partitions
Comments
Post a Comment