- GUID Partition Table
In
computer hardware , GUID Partition Table (GPT) is a standard for the layout of thepartition table on a physicalhard disk . It is a part of the Extensible Firmware Interface (EFI) standard proposed by Intel as a replacement for the PCBIOS , one of the few remaining relics of the original IBM PC. EFI uses GPT whereas BIOS uses aMaster Boot Record (MBR).Features
Current PC BIOS schemes use a Master Boot Record (MBR) to begin the process of initializing the disk. The MBR begins with an entry called the
Master Boot Code , which contains an executable binary for the purpose of identifying and booting the active partition. PC BIOS's replacement, EFI, itself contains this capability but to maintain backwards compatibility, GPT retains the MBR entry as the first sector on the disk followed by a Primary Partition Table Header, the actual beginning of GPT.GPT uses modern
logical block addressing (LBA) in place of thecylinder-head-sector (CHS) addressing used with MBR. Legacy MBR information is contained in LBA 0, the GPT header is in LBA 1, and the partition table itself follows. In 64-bit Windowsoperating system s, 16,384 bytes, or 32 sectors, are reserved for the GPT, leaving LBA 34 as the first usable sector on the disk.According to Apple [http://developer.apple.com/technotes/tn2006/tn2166.html] , "Do not assume that the {LBA} size is always going to be 512 bytes."
GPT also provides for redundancy. The GPT header and partition table are written at both the beginning and end of the disk.
Legacy MBR (LBA 0)
The primary purpose of the MBR at the beginning of the disk is to prevent MBR-based disk utilities from mis-recognizing, and possibly over-writing, GPT disks. A single partition, encompassing the entire GPT drive, is indicated. The System ID for the partition is set to 0xEE, indicating that it uses GPT. Because of this, EFI ignores the MBR. Some 32-bit OSes which cannot read GPT disks nevertheless recognize this ID and present the disk as an inaccessible GPT disk. Older OSes will generally recognize the disk as containing one partition of unknown type and no empty space, and then they'll typically also refuse to modify the disk unless the user explicitly requests and confirms the deletion of this partition. This way, accidental erasures are minimized.
Partition table header (LBA 1)
The partition table header defines the blocks on the disk that can be utilized by the user (the usable blocks). It also defines the number and size of the partition entries that make up the partition table. On 64-bit Windows Server 2003 machines, there are 128 partition entries reserved, each 128 bytes long. Thus, 128 partitions can be created.
The header contains the disk
GUID (Globally Unique Identifier). It records its own size and location (always LBA 1) and the size and location of the secondary GPT header and table (always the last sectors on the disk). Importantly, it also contains a CRC32 checksum for itself and for the partition table, which is verified by EFI processes on boot. Because EFI uses and verifies this checksum, hex editors should not be used to modify the contents of the GPT. Such modification would render the checksum invalid. In this case, EFI would overwrite the primary GPT with the secondary one, or, if both GPTs contained invalid checksums, would be unable to access the disk.# The GUIDs in this table are written assuming a
little-endian byte order . For example, the GUID for an EFI System partition is written as C12A7328-F81F-11D2-BA4B-00A0C93EC93B here, which corresponds to the 16 byte sequence 28 73 2A C1 1F F8 D2 11 BA 4B 00 A0 C9 3E C9 3B — only the first three blocks are byte-swapped.
#note label|linwin|2|b Linux and Windows use the same GUID for their respective data partitions.
#note label|solmac|3|b The GUID for/usr
on Solaris is used as a generic GUID for ZFS by Mac OS X.
# Definitions are in src/sys/sys/disklabel_gpt.h. NetBSD had used the FreeBSD GUIDs before unique NetBSD-specific GUIDs were created.References
ee also
*
Master boot record
* GUID
* EFI
*Disk partitioning External links
*Microsoft TechNet: [http://technet2.microsoft.com/windowsserver/en/library/bdeda920-1f08-4683-9ffb-7b4b50df0b5a1033.mspx?mfr=true Disk Sectors on GPT Disks]
*Microsoft TechNet: [http://www.microsoft.com/whdc/device/storage/GPT-on-x64.mspx Using GPT Drives on x86-64 Systems]
*Apple Developer Connection: [http://developer.apple.com/technotes/tn2006/tn2166.html Secrets of the GPT]
Wikimedia Foundation. 2010.