WHITE PAPER

TecTips: Hidden (32) Options Guide Previously Undocumented Options of the FDISK Utility Released Under Windows95™ OSR2 or Later Abstract 2 Document Conventions 2 Read This First 3 Best-Case Scenario 3 Windows Startup Disk 3 How to apply these options 3 FDISK(32) Options 4 Informational Options 4 Behavioral Options 5 Functional Options 6

February, 2000

Content ©1999 StorageSoft Corporation, all rights reserved Authored by Doug Hassell, In-house Technical Writer StorageSoft White Paper page 2 FDISK(32) Line Options Abstract Anyone that remembers setting-up Windows 3.x or the first Win95 release surely knows of the text-based utility, fdisk.exe. Some of those may even be aware of the few, documented switches, such as /status, /x or even the commonly referenced /mbr. Even fewer would be aware of the large table of undocumented command-line options - including automated creation, reboot behavior, and other modifiers - which we will divulge in this document. Note that all options given here are not fully tested, nor are they guaranteed to work in all scenarios, all commands referenced apply to the contemporary release of Win95 (OSR2 - version “B” - or later, including Win98 and the up-and-coming Millennium™ edition). For our recommendation on how to use these swtiches, please refer to the “Read This First” section. Document Conventions In this document are certain references that deserve special recognition. This is done through special text- formatting conventions, described here… v Words and phrases of particular importance will stand-out. Each occurrence of this style will generally indicate a critical condition or pitfall that deserves specific attention. v The instructions to follow will include descriptions of DOS commands. Since such commands are very explicit in nature, each will be presented on a separate line in a bold, mono-space style to better communicate the exact characters that need to be typed. Also, when the command should be entered a specific location, the default DOS prompt text will also be shown, but in normal . The following example shows the command that will quickly (erase) a previously-used diskette in the A: drive... :\> format a: /q /u v This document contains references to certain files by name. The names of these files will appear in lowercase and in boldface (e.g., open the readme.txt file for information). will always include the file-extension, however the file-extension is not always visible in environments such as Windows Explorer. Refer to the Windows Topics for information on making file-extensions visible. Disclaimer This document makes references to trademarks owned by third parties. The first occurrence of said trademarks will show the trademark symbol (™) and directly indicate ownership, where all rights are presumed to be reserved. Subsequent occurrences of the same trademarks will presume implicit ownership (no ™ symbol), both to enhance readability and to eliminate elements that might detract from context. Linguistic variants of a trademark will not be indicated in any way, and are presumed to be “common use” terms. The information presented in this document is to be considered the “best advice” our organization has to offer, however there is no warranty - implied or otherwise - that the given information will give predictable results under any conditions. By applying the information presented here, the reader is making an agreement to accept any and all responsibility of actions taken, based upon said information. The reader also agrees to hold StorageSoft Corporation, as well as its agents, representatives, partners and affiliates, harmless in the event that applying said information results in manifest damages of a real or conceptual nature. StorageSoft White Paper page 3 FDISK(32) Command Line Options Read This First As many will already know, FDISK is not a tool to be used lightly. If the intended drive is not already erased, use of FDISK can likely result in complete data-loss. Applying any of the options presented in this document constitutes an understanding of this possibility, as well as acceptance and responsibility on the part of the reader for all resulting consequences. Best-Case Scenario FDISK is not a cutting-edge tool, by any means. It is still the “low level”, basic functionality tool of professionals and amateurs alike, offering a simplified interface for simple partitioning functions. As most are already aware, FDISK will directly modify the system-level data structures on a hard drive, often without regard for existing contents. This also means that FDISK works best when the active system is not dependent upon the hard-drive in any way (i.e., system was not booted from the hard-drive). Windows Startup Disk Since the context of this paper revolves around recent Win95/Win98 versions, a prudent measure before applying any of these commands would be to create a Windows Startup Disk. To make one, simply boot a Win9x machine normally, navigate into | Add/Remove Programs, and select the tab labeled Startup Disk. Click the button that reads Create Disk and provide a regular, 3.5”/1.44MB diskette when prompted. (The Win9x Installation , or at least the Setup Files from the CD, will be necessary). The purpose of the Startup Disk is as a “backup” for the system. While this disk includes the FDISK utility, it should not be modified for use with any of the options described herein. Use this disk only in an emergency, when it is critical to the system in a standardized environment, or when attempting to data. How to apply these options For the options that follow, make a diskette with simply the DOS Mode system files, and the fdisk.exe program. This is done most-easily by using the Windows Format Disk applet (right-click on a Floppy Drive icon - A: or B: - and select Format...), then copying the fdisk.exe program-file (in the \windows\system\command folder, right-click on fdisk.exe and select Send To | [Floppy Drive]). After the diskette is made, the options described herein can be manifested as a batch program; either included in the autoexec.bat file, or as a stand-alone batch script. Use Windows Notepad, or a similar text- editor application, and save the file with the .bat extension (be sure to select File Type of “All Files”). Whichever method is chosen, always boot from diskette when using these FDISK options! StorageSoft White Paper page 4FDISK(32) Command Line Options FDISK(32) Options The options that follow have been sorted into three categories... Informational Such options have no real effects, but rather display important information Behavioral These options only change how FDISK behaves, and do not make any significant changes on their own Functional These options will have real results, the hard-disk system area will be changed With careful planning and execution, this information can help one to become a powerful master of the FDISK tool, and may even make setting-up the hard-drive a quick and efficient task. Informational Options Actually, there is really only one option that qualifies in this category: Display Status /status Displays the partition-table in its current state, and in a practical format. The tabulated headings are as follows... Disk The number representing the order of the installed hard-drive(s). (e.g., the first hard-disk appears as disk 1) Drv This column shows which partitions have been assigned as DOS Logical drives (drive-letters). Any rows that do not show anything under Disk or Drv represent partitions that can not be read by DOS or Windows (only the size is shown). Mbytes The size of the disk/partition in MB. At the bottom of the screen, FDISK also shows the value used for Mbytes (not exactly 1 million). Free If the hard-disk is not fully allocated, the amount of free space (also in Mbytes) is shown here. On a drive that is fully allocated, this column will appear blank. Note that this column does not reflect free space within any of the partitions, only space on the hard-disk that is not allocated. Usage Only applies to rows for the hard-disk(s), not partitions, this value displays the percentage of allocated space over total capacity. On a fully-allocated hard-disk, this value would be 100%.

