GDISK – Fixed Disk Partitioning Utility

This document describes GDISK v1.0f-BETA – a Beta release version of the GDISK software product. Although we have taken every step to ensure that this program contains no errors, as with all pre-release software products, the user should not use this version of GDISK with any critical systems or without having first backed up important data.

We are interested in and appreciate receiving your feedback. Please direct any comments or suggestions to

What's New?

GDISK v1.0f-BETA is the second Beta release of the GDISK product. We have received a lot of feedback from users after GDISK 1.0e was released and have now modified the product in response to those suggestions. The following list details the changes made to GDISK since the previous Beta release:

Problems using GDISK with Compaq Computers

Users have reported problems using GDISK with several different models of Compaq computers. The cause of this problem is a fault in the BIOS that makes it appear as if a number of phantom fixed disks are installed. Attempting to read the partition structures from these non-existent fixed disks caused GDISK to display numerous error messages and, in some cases, hang the computer.

We have notified Compaq of this problem and are currently assisting them to resolve it. GDISK is now able to detect this condition and will work correctly even with faulty BIOSes. However, the fault will still exist in the BIOS and this may cause other software packages to fail. Compaq advise us that users who experienced problems with the previous version of GDISK (v1.0e-BETA) should contact them to obtain a BIOS upgrade.

We appreciate the time users have taken to respond to us and their assistance has helped to improve this product. If you have any comments or are having problems, please contact us at


GDISK is intended as a complete replacement for the DOS/Windows 95 FDISK utility. Everything you can do with FDISK you can do with GDISK. The partitions created with GDISK are indistinguishable from those created using FDISK.

GDISK is command-line driven – unlike FDISK which uses interactive menus and prompts – so it is much quicker for configuring a disk’s partition table and does a few extra things that FDISK does not.

Summary of Capabilities

GDISK has six main modes of operation, the first four of which correspond to the menu options in FDISK’s main menu.

  1. Creating partitions - Primary DOS partitions, Extended DOS partitions, Logical DOS drives.
  2. Deleting partitions of any type, including Non-DOS partitions.
  3. Listing current partition information and installed fixed disks.
  4. Activating a partition (nominating it as the bootable partition).
  5. Making existing partitions invisible and visible again.
  6. Reinitializing the Master Boot Record.

Advantages over FDISK

GDISK provides some added capabilities that FDISK does not – such as on-the-fly formatting – and provides a safer alternative in situations where known problems with FDISK can cause data loss and hardware damage.

  1. Command-line driven and much quicker than FDISK. Allows standard configurations to be defined in a batch file and applied to multiple computers.
  2. Gives better disk space utilization. It is much more aggressive in finding free space on the disk for new partitions, and in virtually every case will find space ignored by FDISK (this space can vary between 0.5MB and 16MB). Alternatively the /-CE switch may be specified when creating partitions to force FDISK-compatibility.
  3. Reduces slack space (disk wastage). GDISK is more aggressive than the FORMAT utility provided with Windows 95 in attempting to keep cluster sizes small. For some partition sizes, GDISK is able to format partitions with cluster sizes half the size that FORMAT would select resulting in an effective 10-35% increase in drive capacity.
  4. Allows partitions to be hidden. This can be used to have more than one Primary DOS partition with different versions of DOS/Windows 95 in each partition. Normally it is not possible to have more than one DOS or Windows 95 installation on the same computer. The ability to hide partitions allows the computer to be used to boot into any selected bootable partition ignoring other installations of the same operating system in other partitions.
  5. The FDISK supplied with Windows 95 has a bug that can cause overlapping partitions to be created that will almost certainly lead to corruption of existing partitions. The same bug can also result in partitions that extend past the end of the disk, which can cause permanent damage to the drive when the partition is formatted. This is the one situation in which GDISK does not imitate the exact behavior of FDISK – even with the compatibility switch turned on.
  6. The FDISK supplied with Windows 95 has a bug that means that it is not possible to delete newly created partitions if the drive letter that was provisionally assigned to the new drive matches a drive letter currently assigned to a CD-ROM device. GDISK allows the partitions to be deleted even if the new drive letter is currently assigned.
  7. Useful as a diagnostic tool – extensive integrity verification checks are performed on the partition tables before any operations are performed on the drive.
  8. GDISK can display the partition information in a raw cylinder/head/sector format that may be of use to technicians investigating problems with a computer's partition table.


GDISK has five main modes of operation – creating partitions, deleting partitions, displaying partition information, activating partitions, and hiding partitions. The mode that GDISK operates in is denoted by the switches /CRE, /DEL, /STATUS (the default), /ACT, and /HIDE.

An overview of these modes and their switches may be displayed by using the help switch as follows:

C:\> GDISK /?
Configures fixed disk partitions.

GDISK disk /CRE {/PRI|/EXT|/LOG} [/SZ:mbytes] [/FOR [/Q] [/V[:label]]]
      [/-32] [/-CE] [/X] [/Y]
GDISK disk /DEL {/PRI[:nth]|/EXT[:nth]|/LOG:nth|/P:partn-no|/ALL}
      [/X] [/Y]
GDISK [disk] [/STATUS] [/RAW|/LBA] [/X] [/Y]
GDISK disk /ACT /P:partn-no [/X] [/Y]
GDISK disk /[-]HIDE /P:partn-no [/X] [/Y]
GDISK disk /MBR [/WIPE] [/X] [/Y]

(C) Copyright Binary Research, 1998. Version 1.0f-BETA.

An additional switch not shown here in the help text is the /VERSION switch which displays the version information for the GDISK executable.

Detailed Instructions

More detailed help may be accessed by qualifying the help request with the switch for one of the modes:

