10

I want to enable encryption on an external FireWire disk. The disk has been formatted a while ago (2+ years), and when choosing "encrypt volume" from the Finder context menu, Mountain Lion refuses with the message:

A Recovery system for the targeted disk is required

Turns out: You need a Recovery Partition (RP) on the external disk you want to encrypt. Mine does not have one, as it was formatted when there were no Recovery Partitions.

Reformatting the drive does create a new RP, but I can’t do this because I have no spare disks where I can swap the data to.

This hint is not useful, as it deals with internal disks.

So I am looking for a way to create a Recovery Partition on the external disk so that I can enable encryption for this disk. (How) can this be done?

EDIT: Yes, there is space on the disk for another partition. diskutil list:

/dev/disk2
   #:                       TYPE NAME           SIZE       IDENTIFIER
   0:      GUID_partition_scheme               *320.1 GB   disk2
   1:                        EFI                209.7 MB   disk2s1
   2:                  Apple_HFS le_disk        306.7 GB   disk2s2

EDIT II:

Output from an other disk. Here, encryption of a partition (FreeSpace-500) has worked directly from Finder. Note that the (invisible) boot partition created during the process is called Boot OS X, and not Recovery HD.

/dev/disk2
   #:                       TYPE NAME                SIZE       IDENTIFIER
   0:      GUID_partition_scheme                    *2.0 TB     disk2
   1:                        EFI                     209.7 MB   disk2s1
   2:                  Apple_HFS TimeMachine         1.5 TB     disk2s2
   3:          Apple_CoreStorage FreeSpace-500       503.3 GB   disk2s3
   4:                 Apple_Boot Boot OS X           134.2 MB   disk2s4
4
  • If you are trying to do this to a disk with data on it, it may not be possible, as you cannot move the start of a HFS partition. It depends on whether the recovery partition has to be physically before the data partition or not.
    – Fake Name
    Nov 26, 2012 at 16:57
  • I don't know if the RP has to be physically before the data partition or not.
    – myhd
    Nov 29, 2012 at 12:55
  • What does diskutil list show for the external? Can you create a new 1 GB partition by shrinking existing or allow one existing partition to serve as e recovery HD. it needs to be about 700 MB of space.
    – bmike
    Nov 29, 2012 at 13:12
  • 1
    650 MB, to be exact.
    – duci9y
    Nov 30, 2012 at 12:32

4 Answers 4

10
+50

Manually Cloning a Recovery Partition

This process worked for me on an external USB drive, but I don't have a Firewire drive or encrypted partition to test with, but it should work for you.

