GUID Partition Table
GUID Partition Table (GPT) is a partitioning scheme that is part of the Unified Extensible Firmware Interface specification; it uses a globally unique identifier for qualifying devices. It is the next generation partitioning scheme designed to succeed the Master Boot Record partitioning scheme method. It evolved to deal with several shortcomings of the MBR partitioning scheme method and offers additional advantages.
About the GUID Partition Table
GUID Partition Table (GPT) uses GUIDs (or UUIDs in linux world) to define partitions and its types, hence the name. The GPT consists of:
|Location in the HDD||Purpose|
|First logical sector of the disk or First 512 bytes||Protective MBR - Same as a normal MBR but the 64-byte area contains a single 0xEE type Primary partition entry defined over the entire size of the disk or in case of >2 TiB, upto a partition size of 2 TiB.|
|Second logical sector of the disk or Next 512 bytes||Primary GPT Header - Contains the Unique Disk GUID, Location of the Primary Partition Table, Number of possible entries in partition table, CRC32 checksums of itself and the Primary Partition Table, Location of the Secondary (or Backup) GPT Header|
|16 KiB (by default) following the second logical sector of the disk||Primary GPT Table - 128 Partition entries (by default, can be higher), each with an entry of size 128 bytes (hence total of 16 KiB for 128 partition entries). Sector numbers are stored as 64-bit LBA and each partition has a Partition Type GUID and a Unique Partition GUID.|
|16 KiB (by default) before the last logical sector of the disk||Secondary GPT table - It is byte-for-byte identical to the Primary table. Used mainly for recovery in case the primary partition table is damaged.|
|Last logical sector of the disk or Last 512 bytes||Secondary GPT Header - Contains the Unique Disk GUID, Location of the Secondary Partition Table, Number of possible entries in the partition table, CRC32 checksums of itself and the Secondary Partition Table, Location of the Primary GPT Header. This header can be used to recover GPT info in case the primary header is corrupted.|
Advantages of GPT
- Uses GUIDs (UUIDs) to identify partition types - No collisions.
- Provides a unique disk GUID and unique partition GUID for each partition - A good filesystem-independent way of referencing partitions and disks.
- Arbitrary number of partitions - depends on space allocated for the partition table - No need for extended and logical partitions. By default the GPT table contains space for defining 128 partitions. However if the user wants to define more partitions, he/she can allocate more space to the partition table (currently only gdisk is known to support this feature).
- Uses 64-bit LBA for storing Sector numbers - maximum addressable disk size is 2 ZiB. MBR is limited to addressing 2 TiB of space per drive.
- Stores a backup header and partition table at the end of the disk that aids in recovery in case the primary ones are damaged.
- CRC32 checksums to detect errors and corruption of the header and partition table.
CONFIG_EFI_PARTITION option in the kernel config enables GPT support in the kernel (despite the name EFI PARTITION). This options must be built-in the kernel and not compiled as a loadable module. This option is required even if GPT disks are used only for data storage and not for booting. This option is enabled by default in Arch's and kernels in [core] repo. In case of a custom kernel enable this option by doing
- Wikipedia's Page on GPT and MBR
- Homepage of Rod Smith's GPT fdisk tool and its Sourceforge.net Project page - gptfdisk
- Rod Smith's page on What's a GPT? Converting MBR to GPT and Booting OSes from GPT
- Rod Smith's page on the New Partition Type GUID for Linux data partitions
- System Rescue CD's page on GPT
- Wikipedia page on BIOS Boot Partition
- Make the most of large drives with GPT and Linux - IBM Developer Works
- Microsoft's Windows and GPT FAQ
- Fedora developer discussion on BIOS/GPT configuration