C:\> GDISK /? /CRE
reates fixed disk partitions and logical drives.
GDISK disk /CRE {/PRI|/EXT|/LOG} [/SZ:mbytes] [/FOR [/Q] [/V[:label]]]
      [/-32] [/-CE] [/X] [/Y]
  disk         The physical fixed disk (1-8).
  /CRE         Create a DOS partition or logical DOS drive.
  /PRI         Create a primary DOS partition.
  /EXT         Create an extended DOS partition.
  /LOG         Create a logical DOS drive in the extended DOS
  /SZ:mbytes   Specifies the size of the partition. Default is to
               create a partition of the largest possible size.
  /FOR         Format the new partition once it has been created.
  /Q           Perform a quick format on the new partition.
  /V[:label]   Specifies the volume label. Default is no label.
  /-32         Ignore large-disk support (FAT32). Limits maximum size
               of new primary DOS partitions and logical DOS drives to
               2048 MB.
  /-CE         Ignore any free space in the Customer Engineering (CE)
  /X           Ignore extended disk-access support.
  /Y           Suppress prompting to confirm you wish the action to be
               performed. /SURE has the same meaning.

Reinitializing the Master Boot Record

The /MBR switch may be used to rewrite the boot code in the Master Boot Record. The usual reason for needing to reinitialize the MBR is to eliminate a boot sector virus residing there.

Reinitializing the Master Boot Record does not alter the disk's partition information but can be destructive if other software has replaced the original standard Master Boot Record. This will be the case if a disk extender (such as OnTrack's DiskManager) or operating system loader (such as OS/2's Boot Manager) have been installed.

Warning: Do not use the /MBR switch if a disk extender is installed as it will render the partition data inaccessible until the extender has been reinstalled.

Another situation in which the /MBR switch may be useful relates to a bug in some BIOSes: if a new disk is installed or a different operating system loaded, the next time an IDE auto-detect is performed in the BIOS some devices may fail to be detected. It may be that the new drive itself, the primary drive containing the new operating system, or other IDE devices such as a CD-ROMs are the ones that cannot be detected by the BIOS. Using GDISK /MBR on each of the disk's will often repair this problem.

Assertion Failures

This version of GDISK contains extensive internal self-checks in the form of logical assertions. In the final release of the product these checks will be turned off. In this pre-release version these checks enable us to double-check the internal behavior of the program.

Literally hundreds of these checks are made each time that GDISK is executed. If any of these checks fail, an assertion failure message is displayed that will look similar to the following:

Assertion failed: example_assertion == false, file GDISK.CPP, line 159
Abnormal program termination

If you see an assertion message while running GDISK, please record the information from the message and the details of the operation you were performing and notify us at Binary Research by emailing Your help is appreciated and will assist us in providing software of the highest possible quality.

Terms of Distribution

The ownership and copyright of all materials pertaining to GDISK (The Product) remains with Binary Research Ltd. The distribution of this preview product is not a sale of any rights to The Product. All materials are copyrighted by Binary Research Ltd. All Rights Reserved. They may not be copied, published, re-transmitted, uploaded or summarized without prior, explicit, written permission.

Agreement Period

You are free to make use of The Product for up to 60 days past the date of the preview release (4/23/1998). After that period, the agreement is terminated as described in the Termination clause.

Copying and Distribution

You may not make copies of The Product, other than a backup copy for your own use. You may not distribute The Product in any form, including print, physical media, upload to a bulletin board system, or upload to an Internet or intranet server, without the expressed written consent of Binary Research Ltd.

Rental or Leasing

You may not rent or lease or The Product under any circumstances unless specifically authorized in writing by Binary Research Ltd.

Reservation of Rights

Any and all other rights pertaining to The Product or its use, other than those specifically granted by this Agreement, are hereby reserved by Binary Research Ltd.


Without limitation to other rights that Binary Research Ltd. may have, Binary Research Ltd. reserves the right to immediately terminate this license upon notice, in the event that you fail to comply with its terms. Upon termination, you lose any and all rights granted to you by this Agreement, and you must destroy all copies of The Product in whatever form they may exist.

Notification of Safety Issues

There are certain operations supported by The Product that will result in the deletion of partitions and the data they contain. The user takes all responsibility for any actions that he or she chooses to undertake. Under no circumstances will Binary Research Ltd. be held liable for any loss or damages resulting from the actions of any user of The Product.

No Warranty

Binary Research Ltd. specifically disclaims all warranties with regard to The Product. This preview release is provided "as is", without any warranties of any sort, either expressed or implied. This includes, but is not limited to, implied warranties for The Product’s quality, merchantability, performance, or fitness for a particular purpose. Binary Research Ltd. does not warrant any results that you may obtain from using The Product. All risks arising out of use of the contents of The Product remain solely with the user.

Binary Research Ltd. makes no guarantee of accuracy regarding the material associated with The Product. Binary Research Ltd. incurs no obligation to provide support, maintenance or updates to The Product.

No Liability for Consequential Damages

In no event shall Binary Research Ltd. or its suppliers or agents be held liable for any damages whatsoever arising from the use of The Product, or the inability to use it, even if Binary Research Ltd. has been advised of the possibility of such damages. This disclaimer includes, without limitation, any claims of direct or indirect damages for personal injury, loss of business profits, loss of business information, business interruption, special damages or any other pecuniary loss by yourself or any third party. Because some states do not allow the exclusion or limitation of liability for consequential or incidental damages, the above limitation may not apply to you.

Limitation of Remedies

In any case, the entire liability of Binary Research Ltd. and your exclusive remedy under any provision of this Agreement shall be limited to the actual amount paid for The Product.