Use of this option has no effect on the partition table, and can even be safely used within the Windows environment at a DOS prompt. This means that it is not only appropriate in a batch program, but may also be used as the command-line in a Windows Shortcut. StorageSoft White Paper page 5 FDISK(32) Command Line Options Behavioral Options Each of the following four options has a specific purpose, especially when used in combination with the Functional Options in the following section. Careful review of these options is recommended before applying any of the Functional Options. In short, FDISK already uses an automated system when creating new partitions and/or volumes. These options will over-ride such behavior, often in a manner that would reflect the behavior of older (Win95 “original retail”, or MS-DOS) versions. Prompt for FAT16/32 on each partition /FPRMT By default, FDISK prompts for “Large Disk Support” whenever a hard-disk of >512MB is detected. This selection, however, will only enable FDISK to use FAT32 partition-types when the partition-size is also >512MB. Using this option, FDISK will prompt to use FAT16 or FAT32 types for each partition or that is created during that session, regardless of size. Because of the option to over-ride the >512MB convention, use of this option can give unpredictable results. Use with caution. Skip reboot upon /Q When any permanent changes are made in FDISK (interactive mode) it will require that the system reboots upon exit, a necessary action if the changes are to go into effect. FDISK actually enforces this requirement by invoking a fairly-common BIOS instruction under the i386 architecture. Use of this option will prevent FDISK from enforcing this requirement. Since the DOS environment does not “see” the changes made by FDISK until rebooting, use of this option can have unpredictable results until the system is actually restarted, and/or could result in permanent damage to data if another utility is then used immediately after FDISK. Use with caution. Disable LBA Partition Types /X By default, FDISK will use the special “LBA” Partition Types when a partition goes beyond (or includes) the 8.4GB capacity-point on the drive. Using this option will disable these special types, and may also limit the full use of >8.4GB drives. Disable Hard-Disk Integrity Check /ACTOK By default, FDISK will perform a “quick” disk-integrity scan before creating a partition or volume (i.e., quickly checks the first track of each cylinder on the drive; the process generally takes a few seconds to complete). Using this option will cause FDISK to skip this scan, but also invites the possibility of using a hard-disk that contains bad sectors in the “system area” (first track) of a partition. Use with caution. StorageSoft White Paper page 6 FDISK(32) Command Line Options Functional Options The following options will have permanent effects on the hard-disk system area. By applying any of the following options, the reader is taking full responsibility for any and all results. Consider this a final warning. Some of the following options will use a command varaible, which will be represented as either of the following place-holders... Specifies one of the installed hard-disks, starting with hard-disk 1 (e.g., IDE Primary Master) Specifies the size of a new partition, in Mbytes; FDISK will round-up this value when necessary, as well as truncate a larger value when it exceeds the total hard-disk capacity. Overwrite on Hard-Disk 1 /MBR This option, in actuality, does not modify the partition table. Rather, it over-writes the machine-code construct that surrounds the partition table in the hard-disk Boot Sector (cyl 0, side 0, sector 1), also known as the Master Boot Record or MBR. Certain, 3rd-party utilities may make use of a customized MBR, where replacing it with the “FDISK default” could disable certain functions. Use with caution. Overwrite Master Boot Record on secondary Hard-Disk /CMBR Like the /MBR option, this only over-writes the Master Boot Record code on a hard-disk. Where the /MBR option only works on hard-disk 1, this option allows any hard-disk to be specified as the value, . For example, to over-write the MBR on the Primary Slave, substitue with the number 2. Create Primary Boot Partition (PRI DOS type) and set as “Active” /PRI: Creates a Primary Boot partition of the specified size, on the specified hard-disk (both values are required). The resulting partition will be set as the “Active” or bootable partition on the specified hard-disk (irrelevant for secondary hard-disks). Volumes of 512MB or larger will automatically become FAT32. Create Primary Boot Partition as FAT16 only (PRI DOS type) and set “Active” /PRIO: Creates a Primary Boot partition of the specified size and on the specified hard-disk, but only as a FAT16 partition-type. In effect, this option will disable FAT32 functions in the newer FDISK utility when creating the partition. When formatted, the partition will become FAT16. StorageSoft White Paper page 7 FDISK(32) Command Line Options Create Extended Partition /EXT: Creates an Extended Partition of the specified size and on the specified hard-disk. Remember that an Extended Partition itself can not be formatted, but is only a “container” for one-or-more Logical Volumes (see the following, two options). Create Logical Volume (when creating Extended Partition) /EXT: /LOG:/LOG: Creates a Logical Volume of the specified size, however, it must be used when creating the Extended Partition. Volumes of 512MB or larger will automatically become FAT32. See notes for /EXT above. Create Logical Volume as FAT16 only (when creating Extended Partition) /EXT: /LOGO: Creates a Logical Volume of the specified size, forcing the FAT16 volume-type, however it must be used when creating the Extended Partition. See notes for /EXT above.