Requirements

  • Existing recovery partition on your internal drive (or elsewhere).
  • At least 650 MB of free space on your external drive (a previous version of this answer required more space, but I fixed the first section to only use what's required).

Add New Partition

Notes: this process is not destructive, provided you have sufficient free space on your drive.

  1. In Terminal, run diskutil list. You should get output like this:

    /dev/disk0
       #:                       TYPE NAME                    SIZE       IDENTIFIER
       0:      GUID_partition_scheme                        *120.0 GB   disk0
       1:                        EFI                         209.7 MB   disk0s1
       2:                  Apple_HFS Macintosh SSD           119.2 GB   disk0s2
       3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3
    /dev/disk1
       #:                       TYPE NAME                    SIZE       IDENTIFIER
       0:      GUID_partition_scheme                        *320.1 GB   disk1
       1:                        EFI                         209.7 MB   disk1s1
       2:                  Apple_HFS Portable                319.7 GB   disk1s2
    

    Make note of the identifiers for your existing recovery partition (in my case, disk0s3) and the main partition on your external drive (disk1s2).

  2. Run diskutil info disk1s2 | grep 'Total Size', replacing disk1s2 with the identifier for your external volume. Note the number of bytes listed.
  3. Run diskutil resizeVolume disk1s2 Xb JHFS+ Temp 650002432b, replacing X with the total number of bytes from step 2 minus 650002432. This will repartition your disk, giving us a new partition with exactly enough space for the recovery partition. Note: A recovery partition is not always 650002432 bytes. Find out the exact size by checking diskutil info on the partition you want to copy.
  4. The resizeVolume command will print out the new partition map (like in step 1), make note of the identifier for the new partition (labelled Temp).

Clone Existing Recovery to the New Partition

  1. Run the following command in Terminal to clone the recovery partition to the new partition, replacing disk0s3 and disk1s3 with the appropriate identifiers for your partitions:

    sudo asr -source /dev/disk0s3 -target /dev/disk1s3 --erase
    

    You will be asked for your password, and to verify that you want to erase the contents (type y followed by enter), then the cloning process will begin.

  2. Unmount the recovery partition if it's mounted, then run sudo asr adjust --target /dev/disk1s3 --settype "Apple_Boot". Be sure to replace disk1s3 with the appropriate identifier. This sets the proper partition type, which stops OS X from auto-mounting the recovery partition when you attach your external drive.

If everything completed properly, you should have a working recovery partition on your external disk.

8
  • Thank you very much for this extensive trip to the Terminal (like!). I followed the steps, but got Error: -69742: The requested change in size is too small after Step 3.
    – myhd
    Nov 30, 2012 at 14:03
  • I got that once, double check you're using the right value for the resized volume. It should be the number from step 2 minus 650002432. If that still doesn't work, try decreasing that value, or resizing the partition from Disk Utility, then follow the steps in the second section.
    – robmathers
    Nov 30, 2012 at 16:00
  • @myhd any luck? If you're still having trouble, let me know and I can offer some further assistance.
    – robmathers
    Dec 2, 2012 at 1:48
  • I have tried with decreasing the partition from Disk Utility, and nothing has helped. Tried the same thing from a disk that had the same characteristics described in the original question, and all went well, even without having to resort to your tips. Mysterious. I do assume now the first disk in question was hosed somehow. I found a interesting bit, however: The newly-created partition on the to-be-encrypted disk is called "Boot OS X" instead of "Recovery HD" on the built-in system disk. Maybe that’s why it did not work in the first place?
    – myhd
    Dec 4, 2012 at 12:29
  • Ah, I see why you're running into problems. Based on the diskutil list that you added to your post, you don't have a recovery partition. You'll want to add one before proceeding.
    – robmathers
    Dec 4, 2012 at 15:32
3

This doesn't solve the question as it now stands from the OP, but it may be of help to someone who finds this page looking for a solution to this problem with a USB-mounted disk (as opposed to a FireWire one, as the OP now specifies).

It would appear that this Apple Knowledge Base article does, in fact, answer your question: http://support.apple.com/kb/HT4848

You would need to create a new partition on the external disk (which the article implies, but does not state, can be done non-destructively, suggesting that the partition does not need to be physically before the start of the data partition).

As long as you have space to create a new 1GB partition on the external disk, the article seems to suggest you can install a recovery disk to that partition.

That said, and this is an issue, before repartitioning or encrypting a disk with valuable data, it would be a very very good idea to back up said data in case something goes wrong.

1
  • Recovery Disk Assistant does work on USB devices. Unfortunately, mine is a FireWire disk.
    – myhd
    Nov 29, 2012 at 17:53
2

It's actually possible to non-destructively add a recovery partition to a disk using Carbon Copy Cloner. From the Window menu select Disk Center and select the disk you want to add a recovery partition to from the list on the left hand side. The tab Recovery Partition on the right hand side should allow you to add the recovery partition.

As already suggested, be sure to have a backup when live repartitioning disks just in case something goes wrong.

1
  • Interesting! I did not know CCC had this functionality. I tried, and on the surface it worked. After setting up encryption however, the process stopped with this dialog: "Boot file not written". Any ideas?
    – myhd
    Nov 30, 2012 at 14:11
0

It's much easier to just use the OS installer you choose and this tool to make Recovery HD (or update existing recovery HD if Apple doesn't when they upgrade the OS itself)

You can look at the tools and it's been used by many Mac Admins so it gets updated when things break over time quite rapidly. Apple recommends reinstalling the OS, but that's an indirect way if you don't mind running a special tool for this limited task.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .