blob: fcd5bdd7e18923372ba60b4836733ab7e5e30859 [file] [log] [blame]
Roderick W. Smithaf39cb42013-08-06 15:23:46 -040010.8.8 (?/??/2013):
2------------------
3
Roderick W. Smith427c7992013-09-12 12:37:44 -04004- Fine-tuned verification ('v') check for 0xEE partition that doesn't begin
5 on sector 1: Previously, a disk with multiple 0xEE partitions would
6 always trigger this warning. Now, the warning occurs only if NONE of the
7 0xEE partitions begins on sector 1.
8
9- Fixed hybrid MBR creation on disks larger than 2TiB: Previously, if one
10 opted to create an extra partition to cover unused space following
11 hybridized partitions, gdisk would hang.
12
13- Added support for new partition type code,
14 47CB5633-7E3E-408B-B7B8-2D915B7B21B1 (0x8302), which parted (git versions
15 leading up to 3.2) uses for HFS+ partitions that hold Linux boot files on
16 Macs. This type code corresponds to the "hfs_esp" flag in parted.
17
Roderick W. Smith042f38a2013-08-31 17:40:15 -040018- Added check for an active/bootable 0xEE protective partition to the
19 verify ('v') function. If found, this is not counted as an error, but
20 it is called out to the user, since it can cause some EFIs (such as
21 VirtualBox's EFI) to ignore the disk.
Roderick W. Smithaf39cb42013-08-06 15:23:46 -040022
Roderick W. Smithe09ef882013-07-08 22:56:00 -0400230.8.7 (7/8/2013):
srs5694f5dfbfa2013-02-14 20:47:14 -050024-----------------
25
Roderick W. Smithe09ef882013-07-08 22:56:00 -040026- Modified Mac version so that it can work on /dev/rdisk* devices as well
27 as /dev/disk* devices. The result is that, when using the /dev/rdisk*
28 devices, the partition table can sometimes be re-read without removing
29 the disk or rebooting.
30
31- Added "-a" option to cgdisk to use a ">" symbol to the left of the
32 selected partition rather than ncurses highlighting.
33
Roderick W. Smith1eea9b02013-07-06 22:52:58 -040034- Modified "converting MBR to GPT" message to clarify that the conversion
35 is being held in memory, since some people have mistakenly assumed that a
36 "gdisk -l" operation will change an MBR disk to a GPT disk without
37 prompting.
38
39- Added partition type code for freedesktop.org's proposed $BOOT partition
40 (bc13c2ff-59e6-4262-a352-b275fd6f7172; GPT fdisk type code EA00)
41
srs5694f5dfbfa2013-02-14 20:47:14 -050042- Adjusted alignment code when using -n or -N in sgdisk to keep the
43 requested partition size (if specified using +###{MGT} terminology)
44 as the requested value rather than relative to the requested start
45 point. This gives you the requested partition size rather than be
46 slightly smaller if sgdisk needs to adjust the start point up a bit and
47 it prevents gaps from appearing between partitions if several are created
48 in succession using automatic placement of the start point.
49
50- Fixed small bugs in gdisk_test.sh script.
51
52- Removed stray debug message that would appear when reading MBR disks.
53
Roderick W. Smith1eea9b02013-07-06 22:52:58 -040054- Added partition type code for Intel Rapid Start partition (GUID
55 D3BFE2DE-3DAF-11DF-BA40-E3A556D89593, code 8400), used by systems that
srs5694f5dfbfa2013-02-14 20:47:14 -050056 implement Intel's Rapid Start technology. See
Roderick W. Smith1eea9b02013-07-06 22:52:58 -040057 http://blog.adios.tw/2012/10/funtoo-linux-and-intel-rapid-start.html or
58 http://mjg59.dreamwidth.org/26022.html.
srs5694f5dfbfa2013-02-14 20:47:14 -050059
60- Added partition type code for Haiku BFS (GUID
61 42465331-3BA3-10F1-802A-4861696B7521; code EB00).
62
srs56940741fa22013-01-09 12:55:40 -0500630.8.6 (1/9/2013):
64-----------------
65
66- Fixed a bug that could cause sgdisk to crash when passing a partition
67 number of 0 to the -t option.
68
69- Added support for building under Solaris.
srs5694d8eed462012-12-15 01:55:21 -050070
71- Added a new check to the verification code.
72
73- Added partition type code for Sony system partition
74 (F4019732-066E-4E12-8273-346C5641494F). I'm not entirely clear what this
75 is used for, but it's appearing on some new Sony computers.
76
77- Tweaked hybrid MBR creation options to fix a problem that caused the main
78 0xEE MBR partition to NOT be created if the user told gdisk to NOT place
79 it at the start of the disk AND IF fewer than three partitions are
80 hybridize AND IF the user opted to create a second protective partition.
81
82- Changed default build options for Mac OS X to *NOT* use libicu,
83 since it seems to have broken somewhere along the line. It still
84 works on Linux, though.
85
86- Added partition type codes for VMWare ESX (FB00, FB01, and FC00).
87
srs56944307ef22012-05-30 12:30:48 -0400880.8.5 (5/30/2012):
srs5694fa3868e2012-03-28 01:45:57 -040089------------------
90
srs56944307ef22012-05-30 12:30:48 -040091- Changed code that writes the partition table so that a disk sync
92 operation occurs even if one or more write operations failed (but not if
93 they all failed). This is intended to work around a bug that a user
94 reported on a Windows system on which the write of the protective MBR
95 failed, although everything else worked. (I suspect anti-virus software
96 may have been blocking write access to the MBR.)
97
srs5694fa3868e2012-03-28 01:45:57 -040098- Added type codes for Midnight BSD (0xA580 - 0xA585). I used these codes
99 because Midnight BSD uses the same 0xA5 type code as FreeBSD on MBR
100 disks, so I'm starting Midnight BSD's numbering halfway through the
101 0xA5## range.
102
srs5694a6297b82012-03-25 16:13:16 -04001030.8.4 (3/25/2012):
104------------------
105
106- REALLY fixed Ctrl+D problems! Now gdisk terminates upon receiving a
107 Ctrl+D. In all previous versions, it could lock itself into a CPU-hogging
108 loop if launched via "sudo" from a terminal window that was then closed
109 or if Ctrl+D was pressed at certain input prompts (for a partition name
110 or sector number, for instance).
111
srs569434882942012-03-23 12:49:15 -04001120.8.3 (3/23/2012):
srs5694e842bc12012-02-03 11:27:05 -0500113------------------
114
srs569434882942012-03-23 12:49:15 -0400115- Fixed compilation problem on GCC 4.7.
116
117- Improved handling of Ctrl+D on some systems.
118
119- Added disk's name to message stating that a disk write was successful.
120
121- Fixed bug that caused creation of >2TiB partitions on 32-bit systems to
122 be truncated in sgdisk.
srs5694e842bc12012-02-03 11:27:05 -0500123
1240.8.2 (1/22/2012):
srs5694dcebe572012-01-22 15:03:42 -0500125------------------
srs56940541b562011-12-18 16:35:25 -0500126
srs5694706e5122012-01-21 13:47:24 -0500127- Adjusted the code to support a number of partitions that's not a multiple
128 of the number of partition table entries that fits in a sector (normally
129 4 per sector). The program still rounds up, when necessary, when resizing
130 the partition table manually, but not when loading a partition table that
131 contains a peculiar number of partitions. This helps prevent spurious
132 error messages about CRC problems when loading some Solaris partition
133 tables.
134
srs5694e69e6802012-01-20 22:37:12 -0500135- Fixed bugs relating to the handling of empty partitions; Solaris's ZFS
136 tools create weird empty partitions that are legal but that gdisk wasn't
137 handling properly. (Specifically, they sometimes have non-zero end
138 points; gdisk assumed empty partitions had end points of 0.)
139
srs56940541b562011-12-18 16:35:25 -0500140- Fixed a bug that caused an infinite loop of input prompts if the user
141 pressed Ctrl+D.
142
143- Changed gdisk's first-sector input operation to specify a sector number
144 that's properly aligned as the default value. This eliminates the need
145 to alter that value and notify the user of the change when the user
146 hits "Enter" for the default value as the first partition on an empty
147 disk (as well as in some other situations).
148
srs569423d8d542011-10-01 18:40:10 -04001490.8.1 (10/1/2011):
srs5694d1b11e82011-09-18 21:12:28 -0400150------------------
151
srs569423d8d542011-10-01 18:40:10 -0400152- Fixed bug that could cause FixParts to keep a partition's assignment
153 as logical when FixPart could not actually do so. This could happen
154 when there are no gaps between two logical partitions. Some partitioning
155 tools can create such configurations, but FixParts can't. Such
156 configurations are extremely rare. I've only encountered them when
157 logical partitions are out of order.
158
159- Added code to detect infinite loops of logical partitions when reading
160 MBR data. When detected, the program now stops reading after the first
161 loop, so no duplicates appear in the partition list.
162
163- Fixed bug in partition overlap detection in MBR code.
164
srs5694d1b11e82011-09-18 21:12:28 -0400165- Changed GPT reading code to use the size encoded in GPT headers to
166 determine how much of the header to use in computing a CRC, with the
167 restriction that the size be equal to or less than the disk's sector
168 size. This should work around problems with libefi in ZFS, which sets the
srs569423d8d542011-10-01 18:40:10 -0400169 header size to 512 rather than the more common 92. A caveat: If the
170 disk's sector size is larger than the GPTHeader data structure size (512
171 bytes), then the rest of the sector's contents are ignored and replaced
172 with 0 values. This could produce false positives on CRC checks on disks
173 with over-512-byte sector sizes if the header sector is padded with
174 something other than 0 values.
srs5694d1b11e82011-09-18 21:12:28 -0400175
176- Fixed bug in new (as of 0.8.0) check that main and backup partition
177 tables are identical on big-endian (PowerPC, etc.) hardware.
178
srs5694a17fe692011-09-10 20:30:20 -04001790.8.0 (9/10/2011):
180------------------
181
182- Added new return option for sgdisk: 8, which means that a replication
183 operation (-R or --replicate) failed. Note that other operations on
184 the same command line might still have succeeded.
185
186- Added gdisk_test.sh shell script, contributed by Guillaume Delacour.
187 This script tests some common gdisk and sgdisk operations to be sure
188 they're working correctly.
189
190- Enable sgdisk's -l (--load-backup) and -o (--clear) options to work
191 even on disks that are damaged. Most other options will still be ignored,
192 though, so if you suspect a disk may be bad and want to use one of these
193 options, you should do so on a line by itself, followed by a separate
194 command to perform other actions (such as adding new partitions).
195
196- Added check for mis-matched primary and backup partition tables.
197 A mismatch is reported as a CRC error.
198
199- Added Apple Core Storage partition type code (hex code AF05, GUID
200 53746F72-6167-11AA-AA11-00306543ECAC).
201
202- Added cgdisk program to the family. This program is a rough workalike
203 to cfdisk, much as gdisk is a rough workalike to fdisk. See the cgdisk
204 man page or http://www.rodsbooks.com/gdisk/cgdisk-walkthrough.html for
205 details about its operation.
206
207- Fixed bug that caused CHS end point for protective MBR to be set to
208 0xfeffff rather than the spec-mandated 0xffffff on disks over ~8GB. This
209 is a very minor bug, since not much cares about this, and most other GPT
210 tools get it wrong in the same way, too.
211
srs569400b6d7a2011-06-26 22:40:06 -04002120.7.2 (6/26/2011):
srs56946aae2a92011-06-10 01:16:51 -0400213------------------
214
srs569400b6d7a2011-06-26 22:40:06 -0400215- The Windows version now (finally!) generates proper GUIDs rather than a
216 purely random number. This fixes a bug that caused Windows 7 to crash
217 when converting a disk from MBR format (but, oddly, not when creating a
218 fresh partition table or doing various other things).
219
220- Added a warning when an MBR partition is discarded because it's too
221 big for the disk.
222
223- Changed warning to Windows users about the dangers of converting to GPT
224 so that it appears only on disks that aren't already in GPT form.
225
226- Fixed bug that caused bogus "3" values to pad the ends of partition names
227 on some disks (particularly those created by Microsoft's disk
228 partitioning tools).
229
230- Made compilation without Unicode support possible (see README file)
231
232- Made default filesystem type code OS-dependent (based on the compilation
233 platform).
234
235- Added new Linux-only filesystem partition type GUID code,
236 0FC63DAF-8483-4772-8E79-3D69D8477DE4 (8300 entry code). Also changed name
237 of the EBD0A0A2-B9E5-4433-87C0-68B6B72699C7 (0700 entry code) to
238 "Microsoft basic data").
239
srs56946aae2a92011-06-10 01:16:51 -0400240- Fixed a bug that caused an incorrect code to be set for active/bootable
241 partitions when generating a hybrid MBR.
242
243- Enable entry of hex codes that begin with "0x" for both GPT and MBR
244 partitions.
245
246- Fixed bug that caused the boot loader code to be lost when creating a
247 hybrid MBR.
248
249- Fixed bug in sector input code that could produce improper values
250 if the user inputs ridiculously large "+" values.
251
srs5694699941e2011-03-21 21:33:57 -04002520.7.1 (3/21/2011):
253------------------
254
255- Added support for proper UTF-16LE partition names rather than the
256 "shortcut" that properly encoded only ASCII names. This support works
257 only in Linux, FreeBSD, and OS X, though, at least for the moment.
258 Although it's possible to compile this support into Windows when using
259 Visual C++, it doesn't seem to work properly. Since using this feature
260 would require distributing the ICU libraries with the Windows binary,
261 thus bloating the binary package's size to no effect, I've disabled it in
262 my standard Windows build, at least for now.
263
264- Added check to fixparts to keep it from operating on devices that
265 lack an existing MBR signature. (In 0.7.0, it could write an empty
266 MBR data structure to a device on which it was mistakenly launched.)
srs5694d3ba7a62011-03-13 11:51:34 -0400267
srs5694815fb652011-03-18 12:35:56 -0400268- Fixed bug that caused the protective MBR to not be written when
269 restoring a backup of the GPT data.
270
srs56945a608532011-03-17 13:53:01 -0400271- Fixed bug that caused second protective MBR partition, when created
272 as part of a hybrid MBR, to always be of type 0xEE, even when the
273 user specified something else.
274
srs5694c2f6e0c2011-03-16 02:42:33 -0400275- Integrated a number of code cleanups contributed by Florian Zumbiehl.
srs5694d3ba7a62011-03-13 11:51:34 -0400276
srs5694bf8950c2011-03-12 01:23:12 -05002770.7.0 (3/11/2011):
srs569464cbd172011-03-01 22:03:54 -0500278------------------
279
srs5694bf8950c2011-03-12 01:23:12 -0500280- Fixed bug that caused some types of logical partitions to be misread.
281
282- Created FixParts program, to fix problems on MBR-partitioned disks.
283 Although this program is part of the GPT fdisk family, it is NOT used on
284 GPT disks.
285
286- Completely redid the GPT-to-MBR code, used both for converting to MBR
287 form and for creating hybrid MBRs.
288
289- Fixed a bug that caused gdisk to "forget" some partitions if there were
290 numbering gaps when a conversion to MBR was aborted.
291
292- Improved CHS value creation on small (<~8GB) disks for protective MBR
293 and when creating hybrid MBRs or converting to MBR format. Linux-only,
294 for the moment; other platforms still produce bad CHS values on sub-~8GB
295 disks (but few OSes care these days).
296
srs569464cbd172011-03-01 22:03:54 -0500297- Enhanced disk replication features ('u' on the experts' menu in gdisk; -R
298 or --replicate in sgdisk). It's now possible to replicate the partition
299 table from a larger to a smaller disk, so long as all the partitions fit
300 on the smaller disk. In sgdisk, the secondary GPT data are moved
301 automatically if disk sizes don't match. In gdisk, the secondary GPT data
302 are moved automatically if the target disk is smaller than the source
303 disk; if the target disk is larger than the source disk, the user is
304 given the option of making this adjustment.
305
306- Fixed --load-backup (-l) option to sgdisk, which was broken.
307
308- Changed largest drive that's not given a minimum 4 KiB alignment even
309 when smaller alignment is detected on the disk to 300 GB.
310
srs5694bf8950c2011-03-12 01:23:12 -0500311- Fixed bug that prevented aborting a partition table backup ('u' on the
srs569464cbd172011-03-01 22:03:54 -0500312 experts' menu) by hitting the Enter key for the device filename.
313
srs5694bf8950c2011-03-12 01:23:12 -0500314- Implemented a number of code cleanups provided by Florian Zumbiehl.
srs569464cbd172011-03-01 22:03:54 -0500315
srs5694df9d3632011-01-08 18:33:24 -05003160.6.14 (1/8/2011):
317------------------
318
319- Made small change to the way the start sector is interpreted if you use a
320 "+" specification, as in "+2G" to locate a partition 2 GiB into the
321 default range. This change makes adjustments for sector alignment less
322 likely.
323
324- Modified sgdisk's -n (--new) option to work with relative start and end
325 values (which the man page incorrectly stated it already did). Values of
326 0 for the start and end sectors refer to the first and last available
327 sectors in the largest free block, and a partition number of 0 refers to
328 the first available partition.
329
330- Added ChromeOS GUID values to list of recognized partition type GUIDs.
331 7F00 = ChromeOS kernel, 7501 = ChromeOS root, 7502 = ChromeOS reserved.
332 Untested on actual ChromeOS system.
333
334- Tweaked APM detection to look for APM signature even if an MBR
335 signature has already been found. Helps in diagnosis of cases
336 in which an MBR has overwritten an APM disk.
337
srs5694058d4a52010-10-12 12:42:47 -04003380.6.13 (10/12/2010):
339--------------------
340
341- Added notification about nonexistent partitions to hybrid MBR creation
342 in gdisk.
343
344- Fixed bug in GPT-to-MBR conversion that could sometimes enable creation
345 of an extended partition that overlaps a preceding partition.
346
347- Fixed bug in GPT-to-MBR conversion that prevented creation of an MBR
348 table with logical partitions if there were four or fewer partitions.
349
srs56940873e9d2010-10-07 13:00:45 -04003500.6.12 (10/7/2010):
351-------------------
352
353- Adjusted alignment code to use 1 MiB alignment by default for drives with
354 other than 512-byte sector sizes. (Previous versions increased this --
355 for instance, to 4 MiB for drives with 2048-byte logical sector size.)
356
357- Entry of non-hexadecimal value for partition type code now causes
358 re-prompting for a new value, fixing a recently-introduced minor bug.
359
360- Fixed bug in sector entry using K/M/G/T/P suffixes on disks with
361 other-than-512-byte sector numbers.
362
363- Added "P" (PiB, pebibyte) suffix to suffixes accepted in entering
364 partition sizes.
365
366- Fixed bug that caused sgdisk to segfault if fed the (invalid)
367 "-A show" parameter. Now it terminates with a complaint about an invalid
368 partition number 0.
369
370- Removed warning when running on big-endian hardware, since this
371 support has been present for quite a while with no bug reports.
372
srs5694ab4b0432010-09-25 20:39:52 -04003730.6.11 (9/25/2010):
374-------------------
375
376- Added -F (--first-aligned-in-largest) option to sgdisk. This option is a
377 variant on -f (--first-in-largest); it returns the number of the first
378 sector that will be used in the largest free area, given the current
379 alignment value (set via -a/--set-alignment).
srs5694659eaf12010-08-23 11:26:12 -0400380
srs56945a081752010-09-24 20:39:41 -0400381- Streamlined GUID code entry in gdisk; it no longer offers the option
382 to enter GUIDs in separate segments.
srs569482f3f0b2010-09-22 10:50:24 -0400383
srs5694327129e2010-09-22 01:07:31 -0400384- The -t option to sgdisk now accepts GUID values as well as the
385 sgdisk/gdisk-specific two-byte hex codes.
386
387- Added check that the protective 0xEE MBR partition begins on sector 1
388 to the verify function. If it doesn't, a warning message is displayed,
389 but it doesn't count as an error.
390
391- Added check for overlapping MBR partitions to verify function (gdisk "v"
392 function on all menus; sgdisk -v/--verify function). Also warns about
393 multiple MBR 0xEE partitions (causes problems in some OSes).
394
395- Added check to GPT-to-MBR and hybrid MBR creation options to prevent
396 creation of disks with duplicate partitions. When told to create a disk
397 with duplicates, sgdisk now aborts with the error message "Problem
398 creating MBR!" When attempting to create a hybrid MBR with duplicates,
399 gdisk silently drops duplicate partitions, leaving fewer than requested.
400 Creating duplicates should not be possible in sgdisk when converting to
401 MBR form.
srs5694659eaf12010-08-23 11:26:12 -0400402
srs56949ddc14b2010-08-22 22:44:42 -04004030.6.10 (8/22/2010):
404-------------------
srs5694f9312b02010-07-06 15:39:51 -0400405
srs56949ddc14b2010-08-22 22:44:42 -0400406- Enable disk-wipe (-z and -Z) and verification (-v) operations in
407 sgdisk even if the disk is badly damaged.
408
409- Added support for setting attributes in sgdisk (-A/--attributes option)
410 in sgdisk.
411
412- Fixed bug that created backwards attribute field values (bit #2 was
413 entered as bit #61, etc.).
414
415- Fixed bug that caused creation of hybrid MBR to wipe out the MBR's boot
416 code.
417
418- Added ability to save partition table from one device to another (gdisk:
419 'u' on experts' menu; sgdisk: -R or --replicate option).
420
421- Fixed inaccessible -C/--recompute-chs option in sgdisk.
srs5694f9312b02010-07-06 15:39:51 -0400422
srs569461768bc2010-07-04 01:54:00 -04004230.6.9 (7/4/2010):
424------------------
425
426- Fixed minor error in sgdisk man page (--largest-new option requires
427 a partition number).
428
429- Fixed major bug in hybrid MBR creation, which caused incorrect
430 protective partition end point settings and occasionally other
431 problems.
432
srs56940e197dc2010-05-23 13:06:10 -04004330.6.8 (5/23/2010):
434------------------
435
srs569461768bc2010-07-04 01:54:00 -0400436- Added tests to see if the file to be opened is a directory, character
437 device, FIFO, or socket; program now terminates if any of these
438 conditions is met. (Linux/FreeBSD/OS X only.) Thanks to Justin Maggard
439 for this patch.
srs56940e197dc2010-05-23 13:06:10 -0400440
441- Added 'f' option on gdisk's experts' menu (-G/--randomize-guids in
442 sgdisk). This option randomizes the disk's GUID and all partitions'
443 GUIDs. Intended for use after cloning a disk with a utility that copies
444 the GUIDs intact (such as a raw dd copy) if you want each disk copy to
445 have its own set of GUIDs.
446
447- Added -u/--partition-guid and -U/--disk-guid options to sgdisk. These are
448 the equivalents of the 'g' and 'c' options, respectively, on the gdisk
449 experts' menu: They enable adjusting an individual partition's GUID or a
450 disk's GUID. The GUID may be either a fully specified GUID value or 'R'
451 or 'r' to set a random GUID value.
452
453- Fixed compile problem for FreeBSD (its math library lacks a log2()
454 function). Also created separate Makefile.freebsd with a couple of
455 FreeBSD-specific options.
456
457- Added -N (--largest-new) command to sgdisk. This command creates a single
458 partition that fills the largest single unpartitioned block of space on
459 the disk.
460
461- Fixed sgdisk man page error: the --change-name option was incorrectly
462 listed as --change.
463
464- Added 'h' option to gdisk experts' menu (-C or --recompute-chs in sgdisk)
465 to recompute all protective/hybrid MBR CHS values. This option is
466 intended to work around a bug in at least one BIOS that prevents the
467 computer from booting when the GPT-mandated (but technically illegal)
468 0xFFFFFF CHS value is used as the end point for a protective MBR. The
469 recomputed values will be legal (e.g., 0xFEFFFF instead of 0xFFFFFF),
470 but incorrect in GPT terms, and will therefore enable at least one
471 BIOS to boot with a GPT disk. See http://www.rodsbooks.com/gdisk/bios.html
472 for all I know about BIOS/GPT incompatibilities.
473
4740.6.7 (5/1/2010):
475-----------------
476
477- Undid earlier change, with version 0.6.4, that wiped the MBR boot loader
478 when doing MBR-to-GPT conversions. I've now become skeptical that MBR
479 boot loaders were causing any real problems on GPT disks, so I'm going
480 back to the philosophy of leaving as much alone as possible.
481
482- Fixed bug that caused incorrect reporting of free space on 0-size disks
483 (e.g., files of 0 length passed as disk images).
484
485- Fixed bug that caused segfault on some invalid disks
486
487- Fixed bug that caused incorrect partition numbers to be displayed for
488 some verify problems.
489
490
4910.6.6 (3/21/2010):
492-----------------
493
494- Added support for the "no block IO protocol" (referred to as "hide from
495 EFI" in GPT fdisk) and "legacy BIOS bootable" attribute bits. See Table
496 19 of the UEFI 2.3 specification (p. 153) for details.
497
498- Changed the sequence in which GPT data structures are written to disk;
499 backups are now written first, followed by the main structures. This is
500 as recommended in the UEFI 2.3 specification, since it's safer in the
501 extremely unlikely event that a RAID array's size is increased and
502 there's a power outage mid-write. (If the main structures are written
503 first in this case, they'll point to data that's not yet been written;
504 but by writing the backups first, the old main structures will still
505 point to the valid old backup structures.)
506
507- Protective MBRs now have disk signatures of 0x00000000, to better
508 conform with GPT as described in the UEFI 2.3 specification.
509
510- Added alignment information to the summary data produced by the
511 'p' main-menu option in gdisk or the -p option to sgdisk.
512
513- More alignment changes: GPT fdisk now attempts to determine the alignment
514 value based on alignment of current partitions, if any are defined. If no
515 partitions are defined, a default value of 2048 is set. If the computed
516 value is less than 8 on drives over about 596GiB, it's reset to 8, since
517 the drive might be a WD Advanced Format unit that requires an 8-sector
518 (or larger power-of-2) alignment value for best performance. The
519 2048-sector default provides better alignment in some RAID
520 configurations.
521
522- Changed behavior when a backup restore fails. Previously, GPT fdisk
523 would create a fresh blank set of partitions. Now it does so only
524 if the failure occurs when interpreting the backup's contents; if the
525 user typed the wrong filename, the in-memory data structures aren't
526 touched.
527
528
5290.6.5 (3/7/2010):
530-----------------
531
532- Added tests to verify ('v') function and to pre-save checks to look for
533 partitions that end before they begin or that are too big for their
534 disks.
535
536- Fixed a bug that could cause spurious data to appear in a grown partition
537 table.
538
539- Added ability to convert some or all partitions to logical partitions in
540 GPT-to-MBR conversion. This feature is limited by the fact that at least
541 one free sector must exist immediately prior to each logical partition,
542 so it won't do much good if partitions are crammed together. It should be
543 possible to convert back to MBR any disk that started that way, provided
544 no partitions were added or resized when the disk was in GPT form; and
545 disks that were partitioned with Apple's Disk Utility or other tools that
546 insert unpartitioned space should also be convertible. CAUTION: THE
547 LOGICAL PARTITION CREATION FEATURE DOESN'T TRY TO ALIGN PARTITIONS OR
548 PARTITION HEADER DATA TO CYLINDER BOUNDARIES! It's conceivable that some
549 older OSes or utilities will object to these disks, although Linux, OS X,
550 Windows Vista, and Windows 7 all seem happy with them.
551
552- Fixed bug that caused creation of 0-length file if an incorrect device
553 filename was typed.
554
555- The gdisk program now prompts for a device filename if it's called with
556 no options. This enables gdisk to do something useful if it's launched by
557 double-clicking its icon in a GUI environment.
558
559- Added workaround for bug in some versions of MinGW that caused the
560 program to garble input sector numbers.
561
562- The Windows version now works on disks with over-512-byte sectors.
563 Tested on a magneto-optical (MO) drive with 2048-byte sectors.
564
565- Added -D (--display-alignment) option to sgdisk, to display sector
566 alignment value (by default, 1 for sub-800GiB disks and 8 for disks
567 over that size).
568
569- Fixed bug in computation of CHS geometries for protective MBR. This is
570 non-critical, since most modern utilities ignore the CHS geometries.
571 Concerned users can use the 'n' option on the experts' menu to build new
572 protective MBRs with the new algorithm, if desired. (Note that GNU
573 Parted, at least, gets this wrong, too.)
574
575- Fixed memory-allocation bug when reading GPT disks with partition tables
576 with over 128 entries; could cause program to crash on startup.
577
5780.6.4-2 (2/20/2010):
579--------------------
580
581Note: Neither of the following changes affects actual program code, so I've
582left the version number in the program at 0.6.4.
583
584- Altered Makefile to pass user's compiler and linker environment
585 variables through.
586
587- Added #include to gpttext.cc to enable it to compile on the latest
588 GCC versions (it was failing on at least some 4.4.x compilers).
589
5900.6.4 (2/19/2010):
591-------------------
592
593- Added -m (--gpttombr) option to sgdisk, enabling conversion of GPT
594 disks to MBR format, with a limit of four partitions total, and of course
595 without overcoming the 2TiB limit.
596
597- Added -h (--hybrid) option to sgdisk, enabling creation of hybrid
598 MBRs. Fewer options are available in sgdisk than in gdisk, though,
599 in order to keep the user interface manageable.
600
601- Fixed off-by-one bug in specification of partition when using the
602 -T (--transform-bsd) option in sgdisk.
603
604- Changed the code to create a new MBR unique disk signature whenever a new
605 protective MBR is generated (when doing an MBR-to-GPT conversion, when
606 using the 'n' option on the experts' menu, or when using the 'o' option
607 on the main menu, for example). Previous versions attempted to preserve
608 the existing MBR disk signature in most cases, but this resulted in
609 values of 0x00000000 whenever an empty disk was partitioned, and often in
610 other cases, too. Better to risk changing this value too often than to
611 leave multiple disks with 0x00000000 values, I think.
612
613- Added transpose ('t' on experts' menu in gdisk; or -r or --transpose in
614 sgdisk) command to enable fine-tuning partition order without doing a
615 full sort.
616
617- Added code to clear the MBR boot loader when doing an MBR-to-GPT
618 conversion. (This was already done in full-disk BSD-to-GPT conversions.)
619 This is done because I've seen a few problem reports that make me think
620 some MBR boot loaders freak out and hang the system when they encounter
621 GPT disks, and/or they attempt to load a second-stage boot loader stored
622 in what is now GPT territory, causing a system hang. Since MBR boot
623 loaders don't work on GPT disks anyhow (even GRUB needs to be
624 reinstalled), this new wiping behavior shouldn't cause any problems, and
625 may prevent a few.
626
627- Fixed bug in Windows version that prevented saving backup files.
628
629- Fixed bug that caused second and subsequent partition numbers in
630 prompts in hybrid MBR conversion procedure to be displayed in
631 hexadecimal.
632
633- Fixed very obscure potential bug in hybrid MBR/GPT synchronization when
634 deleting partitions; code wasn't matching partition lengths correctly,
635 which would only affect partitions that start at the same point but have
636 different lengths in MBR vs. GPT.
637
638- Fixed bug in the -E option to sgdisk; it was actually returning the
639 last free sector, not the last free sector in the largest free block.
640
641- Fixed bug in -t option to sgdisk; it was corrupting partition type
642 codes.
643
644- Fixed minor alignment bug in partition summary list ('p' from any menu)
645 when partition sizes are between 1000 and 1024 units.
646
647- Backup restore function ('l' on recovery & transformation menu) now
648 accepts both backups generated by GPT fdisk and backups created by a
649 direct copy (via dd, etc.) of the MBR, main GPT header, and main GPT
650 partition table, in that order. ("dd if=/dev/sda of=backup.gpt bs=512
651 count=34" will do this on Linux for a disk with a typical-sized GPT table
652 of 128 entries.)
653
6540.6.3 (2/3/2010):
655------------------
656
657- Fixed serious data corruption bug on big-endian (PowerPC and similar)
658 systems.
659
660- Changed several GPT fdisk Solaris type codes to correct a duplicate
661
662- Corrected error in GPT fdisk type codes for NetBSD LFS and NetBSD RAID;
663 they were identical, but I've now changed NetBSD RAID to A906, which
664 is unique.
665
666- Added GUID for IBM General Parallel File System (GPFS) partition type
667 code. Somewhat arbitrarily set it to use the 7501 number (MBR code 0x75
668 is used by IBM PC/IX, so it's at least the right company, by my loose
669 numbering rules....).
670
671- Improved GUID generation. Prior versions generated completely random
672 numbers for GUIDs. This works, but is technically a violation of the
673 spec. Unix versions now employ libuuid to generate GUIDs in a more
674 correct way. The Windows version still generates random numbers, though.
675
676- Turned PartTypes class into a derived class of GUIDData, and renamed
677 it to PartType.
678
679- Created new GUIDData class, to replace the original GUIDData struct.
680
6810.6.2 (1/29/2010):
682------------------
683
684- The change-type ('t' on main menu) option now changes the partition's
685 name *IF* the current name is the generic one for the partition type.
686 If the current name is not the generic name, it is NOT changed.
687
688- Fixed bug that caused new protective MBR to not be created when the
689 MBR was invalid and the GPT was damaged and the user opts to try to
690 use the GPT data.
691
692- Enabled default partition type code of 0700 when creating partitions
693 or changing their type codes. (Type 0700, Linux/Windows data, is set if
694 the user hits the Enter key alone.)
695
696- Fixed bug in sort ('s' on main menu) option that caused partition
697 numbers to begin at more than 1 if the original partition list had
698 too many empty partitions before the last one defined.
699
700- Improved code to determine which partition table to load in case of
701 CRC mismatches between the partition tables and the stored CRC values
702 in the headers.
703
704- Compiles using MinGW (http://www.mingw.org) to create a Windows binary.
705
706- Moved all disk I/O functions to the new DiskIO class. This helps with the
707 Windows port; it uses diskio-windows.cc for Windows-specific code,
708 diskio-unix.cc for the Linux, FreeBSD, and OS X code, and diskio.cc for
709 cross-platform disk I/O code.
710
711- Changed BSD disklabel detection code to be more correct (I think).
712 This change has no effect on my test disks, but I hope it'll work
713 better on disks with sector sizes other than 512 or 2048.
714
7150.6.1 (1/20/2010):
716------------------
717
718- Fixed bug that returned incorrect disk size on 32-bit versions of
719 FreeBSD.
720
721- Fixed bug that prevented FreeBSD version from working on disk image
722 files.
723
724- Fixed bug that caused BSD disklabel conversion to fail.
725
7260.6.0 (1/15/2010):
727------------------
728
729- Fixed bug that caused the convert to MBR function to fail.
730
731- Added support for disks with other than 512-byte sectors.
732
733- Created embryonic sgdisk program.
734
735- Fixed bug that caused relative sector numbers entered by users (e.g,
736 "+128M") to be misinterpreted as from the start of the range rather than
737 from the default value.
738
7390.5.3 (1/4/2010):
740-----------------
741
742- Fixed bug in display of GUIDs when compiled with some versions of GCC.
743
744- Eliminated warnings caused by additional checks in latest versions of
745 GCC. These warnings were harmless, but to eliminate them I've added
746 more error checking on disk I/O.
747
748- Eliminated unnecessary warnings about potential data loss if the program
749 was launched with the -l option or if writes aren't possible.
750
751- Added code to set the partition boundary value based on the physical
752 sector size. (FindAlignment() function.) This function, however, works
753 only on Linux, and then only if the BLKPBSZGET ioctl is defined. This
754 ioctl is new in kernel 2.6.32 or thereabouts.
755
7560.5.2 (12/31/2009):
757-------------------
758
759- Modified partition creation function to begin partitions on 8-sector
760 boundaries by default. This improves performance on the new Western
761 Digital Advanced Format drives. The new 'd' and 'l' options on the
762 experts' menu display and change, respectively, the boundary size.
763
764- Tweaked code to produce fewer warnings on the latest versions of
765 GCC.
766
7670.5.1:
768------
769
770- Made some minor edits to the man page.
771
772- Incorporated RPM .spec file changes contributed by Scott Collier
773 (boodle11@gmail.com).
774
775- Changed method of locating and loading backup GPT data, to use the
776 main header's pointer, if it's valid, rather than seeking to the
777 end of the disk.
778
779- Added 'e' option (relocate backup GPT data structures) to the experts'
780 menu.
781
782- Fixed bug that prevented recovery of partitions in case of partially
783 damaged GPT data (bad main and good backup or bad backup and good
784 main header, for instance).
785
7860.5.0:
787------
788
789- Added GPT-to-MBR conversion function. It's very limited, but potentially
790 useful in some cases.
791
792- Fixed bug that caused incorrect file sizes to be reported on 32-bit
793 Linux, thus causing problems when editing partition tables in disk images
794 or when loading GPT backup files.
795
796- Fixed bug that caused bogus CRC error reports when loading backup GPT
797 data.
798
799- Reorganized menus. There are now three: the main menu, the experts' menu,
800 and the recovery & transformation menu. The last of these has most of the
801 items that had been on the earlier versions' experts' menu.
802
803- Added ability to re-load the MBR and generate a fresh GPT from it. This
804 is normally identical to quitting and re-running the program, but it
805 could be handy if, say, the GPT partitions on a hybrid configuration are
806 badly messed up; this will enable using the hybridized partitions as the
807 starting point for a new GPT setup.
808
809- The program now generates CHS values for hybrid and GPT-to-MBR conversion
810 MBRs. For the moment, the assumption is the maximum number of heads and
811 sectors per track (255 and 63, respectively), although the bulk of the
812 code supports other values -- it'd just be awkward to enter the data in
813 the user interface.
814
815- Fixed minor display bug that caused number of sectors on the disk to be
816 shown as 0 on large disks when running 32-bit binaries.
817
818- Reverted 0.4.2's zap (destroy GPT) changes, since I don't want to wipe
819 out a valid MBR if the user created that MBR over an older GPT without
820 first properly wiping out the GPT, and the user now wants to wipe out
821 the GPT.
822
823- Reformatted and edited the man page. Aside from edits related to the
824 preceding program changes, I've altered the markup slightly and trimmed
825 much of the more tutorial information from the man page to better
826 conform to typical terse man page style.
827
8280.4.2:
829------
830
831- Code cleanup.
832
833- Fixed very small formatting bug in display of hex code when a match isn't
834 found when converting from an MBR/gdisk hex code to a GUID type code.
835
836- Added the ability to work on disk image files (raw files for virtual
837 machines, backup images, etc.). The program assumes that all such disk
838 image files have 512-byte sectors.
839
840- Added verification prompt to 'o' main-menu option to avoid accidental
841 erasures of all partitions.
842
843- The "destroy GPT data structures" option ('z' on the experts' menu) now
844 also destroys all EFI GPT (0xEE) partitions in the MBR.
845
846- Added an extra warning to the "destroy GPT data structures" option if an APM
847 or BSD disklabel was detected on the disk.
848
849- Added a buffer flush after destroying GPT data structures, to get the OS
850 to read the new (empty or MBR-only) partition table.
851
852- Fixed bug that allowed entry of nonexistent partition numbers when creating
853 a hybrid MBR.
854
8550.4.1:
856------
857
858- Code cleanup/re-organization
859
860- Partition creation function ('n' on main menu) now uses the start of the
861 largest available chunk of free space rather than the first available
862 sector as the default starting sector number. This should enable easier
863 partition creation if there are small bits of free space on the disk.
864
865- You can now specify the end point of a partition by using a minus sign,
866 in which case the end point is the default value minus the specified
867 size. For instance, "-200M" creates a partition that ends 200MiB before
868 the default end point.
869
870- You can now specify the start point of a partition by using a plus or
871 minus sign, in which case the start point is the specified distance from
872 the start (+) or end (-) of free space. This is exactly the same as the
873 new rules for entry of the end point, except that the default value is
874 set differently.
875
876- Deleting a partition now checks for a matching hybrid MBR partition, and
877 if one is found, it's deleted. Any empty space that then surrounds the
878 0xEE (EFI GPT) MBR partitions is then added to the nearby 0xEE partition.
879 If no non-0xEE partitions are left, a fresh protective MBR is generated.
880
881- Added hybrid MBR consistency check to the verify ('v') option and to
882 pre-write checks. If non-0xEE/non-0x00 MBR partitions without
883 corresponding GPT partitions are found, the user is warned. This finding
884 does NOT prevent writing the partition table, though.
885
886- Added non-destructive write test when opening the device file, in order
887 to detect the problem with FreeBSD being unable to write to disks with
888 mounted partitions (or other potential problems).
889
8900.4.0:
891------
892
893- Added support for BSD disklabels. The program can now convert disks that
894 use "raw" disklabels, with the caveat that the first partition will
895 almost certainly need to be deleted because it'll overlap the main GPT
896 header; and convert disklabels contained within a GPT (or a former MBR,
897 converted to GPT) partition. In the latter case, the 'b' main menu option
898 is used.
899
900- Added support for compiling on FreeBSD.
901
902- Fixed bug that could cause crashes or incomplete sorts when sorting
903 the partition table.
904
905- New partitions, including converted ones, now take on the name of the
906 partition type as a default name.
907
908- Reorganized some code; created a separate C++ class for GPT partitions
909 (GPTPart), which replaced a struct and enabled moving code from the
910 bloated GPTData class into GPTPart.
911
912- Fixed a bug that produced spurious warnings about unknown sector sizes
913 when loading a backup file.
914
9150.3.5:
916------
917
918Note: This version was not officially publicly released; I wanted to test
919the big-endian support while developing 0.4.0.
920
921- Tweaked the disk type identification code to warn users to re-sync their
922 hybrid MBRs when one is detected.
923
924- Tweaked MBR-reading code to ignore 0xEE (EFI GPT) partitions. This will
925 only have an effect on a poorly partitioned MBR disk that contains an
926 inappropriate EFI GPT partition, or when attempting to recover a
927 corrupted disk by using the hybrid MBR for data recovery.
928
929- Added big-endian (PowerPC, etc.) support!
930
931- Added code to identify and warn of the presence of an Apple Partition
932 Map (APM) on the disk.
933
934- Enabled MBR conversion code to handle multiple logical partitions.
935
9360.3.4:
937------
938
939- Fixed bug that enabled (possibly accidental) entry of MBR type codes of
940 0x00 in GPTData::MakeHybrid(). The fix also enables entry of default
941 type code by pressing the Enter key when prompted. Applied a similar
942 fix to the entry of the type code for the second protective partition,
943 if one is used.
944
945- Fixed a typo: "sectors" was spelled "sectprs" in one spot!
946
947- Fixed bug that caused default entry for end sector to be refused if an
948 initial value using a plus sign (e.g., "+20G") was also refused.
949
9500.3.3:
951------
952
953- Gave users control over the way MBR partitions are assigned to slots in a
954 hybrid MBR setup; the original method (putting the 0xEE partition after
955 the real partitions) works well for non-boot disks, but both GRUB and
956 GRUB2 become confused by this type of setup, so it needs changing.
957
958- Changed "blocks" to "sectors" in GPT and MBR table displays.
959
960- Added "Boot" column to MBR table display; shows an asterisk (*) when the
961 partition's status is bootable.
962
9630.3.2:
964------
965
966- Changed __DARWIN_UNIX03 to __APPLE__ as code to enable MacOS X support.
967
968- Added the ability to create a hybrid MBR ('h' on experts' menu). This was
969 motivated by my discovery that Windows 7 remains brain-dead when it comes
970 to the ability to boot from a GPT disk, at least on BIOS-based machines.
971
972- Added 'z' option to experts' menu, to destroy GPT data structures and
973 exit. The intent is to use this feature to enable subsequent partitioning
974 of the disk using fdisk or other GPT-unaware tools. (GNU Parted will wipe
975 the GPT data structures itself when you create a new MBR ["msdos
976 disklabel," in Parted parlance], so using Parted is another option.)
977
978- Slightly altered the effect of the 'o' command on the main menu. It now
979 blanks out the protective MBR, as well as the GPT data.
980
9810.3.1:
982------
983
984- Added Mac OS X support, provided as a patch by David Hubbard
985 (david.c.hubbard@gmail.com).
986
987- Fixed bug in disksize() function on Mac OS. (Possibly dependent on the
988 kernel and/or GCC version.) The disk size, of type uint64_t, was not
989 being passed correctly, so I reorganized the function to return it as
990 the function's return value rather than as a parameter. This seems to
991 work OK on my Mac OS test system and on both 32- and 64-bit Linux
992 systems.
993
994- Fixed off-by-one bug in GPTData::FindLastAvailable().
995
996- Fixed bug that caused display of options after a disk-write error.
997
998- Fixed several incorrect MacOS X partition type GUIDs, thanks to Yves
999 Blusseau (1otnwmz02@sneakemail.com).
1000
10010.3.0:
1002------
1003
1004- Changed version number to 0.3.0, reflecting the fact that I've received
1005 no significant bug reports and so am elevating the program to "beta"
1006 status. This change also entailed altering the warning the program
1007 displays when saving partition table changes.
1008
1009- Fixed minor bug in CHS geometry of the protective MBR's type EE partition
1010 (was producing 0x000200 as the start value, but should be 0x000100).
1011 Should be a non-critical bug since the protective MBR partition
1012 definition is only there to keep MBR-only disk utilities from messing
1013 with the disk.
1014
1015- Added ability to enter GUIDs as single massive strings rather than in
1016 chunks.
1017
10180.2.2:
1019------
1020
1021- Added #include directives required to compile the program using GCC
1022 4.4.0.
1023
10240.2.1:
1025------
1026
1027- Fixed partition numbering problem in reports of partition overlaps in
1028 verification function.
1029
1030- Fixed 1-sector partition size problem when creating new partitions
1031 (partitions were 1 sector too big when using the +size option).
1032
1033- Changed BytesToSI() to display values in bytes without decimal points
1034 (e.g., "512 bytes" rather than "512.0 bytes").
1035
1036- Added GPTData class member functions to retrieve GPT data structure
1037 locations on disk; used in my internal-use-only GPT-wiping program.
1038
1039- Eliminated the "a reboot is recommended" notice after writing the
1040 partition table.
1041
1042- Added notice after sorting the partition table to the effect that
1043 editing /etc/fstab and/or the boot loader files may be required.
1044
1045- Fixed bug in MBR-reading function that caused 0x0f (Win95 LBA) and 0x85
1046 (Linux extended) extended partitions to not be read.
1047
1048- Fixed bug in GetLastSector() (in support.cc) that would have prevented
1049 correct user entry of over-32-bit sector numbers on 32-bit systems.
1050
1051- Made some changes/corrections to the partition type list in
1052 parttypes.cc. Most of these were based on newly-discovered MBR type
1053 codes for Apple (Mac OS X) filesystems.
1054
1055- General code cleanup (setting explicit casts, etc.)
1056
10570.2.0:
1058------
1059
1060- Initial semi-public release