Strange partitions on HD

Discussion in 'Mac Pro' started by macmesser, Feb 22, 2013.

  1. macmesser macrumors 6502a

    Joined:
    Aug 13, 2012
    Location:
    Long Island, NY USA
    #1
    While using Drive Genius 3 to partition an eSATA drive for use with Time Machine, I noticed that the drive contained three tiny partitions which were not visible in Disk Utility. One is an "EFI System Partition" named "disk5s1" and is about 210 MB in size. I've seen names like this in Disk Utility when first installing and formatting drives in my eSATA enclosure. The other partitions, named "Free space #1" and "Free space #2", are "Apple_Free" partitions and are 3KB and 132MB respectively.

    What's up with these partitions? Not that they take much space on a 2TB drive, but can they be deleted?
     
  2. Weaselboy Moderator

    Weaselboy

    Staff Member

    Joined:
    Jan 23, 2005
    Location:
    California
    #2
    The EFI one is standard and needs to be there. The others can be deleted.
     
  3. macmesser thread starter macrumors 6502a

    Joined:
    Aug 13, 2012
    Location:
    Long Island, NY USA
    #3
    Thanks.
     
  4. Tesselator, Feb 22, 2013
    Last edited: Feb 22, 2013

    Tesselator macrumors 601

    Tesselator

    Joined:
    Jan 9, 2008
    Location:
    Japan
    #4
    On Apple–Intel architecture Macs, the EFI partition is initially blank and not used for booting. However, the EFI partition is used as a staging area for firmware updates specifically, it places a firmware flash utility (EFI binary) and data file (FD – "Firmware Device") in the directory EFI/APPLE/FIRMWARE which is then run when rebooting the system in "flash firmware" mode.

    If deleted, the system will still boot, and the boot manager will still allow users to choose whether to start a Boot Camp partition or the default Mac OS X, but firmware updates will fail.

    For use as storage or with Time Machine and not as a boot drive which might need to participate in a firmware upgrade procedure, I believe you can safely delete the EFI partition as well. It shouldn't affect anything.



    To delete the EFI (ESP) partition:
    sudo gpt remove -i 1 disk1
    Assuming it's disk1 of course. (be careful!)

    To recreate an EFI (ESP) partition:
    sudo gpt add -b 40 -i 1 -s 409600 -t C12A7328-F81F-11D2-BA4B-00A0C93EC93B disk1
    sudo dd if=/dev/disk0s1 of=/dev/disk1s1
    Again assuming it's disk1 you're working on.



    The later set of two commands will create the EFI partition on your external drive and clone the EFI partition from your boot drive over to it. The cloning is needed as EFI has a very specific structure as documented here:
    http://developer.apple.com/library/...apple_ref/doc/uid/DTS10003927-CH1-SUBSECTION6
     
  5. DanielCoffey macrumors 65816

    DanielCoffey

    Joined:
    Nov 15, 2010
    Location:
    Edinburgh, UK
  6. Weaselboy Moderator

    Weaselboy

    Staff Member

    Joined:
    Jan 23, 2005
    Location:
    California
    #6
    Good point. I wonder if not having an EFI partition on the external would impact a Time Machine drive's ability to boot for a restore?
     
  7. Quad5Ny macrumors 6502a

    Quad5Ny

    Joined:
    Sep 13, 2009
    Location:
    New York, USA
    #7
    The EFI System partition is part of the GPT spec.

    The 3KB partition is slack space used to align the other partitions.

    The 2 other blocks are just free space not partitions, Apple's standard disk layout places that amount of free space between each partition.

    Don't mess with it, everything is perfectly normal. Also why the heck aren't you using Disk Utility to partition the drive? :confused:
     
  8. macmesser thread starter macrumors 6502a

    Joined:
    Aug 13, 2012
    Location:
    Long Island, NY USA
    #8

    Thanks for sharing your knowledge. Great to know this stuff even for a non-engineer. The drive in question was simply formatted and partitioned for data storage. There was no OS installation. Am I correct in thinking the EFI on it was added during Disk Utility formatting but is empty, and that had an OS installation been done the files and directory structure would be installed along with the OS?
     
  9. Quad5Ny macrumors 6502a

    Quad5Ny

    Joined:
    Sep 13, 2009
    Location:
    New York, USA
    #9
    The EFI partition is always empty on OS X, the only time you'll find something on it is during a Firmware update.

    Disk utility creates the a EFI partition whenever you initialize a GUID Partition Table (GPT) disk. It does this regardless of whether you install a operating system on it or not.
     
  10. Tesselator macrumors 601

    Tesselator

    Joined:
    Jan 9, 2008
    Location:
    Japan
    #10
    Nope, it sure wouldn't. Err, shouldn't...



    BTW, I have to agree with Quad5Ny, While these things are all perfectly possible it's a much better idea to stick to the prescribed methods and tools. What are you losing, about 220MB all total? compress a few files and you'll get that right back. :)
     

Share This Page