      DFSee version 6.14 28-09-2004  (c) 1994-2004: Jan van Wijk
 =========================[ www.dfsee.com ]==========================

_______________________________________________________________________________

C O N T E N T S:
_______________________________________________________________________________

  Command reference = overview of FDISK specific commands
  Detailed description = description of every command


  Note: All generic commands can be found in DFSCMDS.TXT, for example:

        ALLOC,  CHECK,  CLONE,  RESIZE,  RECOVER,  SAVETO,  SCAN,  WIPE

_______________________________________________________________________________

C O M M A N D   R E F E R E N C E:
_______________________________________________________________________________

FDISK specific commands

Active filesystem : FDISK / IBM-BMGR,  specific commands are:

 BMP       [disk  | -d:disknr  ] = Show BMGR primary-names sector for a disk
 CLEANUP   [disk               ] = Cleanup partition-chain, fix minor errors
 CR        [parameters][options] = Create a new partition, use 'CR' for usage
 DELETE    [pid] [disk]          = Delete one or more partitions
 DFSIBMGR   disk [imagefilename] = Create new BootManager image for 'create'
 DISK      [disk]           [-r] = Select disk, show MBR; <Enter> = next EBR
 FAT2OS     pid [disk [boot-OS]] = Set FAT-BR bootcode to OS2|NT|IBMdos|MSdos
 FIXCHS     disk                 = Fix CHS values to match LBA/current geometry
 FIXEXT    [disk   [to  [from]]] = Fix ext-partition types to standard value
 LVM       [pid | *]   [options] = Update name, letter and BM-menu for partition
 LVMSHOW   [pid | *]             = Show related LVM-info for 1 or all partitions
 NEWMBR    [disk | *]   [-clean] = Refresh MBR bootcode, [-clean] = delete all
 NTSIGN    [disk    [signature]] = Set NT-signature in MBR, HEX signature value
 PCLEAR     disk [P][Lvm[S]][Br] = Clear info in P-tables, LVM and/or Boot-rec
 PLIST      p|f|e|m|b|w|l [d[r]] = List: part|free|ebr|mbr|boot|walk|lvm [opt]
 PRESTORE   disk Fname   [types] = Write info from file into P-tables and LVM
 PSAVE      disk Fname [comment] = Save Partition-table and LVM info in file
 SETACCESS  pid [hide|vis|multi] = Make partition 'pid' accessible or hidden
 SETBOOT    opt[:opt-parameters] = BootManager setup and reboot => 'setboot ?'
 SETLET     pid  letter | - [ns] = Set driveletter for DFSee; [ns] = no sync (NT)
 SETNAME    pid        [BM-name] = Set or reset (non-LVM) BMGR name for partition
 SETTYPE    pid  disk new  [old] = Change partition-type from old to new value
 STARTABLE  pid  [multi | clear] = Make partition 'pid' startable (bootable)
 TYPE        [type | first last] = Show system-type description (for 00..ff)
 VCU        disk  | * |  -d[:nr] = Clear existing LVM-info, create new defaults
 VIRTUAL  $ | Fname | size [H S] = Virtual disk from CURRENT, Fname or size/geo
 VREMOVE                   [ * ] = Remove last one made, or all virtual disks
 VSTATUS                         = Show R/W and usage status of virtual disks
 W2KBM     [disk               ] = Make IBM's BootManager Windows-2000-Proof
 WALK [disk]                [-r] = Select disk, show the MBR, walk EBR chain


 For an up-to-date list of commands, use the '?' command

 FDISK specific sector types (see ??? command)

  'A' = MAC DDM, drive description      'a' = MAC DPM, partition map, Apple
  'l' = LVM disk and volume info        's' = LVM signature sector
  'd' = LVM DriveLink sector            'D' = LVM DriveLink table
  'f' = LVM BadBlockRelocation sector   'F' = LVM BadBlockRelocation table
  'p' = VRAID phys device               'v' = VRAID devicetype1
  'V' = VRAID devicetype2               'X' = Unidentified data

_______________________________________________________________________________

D E T A I L E D   D E S C R I P T I O N:
_______________________________________________________________________________

 BMP       [disk  | -d:disknr  ] = Show BMGR primary-names sector for a disk

 Purpose:       Show the IBM BootManager sector that has BM-names for primaries

 Parameters:    disk     optional   Disk number with BMGR to show names for

 Options:       -d[:disknr]         Disk number with BMGR to show names for

 Output:        Hexdump display of first part of that sector (if present)

 Remarks:       This sector is an array of 4 lines for each physical disk,
                one for each possible primary partition.
                Each line has an active flag-byte, head+sector/cylinder,another
                flag which is set when on the BM-menu, and the name string

                When using an LVM-enabled BootManager, the startable
                primaries are represented here with a "--> LVM" string
_______________________________________________________________________________

 CLEANUP    [disk]               = Cleanup partition-chain, fix minor errors

 Purpose:       Clean up minor inconsistencies in partition-chain, like removal
                of 'empty' extended partitions and recalculation of the total
                size of the extended-container.

 Parameters:    disk    optional   Disk to operate on, default is all disks

 Options:       -c:[0|1|2] : CHS style: 1=PQmagic, 2=MS, default 0=IBM/DFSee

 Output:        Progress information and confirmation messages

 Remarks:       Inconsistencies can be caused by several operations, using
                DFSee, other FDISK versions, tools like Linux GRUB or
                Partition Magic. Resizing and deleting with PQMagic can
                cause 'empty' extended containers.
_______________________________________________________________________________

 CR        [parameters][options] = Create a new partition, use 'CR' for usage

 You can use positional-parameters and/or position-independent options.
 For a detailed description of all the positional-parameters and the
 position-independent options see further below, short description:

          parameters   : pri|log  [type  [size  [loc  [pos  [BM-name]]]]]

         -p or -l      : Create a Primary or Logical partition. (mandatory)
         -t:numeric  ¿ : System Type, numeric, default DECIMAL  (mandatory)
         -t:'symbol' Ù : System Type, as a symbolic-name        (mandatory)
         -s:size       : Size, will be rounded UP to next cylinder boundary
         -d:disk-nr  ¿ : Location, use first fitting area on specified Disk
         -f:id       Ù : Location, as Freespace id (1st column from 'part')
         -a:abs-pos  ¿ : Absolute position from start of disk  (mcs-number)
         -r:rel-pos  ³ : Relative pos from start of freespace  (mcs-number)
         -e:end-pos  ³ : Relative pos from end   of freespace  (mcs-number)
         -i:i13-pos  ³ : Relative pos before the Int-13 limit  (mcs-number)
         -x:e13-pos  Ù : Relative pos after the Int-13 limit   (mcs-number)
         -b:BM-name    : Partition name for (IBM, non-LVM) BootManager menu
         -o            : Open the new partition after creation
         -C            : Clear bootsector with 0xF6 pattern (FDISK behaviour)
         -F            : Set bootable status-flag in partition-table (active)
         -I[:image]    : Imagefile to be written to new partition
         -L            : Automatic 'lvm -V' on new partition
         -L:'lvm opts' : Automatic 'lvm' using specified options
         -A:pid|letter : Create AS partition; using same type and size
         -c:[0|1|2]    : CHS dummy style: 1=PQmagic, 2=MS, default 0=IBM/DFSee


       The mcs-number format is [0x]nnnn[,g|m|k|c|t|s] a HEX or decimal value,
       in GiB, MiB, KIb, Cylinders, Tracks or Sectors. Default is decimal MiB.


       You can mix the old and new style syntax, as long as the 'old' type
       parameters are in the required fixed position as specified above
       and the 'pri|log' and 'type' are specified somehow.

       Examples: cr log hpfs 200  3  *  OS2MAINT
                 cr log hpfs 200  -d:3  -b:OS2MAINT
                 cr log hpfs -s:200  -d:3  -b:OS2MAINT
                 cr log -t:hpfs -s:200  -d:3  -b:OS2MAINT
                 cr -log  -t:hpfs  -s:200  -d:3  -b:OS2MAINT
                 cr -d:3 -b:OS2MAINT -t:hpfs -s:200 -logical
                 cr -disk:3 -bm:OS2MAINT -type:hpfs  -size:200  -logical

                 These are all variations of the same CReate command ...


 Purpose:       Create one new partition in an area that is now freespace

 Parameters     pri|log mandatory  Primary/Logical identifier;
 (old style)
                                   log  | l   Logical partition

                                   pri  | p   Primary partition


                type    mandatory  System-type for new partition;

                                   hex        Hexadecimal value 0..ff

                                   symbolic   A name from the predefined
                                              set of partition-types.
                                              (see SETTYPE for a list)


                size    optional   Desired size for the partition;

                                   *          Use maximum size for the
                                              selected freespace-area

                          number[[,d|x]m|c|s] Specific value, decimal or hex.
                                              Megabytes, Cylinders or Sectors.
                                              Default: decimal Megabytes


                loc     optional   Location to place new partition;

                                   *          Use first 'matching' area

                                   @fsp-id    Specific freespace area

                                   disk       Use first matching area on
                                              the specified disk


                pos     optional   Position in loc-area;

                                   *          Default position (at start)

               [+|-|@|{|}]number[[,d|x]m|c|s] Specific value, decimal or hex.
                                              Megabytes, Cylinders or Sectors.
                                              Default: decimal Megabytes
                                              Prefix modifiers are:
                                   +          Relative to start of area
                                   -          Relative to end of area
                                   @          Absolute from start of disk
                                   {          Relative, before 1024-cyl limit
                                   }          Relative, after  1024-cyl limit

                                              Note: The corresponding value
                                                    with the prefix can be 0
                                                    or empty

                BM-name optional   Add to the BootManager-menu using this name


 Options:       -p         : Create a Primary partition
 (new style)    -l         : Create a Logical partition

                -t:type    : System Type, numeric or symbolic-name  (mandatory)
                             When numeric, the value is DECIMAL by default,
                             Hexadecimal can be specified using the '0x' prefix

                             Some symbolic names + HEX value and description:

                             FAT   = 01/04/06/0b/0c    Automatic FAT type
                             BMGR  = 0a                OS/2 BootManager
                             FAT32 = 0b/0c             Automatic 32-bit FAT
                             JFS   = 35                Journalled FS (LVM)
                             HPFS  = 07                OS/2 native filesystem
                             NTFS  = 07                Windows-NT>XP filesystem
                             SWAP  = 82                Linux SWAP partition
                             EXT2  = 83                Linux EXT2 filesystem

                             Note: The automatic FAT types will use the required
                                   value based on partition size and position.

                             Example formats, all of the following are equal:

                             -t:ext2          symbolic name (case insensitive)
                             -t:'83'          hex value, as a string
                             -t:83h           hex value, with the 'h' postfix
                             -t:0x83          hex value, with the '0x' prefix
                             -t:131           decimal value, numeric format

                             Note:

                             -t:83            is decimal 83 ==> type 0x53 !!!

                -s:size    : Size, will be rounded UP to next cylinder boundary
                                   except when specified in sectors

                             Examples:

                             -s:800           size of 800 MiB, rounded UP
                             -s:30,c          size of 30 cylinders, rounded UP
                             -s:0x3fc0,s      size of exactly 0x3fc0 sectors

                -f:id      : Location, as Freespace id (1st column from 'part')
                -d:disk-nr : Location, use first fitting area on specified Disk
                -d or -d:0 : Location, currently open disk.   (this is default)
                -d-        : Use first fitting area on ANY disk.

                -a:abs-pos : Absolute position from start of disk  (mcs-number)
                -r:rel-pos : Relative position from start of area  (mcs-number)
                -e:end-pos : Relative pos from end of the disk     (mcs-number)
                -i:i13-pos : Relative pos before the Int-13 limit  (mcs-number)
                -x:e13-pos : Relative pos after the Int-13 limit   (mcs-number)

                -b:BM-name : Partition name for (IBM, non-LVM) BootManager menu

                -o         : Open the new partition after creation

                -I-        : Do NOT install any image (like DFSIBMGR.IMG) here.
                -I[:image] : Imagefile to be written to new partition, this can
                             be a RAW (.IMG) or compressed (.IMZ) image as used
                             with the SIM and WRIM commands. It is intended to
                             initialize the new partition with existing data.
                             When no name is specified, you will be prompted.

                -L           Automatic 'lvm -V' on new partition
                -L:'lvmopts' Automatic 'lvm' using specified options
                             In both cases LVM-information will be added
                             for the new partition, either interactively or
                             with defaults, or with the specified values.
                             The 'lvmopts' are simply options that are valid
                             for the LVM command, but combined in one string
                             with either double or single quotes.


                -A:pid|let   Create AS partition; using same type and size.
                             This "CREATE AS" will use the specified partition
                             primary/logical, type and size as a default.
                             Other options can be added, and overrule any
                             value set by the -A option.

                    Example: "CR -As:2 -t:fat32" will create a partition just
                             like the current 02 but with type FAT32.


 Output:        Progress information and confirmation messages

 Remarks:       When creating a type 0x0a = IBM BootManager partition, and
                an imagefile 'DFSIBMGR.IMG' exists in the current directory,
                DFSee will prompt you to write this image to the new partition.
                In batch-mode you can PREVENT an existing 'DFSIBMGR.ING' image
                to be installed by using the '-I-' option.
                A 'DFSIBMGR.ING' image can be created from an existing
                installation using the DFSIBMGR command.
_______________________________________________________________________________

 DELETE    [pid] [disk]          = Delete one or more partitions

 Purpose:       Delete one or more partitions.

 Parameters     pid   : Partition-id for 1 partition or '*' for all partitions
                pid,r : Relative partition ID on specified or current disk
                disk  : Physical disk number for 1 disk or '*' for all disks
                        Used for extra verification only

 Options:       -c      Clean partition-table entry to all zeroes
                -d      Partition to delete must be on current disk
                -d:[nr] Partition to delete must be on specified disk
                -p:x    Partition ID (PID) to delete (same as 'pid' parameter)
                -p:x,r  Relative partition ID on specified or current disk
                -L-     Do NOT delete related DLAT LVM info for a primary, as
                        this allows re-creation in same place (resizing).

 Output:        Progress information and confirmation messages

 Remarks:       The partition will by default be deleted by changing the
                system-type to hex '00'. This is the minimum required change.
                This allows for relatively easy recovery or rollback.
                The '-c' option forces the complete table-entry, 16-bytes
                to be set to all zeroes.

                Related IBM-BootManager (pre-LVM) and DLAT LVM information
                is automatically removed to avoid inconsistencies.
_______________________________________________________________________________

 DFSIBMGR   disk          [name] = Create new BootManager image for 'create'

 Purpose:       Create a DFSIBMGR.IMG image-file from the BootManager installed
                on the specified disk, to be used later on 'create' commands
                when creating new BootManager partitions.

 Parameters:    disk    mandatory  Disk to get the BootManager image from
                name    optional   Name for the image (default DFSIBMGR.IMG)

 Output:        Progress information

 Remarks:       The 'create' command will automatically search for an image
                with this name when a type 0x0a = BMGR partition is created.
_______________________________________________________________________________

 FAT2OS     pid [disk [boot-OS]] = Set FAT-BR bootcode to OS2|NT|IBMdos|MSdos

 Purpose:       Replace bootcode by OS/2, NT, IBMdos or MSdos bootcode for FAT

 Parameters     pid     : Partition-id for 1 partition or '*' for all
                pid,r     Relative PID, on current or specified disk
                disk    : Physical disk number for 1 disk or '*' for all
                boot-OS : Specifier for bootcode, taken from operating system:

                          OS2    - OS/2   version 4 (Warp, Merlin)
                          NT     - Win-NT version 4
                          IBMdos - IBM DOS 7.0
                          PCdos  - IBM DOS 7.0
                          MSdos  - MS  DOS 6.22

 Options:       -d[:nr]      : Use current or [specified] disk for relative PID

 Output:        Progress information and confirmation messages

 Remarks:    a: The command only replaces the BOOT-CODE part of the FAT
                bootsector. Other stuff, like the boot-parameter-block (BPB)
                is kept intact to preserve geometry and format information

             b: This command is intended to prepare a partition for booting
                the specified OS (FAT only), from a pure DOS environment.

                Step 1) Partition using DFSee FDISK (make at least 1 FAT)
                Step 2) Reboot, to make DOS assign a drive-letter
                Step 3) Format the FAT partition using standard DOS FORMAT
                Step 4) Use DFSEE FAT2OS command to make it correctly bootable
                Step 5) Xcopy a saved set of specific Operating-System files
                        to the partition, including the system-files like
                        OS2BOOT, OS2LDR, NTLDR, IBMBIO/IBMDOS, IO.SYS/MSDOS.SYS
                        etc., depending upon the Operating System.
                Step 6) Boot that partition (directly or through a BMGR)
_______________________________________________________________________________

 FIXCHS     disk                 = Fix CHS values to match LBA/current geometry

 Purpose:       Change all non-standard values for the CHS fields in partition
                tables to valid ones to avoid warnings or failures working
                with other disktools (FDISK, LVM, Partition-Magic etc)

 Parameters:    disk    mandatory  Disknr or '.' for current, '*' for all disks

 Options:       -c:[0|1|2] : CHS style: 1=PQmagic, 2=MS, default 0=IBM/DFSee
             or -c:IBM       To override the global style being used, and
             or -c:PQ        force ALL CHS value to use this specific style.
             or -c:MS        useful to avoid "corruption" messages/errors
                             by tools like PartitionMagic or LVM ...

 Output:        Progress information and confirmation messages

 Remarks:       Non-standard values for the CHS fields sometimes cause
                problems in tools like LVM, it refuses to update anything
                because the "partition table might be corrupt" ...

                There are two cases: for cylinders below 1024 the CHS values
                must match the calculated linear values (LBA) exactly, and
                above cylinder 1024 they should be acceptable 'dummy' values.
                For the dummy values, a few styles are supported, the default
                is the one normally created by DFSee and by OS/2 FDISK or LVM
                but you can also select the PowerQuest style to make sure
                Partition-Magic or Drive-Image are satisfied.

                Note that the calculated LBA values depend on the logical
                geometry being used, so check if that geometry is the one
                you want (or need) to use.

                Fixing this will get rid of all the DFSee warnings related
                to CHS problems (as displayed with 'part -w:chs')
                However, cylinder alignment warnings will stay because the
                partitions are not moved or resized. This is often less of
                a problem than CHS mismatches.
_______________________________________________________________________________

 FIXEXT  [disk | * [to  [from]]] = Fix ext-partition types to standard value

 Purpose:       Change non-standard values (0x0f) back to the standard 0x05
                value so operating systems like DOS and OS/2 can access the
                logical volumes inside this extended-partition container.

 Parameters:    disk    optional   Disk number or '*', default all disks = '*'

                to      optional   New system-type for EBR, default is 0x05

                from    optional   Existing system-type, default is 0x0f

                Options:     -e    Force setting type other than 0x05 or 0x0f

 Output:        Progress information and confirmation messages

 Remarks:       The non-standard type 0x0f was introduced by Win9x combined
                with the FAT32 filesystem. These allow partitions larger
                then 2GiB and spanning the 8GiB BIOS limit (1024 cylinders).
                Using the 0x0f type prevents older operating systems from
                accessing, and possibly damaging, the new partitions.

                When all FAT16 partition are below cylinder 1024, there
                seems to be NO VALID REASON to use this type, and it can
                be safely changed back to 0x05 to allow access by DOS,
                OS/2 and others.

                I can NOT GUARANTEE full co-operation with multiple
                operating systems, but my experiences are positive.
_______________________________________________________________________________

 LVM       [pid | *]   [options] = Update name, letter and BM-menu for partition

 Purpose:       Set/show LVM related values for a partition (update or display)

 Parameters     pid     optional   Partition id for partition to update or '*'
                pid,r              Relative PID, on current or specified disk

 Options:       -v:volume    : Set volumename (= BootManager name if on menu)
                -v:"" or -v- : Remove volumename. This deletes the volume for LVM
                -p:part      : Set partition name for this partition
                -p:"" or -p- : Remove partitionname. LVM will use a default.
                -l:letter    : Set preferred driveletter for the volume
                -l:"" or -l- : Remove driveletter for the volume (hide)
                -m    or -m- : Set volume on the BootManager menu, or remove it
                -i    or -i- : Set installable status for volume,  or remove it
                -s           : Force synchronization of start/size with p-tables
                -lvmpid:pid  : Force specific LVM partition ID to be set
                -lvmvid:vid  : Force specific LVM volume ID to be set
                -lvmdid:did  : Force specific LVM 'this disk' ID to be set
                -lvmbid:bid  : Force specific LVM 'boot disk' ID to be set

                -P-          : Do not prompt for values with a dialog-window

                -D           : Force default values to be used, by deleting
                               existing values before assigning new ones.
                -J           : Allow JFS volume creation (recovery, not new ones!)
                -r-          : Do NOT use existing LVM-signature data in recovery
                -V           : Automatically assign a volume-name when new LVM
                               info is created. This will make the partition a
                               volume too, but without a drive-letter.
                -R           : Read-only, just show values (as used from LVMSHOW)

                -c           : Update CRCs for LVM sectors on selected disk(s)
                -n[:name]    : set disk name for selected disk(s), optional prompt
                               When changing the name, the internal LVM DiskID
                               will be synchronized for all partitions too.

                -d:nr        : disk number, restrict updates to specified disk
                -d           : restrict updates to the current disk only

 Output:        Confirmation and progress information, and when no -P- option
                is used, an LVM-update dialog window allowing change of most
                LVM values using entry-fields and check-boxes.

 Remarks:       When the -P- option is specified, the fields will be displayed
                only, from this display, the 'd' or <Enter> key will display
                the full LVM-information structure, and the 'x' key the related
                partition-table. LVMSHOW will use this to diplay that sector.

                When no LVM-info exists for the partition, it will be created
                automatically with a default value for the partition-name.
                With the -V option, a volume-name will be assigned as well.

                The -d option will update the CRC values, useful after manual
                editing of the LVM-info sectors, and in combination with the
                -n options it will update the descriptive LVM diskname.
                No other options can be used with -d or -c

                The -c option alone will also check for obsolete DLAT entries,
                and can remove these to avoid the error messages from LVM that
                say: 'The partition table on this disk may be corrupt'.

                Be careful when updating a multi-partition volume (like JFS)
                the volumename and driveletter must be the same on all!

                The command can be called directly from the Operating System
                commandline, as in:

                        DFSOS2.EXE  -b  lvm  2  -v:System  -menu

                This will place the 2nd partition on the BMGR menu as "System"

                Unlike the "delete volume" operation in LVM itself, the "-v-"
                option in DFSee does NOT delete the partition as well. All the
                other LVM-info will remain intact, including the driveletter.
                A subsequent "-v:newname" will recreate the volume with a new
                name and use the same ("existing") partition and driveletter.

                Note that YOU are responsible for keeping the driveletters
                unique for the whole system.

                Using the "-p-" option deletes the explicit partition name,
                LVM will use a default name like "[ A3 ]" in this case.

                While the dialog is up, commands that are started using a
                function key can still be executed. (F4 .. F9 are useful)
                The output in the "text output window" can still be scrolled
                using <Ctrl> + arrow keys or <Ctrl> + PgDn/PgUp.

                As another example, remove all RELEVANT info from the LVM info
                for a partition. This will delete everything that is normally
                used or displayed for an LVM volume. Example, for partition 06:

                     lvm 06  -D  -v-  -p-  -l-  -m-  -i-

                After applying it will NOT be considered a volume anymore.
                However, the LVM sector for the partition will still contain
                the disk-name, the partition-size, and LVM signature and a CRC.
                Using this partition with DFSee, LVM.EXE or LVMGUI would look
                the same as using a freshly created partition without any LVM info.
_______________________________________________________________________________

 LVMCRC     [disk]               = OBSOLETE! Use "LVM -c" or "LVM -d"
_______________________________________________________________________________

 LVMSHOW   [pid | *]             = Show related LVM-info for 1 or all partitions

 Purpose:       Perform a simple display of the LVM-info sector for the current
                or specified partition. (DLAT = Drive Letter Assignment Table)

 Parameters:    pid     optional   Partition id for partition to be listed,
                                   or '*' to list for all partitions.
                                   List CURRENT partition if not specified.

 Output:        Contents of the LVM-info sector(s) with names and driveletter(s)

 Remarks:       Uses a hidden 'lvm' cmd to find the info, and a display of
                the then default sector to display it. It will fail when the
                partition has no LVM-info, and might display the wrong sector.
                To list for ALL partitions, a 'pl l' command will be executed.
_______________________________________________________________________________

 NEWMBR    [disk | *]   [-clean] = Refresh MBR bootcode, [-clean] = delete all

 Purpose:       Create or refresh the boot-code in the master boot record (0)

 Parameters:    disk    optional   Disk to operate on, default is all disks
                                   You can specify either this or use the
                                   -d option for a specific disk, otherwise
                                   the command will be applied to ALL disks

 Options:       -d:disk   = Apply to specified disk or current disk
                -c[lean]  = Clear the partition tables too, resulting
                            in an empty disk, with valid MBR code
                -I[:img]  = Use specified or default (newmbr.img) imagefile
                            for the bootcode instead of the built-in code

 Output:        Progress information and confirmation messages

 Remarks:       Without the -clean option, this command will ONLY replace
                the bootcode part of the MBR, the partition-tables and hence
                all the currently defined partitions will stay intact!
_______________________________________________________________________________

 NTCDR      CD-nr     letter | - = Set driveletter for CDrom (NT version only)

 Purpose:       Set or clear the driveletter for specified CDrom device

 Parameters:    CD-nr   mandatory  Sequence number for CDrom, first is 1

                letter  mandatory  Driveletter to be used for the CDrom device
                                   as displayed in the DFSee "NTMAP" command
                                   Specify '-' to clear the driveletter

 Output:        Progress information and confirmation messages

 Remarks:       Only available in the Windows version of DFSee (DFSWIN.EXE)
                For use on Windows NT-4 only, not recommended on 2000 or XP.
_______________________________________________________________________________

 NTDDD action WIN32dev [NT-device] = Direct manipulation of DosDevice mapping

 Purpose:       Low level corrections, test and debugging of DosDevice mapping
                (NOT intended for normal use)

 Parameters:    action   mandatory Flag value to be passed to DefineDosDevice
                                   The default is 1  (RAW)

                                   Values:      DDD_RAW_TARGET_PATH         1
                                                DDD_REMOVE_DEFINITION       2
                                                DDD_EXACT_MATCH_ON_REMOVE   4
                                                DDD_NO_BROADCAST_SYSTEM     8

                WIN32dev mandatory Specification for the WIN32 device, usually
                                   this will be a driveletter (check NTDEV)

                NT-dev   optional  Native NT device name (path) to define
                                   for the specified WIN32 devicename.
                                   When not specified, the mapping is deleted

 Output:        Success or failure status for the DefineDosDevice API call

 Examples:      DDD 1 R:                                ;Unassign R: mapping
                DDD 1 Q: \Device\Cdrom0                 ;Assign Q: to CDROM 1
                DDD 1 F: \Device\HardDisk0\Partition3   ;Assign F: to 3rd part
                                                        ;on the first harddisk

 Remarks:       Only the (dynamic) mapping used by NT is updated, the registry
                key for driveletter mapping is not modified.

                Only available in the Windows version of DFSee (DFSWIN.EXE)
                For use on Windows NT-4 only, not recommended on 2000 or XP.
_______________________________________________________________________________

 NTDEV      [ device ] [mapping] = Show DosDevice mapping, wildcards limit output

 Purpose:       Show the mapping between WIN32 devices, including driveletters,
                and the underlying systemwide NT device-names

 Parameters:    device   optional  Wildcard specification for the WIN32 name
                                   The default is "?:" resolving driveletters

                mapping  optional  Wildcard specification for native NT name
                                   The default is "*" for all devices
                                   useful are: "*partition*"  for partitions
                                               "*lanmanager*" for NET USE...

 Output:        A two column table with WIN32 versus NT native device names

 Remarks:       useful to check the assignment of driveletters to partitions
                on a disk, but also for network drives (aka NET USE ...)

                Only available in the Windows version of DFSee (DFSWIN.EXE)
                For use on Windows NT-4 only, not recommended on 2000 or XP.
_______________________________________________________________________________

 NTMAP      [ verbose |  sync  ] = Show reg-diskkey, update & sync with DosDevice

 Purpose:       Show a table with disk-number, relative (registry) partition-nr,
                the driveletter assigned, the size in Megabytes and the native
                NT device name related to the driveletter.

 Parameters:    verbose  optional  Expand table to multiple, detailed lines
                                   for each listed driveletter

                sync     optional  Synchronization request of the DFSee info
                                   with NT registry, MBR signatures and the
                                   dynamic driveletter assignments

                                   Note: automatically executed for "SETLET"
                                         commands without a "ns" parameter

 Output:        Progress information

 Remarks:       The driveletters as shown by the DFSee "Part" table will be
                leading, and replace any existing values. Actions performed:

                - When needed: NT signature in the MBR will be written
                - NT registry "disk" key will be (re)created
                - dynamic DosDevice mapping between WIN32 and native NT
                  devicenames is updated when needed

                Only available in the Windows version of DFSee (DFSWIN.EXE)
                For use on Windows NT-4 only, not recommended on 2000 or XP.
_______________________________________________________________________________

 NTSIGN    [disk    [signature]] = Set NT-signature in MBR, HEX signature value

 Purpose:       Set a well-known value as NT disk-administrator signature

 Parameters:    disk    optional   Disk to operate on, default is all disks

                sign    optional   The signature value, in hexadecimal format
                                   Default value is hex DF5EE402

 Output:        Progress information and confirmation messages

 Remarks:       Setting a fixed value for the NT signature value in the MBR
                can avoid unwanted re-assigning of drive-letters when using
                Windows NT. It uses this value to correlate the drive-letter
                mapping kept in the registry. When cloning an NT image to a
                new disk, set the signature to the same (known) value.
_______________________________________________________________________________

 PCLEAR     disk [P][Lvm[S]][Br] = Clear info in P-tables, LVM and/or Boot-rec

 Purpose:       Clear contents of partition-table, LVM or bootrecord sectors.
                The sectors will be completely filled with zero-bytes (0x00)

 Parameters:    disk    mandatory  Physical disknumber, or * for all disks

                type       Ptable  Partition-table sectors (MBR and EBRs)
                           Lvm     LVM disk/volume information sectors
                           S       LVM signature sectors (only valid with'L')
                           Bootrec Boot-records for each partition

                                   Only the first letter is required and
                                   multiple types can be specified.

 Output:        Confirmation messages (interactive mode only)

 Remarks:       Confirmations (yes/no) will be issued for each physical disk
                when clearing partition-table and LVM-info sectors, and for
                each individual partition when clearing the boot-record.
_______________________________________________________________________________

 PLIST     p|f|e|m|b|w|l [opts] = list: part|free|ebr|mbr|boot|walk|lvm

 Purpose:       Show one of several lists of partition related information

 Parameters:    type    optional   type of list wanted: p|f|e|m|b|w|l

                            part   normal partitions
                            free   freespace areas
                            ebr    EBR-chain
                            mbr    MBR partition-table entries
                            boot   Bootsectors for all partitions
                            walk   MBRs and all EBRs (as WALK cmd)
                            lvm    LVM volume information sectors and
                                   the LVM signature sectors

 Options:       -d[:nr]     Disk to operate on, default is all disks when
                            not specified and current disk for '-d'

                -r          Related, include extra-info on related sectors
                            (MBR/EBR versus LVM-info)

 Output:        The list of the requested type with info on start-sector
                and end-sector numbers, sizes and more.

 Remarks:       All sector-numbers are also stored in the DFS sector list,
                for use with the LIST and EXPORT commands.
_______________________________________________________________________________

 PRESTORE *|disk Fname [types] = Write info from file into P-tables and LVM

 Purpose:       Restore (selected) partition-table, LVM and boot-record
                sectors from a binary file created with the PSAVE command.

 Parameters:    disk    mandatory  Physical disknumber, or * for all disks

                Fname   mandatory  Filename for file(s) to restore, when no
                                   extension is specified, the 'disk' parameter
                                   will be used to select the right .PDn file.
                                   An explicit extension can be used to restore
                                   from a different file (other disk number).

                types   optional   Only restore sectors of specified type(s)

                                  r  = Master boot record
                                  e  = Extended boot records
                                  b  = Filesystem boot records
                                  l  = LVM information sectors
                                  s  = LVM signature sectors

                options:         -v  = verbose display and prompting
                                 -l  = list sectors only (no write back)
                                 -c- = no confirmation for each sector,
                                       only for the complete .PDx file


 Output:        Confirmation messages, depending on the specified options

 Remarks:       Sectors are not restored when the '-l' option is specified.

                Quick restore with a single confirmation prompt for the
                whole file can be forced using the "-c-" option.
_______________________________________________________________________________

 PSAVE    *|disk Fname [comment] = Save Partition-table and LVM info in file

 Purpose:       Save contents of all partition-table, LVM and boot-record
                sectors in one binary file per physical disk, selectively
                restorable with the associated PRESTORE command.

 Parameters:    disk    mandatory  Physical disknumber, or * for all disks

                Fname   mandatory  Base filename for saved file(s), the
                                   extension will be '.PDn' (n = disk nr)

                comment optional   A text string that will be included in the
                                   saved file(s) for easy identification.

 Output:        Progress info, one letter r, e, l or b for each saved sector

 Remarks:       Each resulting file will start with an ASCII header that
                contains info on the DFSee version used, date and time and
                some info on the disk and partitions. It also includes the
                comment specified with the PSAVE command.
                This info can be easily referenced by a simple TYPE of the
                file, the ASCII part ends in an EOF character (ctrl-Z) so
                the rest of the binary info does not mess up the display.
_______________________________________________________________________________

 SETACCESS  pid [hide|vis|multi] = Make partition 'pid' accessible or hidden

 Purpose:       Set visibility for the specified partition.

 Parameters:    pid     mandatory  Partition id, see PART and MAP display
                pid,r              Relative PID, on current or specified disk

                hide    optional   Make this partition hidden (invisible)
                vis     optional   Make this partition visible, hide others
                multi   optional   Make this partition visible, but do allow
                                   multiple visible primary partitions per disk

 Options:       -d[:nr]      : Use current or [specified] disk for relative PID
                               PID MUST be specified as relative 'pid,r' in this
                               case, example, set 2nd part on 2nd disk hidden:

                                     SETACCESS  2,r  -d:2  hide


 Output:        Progress information and confirmation messages

 Remarks:       The partition will be made visible (types 01 .. 0f).
                All other primaries on the same disk will be made hidden,
                except when the 'multi' parameter was given.
_______________________________________________________________________________

 SETBOOT    [-]opt[:params]      = BootManager setup and reboot options

 Purpose:       Configure BMGR; Set partition to boot, and (optionally) boot

 Parameters:    opt     mandatory  Option letter/word for the setboot action

                params  optional   Depending on the selected option:

                      q:disk       (query BM settings on 'disk')
                      t:timeout    (seconds or NO)
                      m:mode       (normal or advanced)
                      x:num        (set system-index to 'num')
                 [0..5]:name       (set system 0..5 to 'name')
                    ibd:d          (reboot from drive d)
                    iba:BM-name    (reboot from BM-name)
                      n:d          (set next-boot to drive d)
                      a:BM-name    (set next-boot to BM-name)
                      b            ([shutdown] and reboot now)

      System-indexes 0..5 have the following meaning:

      0  default system   Booted when no other selection is made from the
                          menu, or when the timeout is set to NO.

   1..3  fallback range   On a failing boot on one of these systems, the
                          next boot will be of the next lower-number
                          system (fallback scenario)

      4  force-reboot     Indicates the system-name to boot next time,
                          without display of the menu (forced).
                          This is used by the /iba:name option.
                          The name is automatically cleared on the next boot.

      5  last-booted      The system-name last booted using BootManager.
                          This will also be the default when the default
                          system itself (0) is not set.

 Output:        Progress information and confirmation messages

 Remarks:       Both the 'classic' version of IBM BootManager (2.1 up to Warp4)
                and the "Warp Server for e-Business" or "eComStation" version
                working together with LVM are supported. The latter uses
                longer names for the partitions that are bootable.

                - The reboot from DFSOS2.EXE requires DOS.SYS to be loaded!
                - The reboot from DFSDOS.EXE will only work on Win9x when the
                  external reboot program 'dfsdosx.exe' is present.
                  This executable is delivered in the package as dfsboot9.exe
                  and needs to be renamed before it will work on Windows-9x.
_______________________________________________________________________________

 SETLET     pid  letter | - [ns] = Set driveletter for DFSee; [ns] = no sync

 Purpose:       Set or clear the driveletter for a partition

 Parameters:    pid     mandatory  Partition id, see PART and MAP display
                pid,r              Relative PID, on current or specified disk

                letter  mandatory  Driveletter to be used with the partition
                                   as displayed in the DFSee tables.
                                   Specify '-' to clear the driveletter

                ns      optional   No Synchronize with NT registry and the
                                   dynamic NT drive-letter assignment.
                                   Otherwise a complete sync between DFSee
                                   and the registry will be done, comparable
                                   with the "NTMAP sync" command.

 Options:       -d[:nr]      : Use current or [specified] disk for relative PID



 Output:        Progress information and confirmation messages

 Remarks:       Setting the driveletter as used in DFSee tables works for all
                versions. However, the real use is with the NT version where
                the driveletter as used by NT itself will change too!
                It will be updated in the "Disk" key in the registry and in
                the dynamically maintained DosDevice mapping

                It might be wise to reboot or shutdown quickly after changing
                critical drive-letters like the WINNT system or boot drive.

                To change driveletters and other related info for systems
                with LVM (OS/2 4.5, eComStation) use the LVM command.
_______________________________________________________________________________

 SETNAME    pid        [BM-name] = Set or reset BootManager name for partition

 Purpose:       Set or clear the name for a partition, adding it to the menu

 Parameters:    pid     mandatory  Partition id, see PART and MAP display
                pid,r              Relative PID, on current or specified disk

 Options:       -d[:nr]      : Use current or [specified] disk for relative PID

                BM-name optional   When specified, this is the name to be
                                   used in the BootManager menu. (length 8)

                                   When not specified, the partition will
                                   be removed from the menu by clearing the
                                   name in the BootManager administration.

 Output:        Progress information and confirmation messages

 Remarks:       To change the volumename and other related info for systems
                with LVM (OS/2 4.5, eComStation) use the LVM command.
_______________________________________________________________________________

 SETTYPE    pid  disk new  [old] = Change partition-type from old to new

 Purpose:       Change the system-type for a partition to a new value

 Parameters:    pid     mandatory  Partition id, see PART and MAP display
                pid,r              Relative PID, on current or specified disk

                disk    mandadory  Disknr, * or 0, used for verification

                new     mandatory  New system-type, hexadecimal or symbolic

                        The most used system-types are:

                        hex   sym

                        01   FAT12  =  FAT12
                        04   FAT16  =  FAT16 < 32 MiB
                        05   EXT    =  Extended partition (chain)
                        06   FAT    =  FAT16 > 32 MiB
                        07   IFS    =  Installable File system
                        07   HPFS   =  IFS, HPFS (alias)
                        07   NTFS   =  IFS, NTFS (alias)
                        0a   BMGR   =  OS/2 BootManager
                        0b   FAT32  =  FAT32 small and below cyl 1024
                        0c   FAT32X =  FAT32 large or beyond cyl 1024
                        0f   BIGX   =  Large extended (PQMAGIC 4.0)
                        82   SWAP   =  Linux swap partition
                        83   EXT2   =  Linux EXT2 data partition
                        eb   BEOS   =  BeOS filesystem
                        fe   PS2S   =  PS/2 system partition

                old     optional   Existing system-type, for verification

 Options:       -e           : Force setting an extended type 0x05 or 0x0f


 Output:        Progress information and confirmation messages

 Remarks:       Only the type of the partition in the partition-table will
                be changed. The actual internal format of the partition is
                not affected by this operation.

                You can get an overview of all types with the 'TYPE' command.
_______________________________________________________________________________

 STARTABLE  pid  [multi | clear] = Make partition 'pid' startable (bootable)

 Purpose:       Make the selection partition the 'active' one to be booted

 Parameters:    pid     mandatory  Partition id, see PART and MAP display
                pid,r              Relative PID, on current or specified disk

 Options:       -d[:nr]      : Use current or [specified] disk for relative PID


                multi   optional   Allow multiple visible pri part'ns per disk
                clear   optional   Clear the 'active' flag to 'not-startable'

 Output:        Progress information and confirmation messages

 Remarks:       The partition status will be set to 'active' (0x80) and,
                if needed the partition will be made visible.
                All other primaries on the same disk will be made hidden,
                except when the 'multi' parameter was given.
                When 'clear' is specified, the active bit will be reset (0x00)
                and no change in visibility for any partition will be made.
_______________________________________________________________________________

 TYPE        [type | first last] = Show system-type description (for 00..ff)

 Purpose:       Show short description for one or more known system types

 Parameters:    type    optional   one system type to query
                first   optional   first type value for a range to show
                last    optional   last  type value for a range to show

 Output:        Single line when 'one type' queries, or 4 descriptions per
                line covering all known system-types from 00 through ff
                or from 'system-type' up to 'last' if a range is given.

 Remarks:       none
_______________________________________________________________________________

 VCU        disk  | * |  -d[:nr] = Clear existing LVM-info, create new defaults

 Purpose:       Create new LVM information like volume-name and partition-name
                Remove current LVM information when present.

 Parameters:    disk | *           Disk number or '*' for all disks

 Options        -d[:nr]            Disk number, or current disk

 Output:        Progress information

 Remarks:       This can be used to create default LVM-information with
                names derived from partition-id, filesystem-types and size,
                and assign the drive-letters as currently known to DFSee.
                The default volumenames will be taken from the current
                BootManager names or the drive LABEL when available.

                LVM additional information in the signature sectors, as used
                by LVM/JFS partitions (type 0x35) will not be cleared, so it
                is safe to use this command on a system with JFS partitions.
_______________________________________________________________________________

 VIRTUAL     Fname | size [H S] = Virtual disk from CURRENT, Fname or size/geo

 Purpose:       Create a new virtual disk based on supplied information

 Parameters:    layout  optional   Disk size and geometry, in several forms:

                  none     = Disk with same size and geometry as current

                  Fname    = Disk with size and geometry as in the *.PD*
                             file specified, created with the PSAVE cmd.
                             The file will be automatically restored on
                             the newly created virtual disk (PRESTORE).
                             This leads to a virtual disk with exactly
                             the same partitions as the original disk.
                             If a *.SN* file with exported list sectors
                             also exists, that will be imported as well.
                             This is a very fast and convenient way to test
                             with disk information from the DFSUNFD script.

                  size[[,d|x]m|g|c|s]  Specific size value, hex or decimal.
                                       in MiB, GiB, Cylinders or Sectors.
                                       Default: decimal Megabytes

                  H S      = Heads & Sectors to use with specified size

 Options:         -o-        Do NOT open the new virtual disk automatically



 Output:        Single line specifying the virtual and real disk-number

 Remarks:       The virtual disk created will be empty at start (zeroes).
                Only sectors written to will actually be created in memory,
                and this might be limited by the available memory.

                By default the created virtual-disk is opened, showing
                disk-geometry. This will allow direct and easy use from
                scripts, without knowing the actual disk number.

                A virtual disk is very useful when experimenting. An existing
                partition scheme can be copied by using PSAVE and PRESTORE.
                It is also used in DFSUNFD analysis and script testing.
_______________________________________________________________________________

 VREMOVE                   [ * ] = Remove last one made, or all virtual disks

 Purpose:       Remove virtual disk(s) from memory, freeing up resources

 Parameters:    *       optional   remove all existing virtual disks

 Output:        none

 Remarks:       There is usually no need to remove virtual disks, they
                automatically disappear when DFSee ends
_______________________________________________________________________________

 VSTATUS                         = Show R/W and usage status of virtual disks

 Purpose:       Show nr of sectors in use and read/write statistics for virtuals

 Parameters:    none

 Output:        A few lines with statistics for every virtual disk
_______________________________________________________________________________

 W2KBM     [disk]                = Make IBM's BootManager Windows-2000-Proof

 Purpose:       Make BootManager sectors survive a Win-2000 CHKDSK operation

 Parameters:    disk    optional   Nr of the disk containing BootManager

 Output:        Prompting, progress and confirmation information.

 Remarks:       The method used is based on a C't article and uses the
                FAT bootsector field 'reserved sectors to 1st FAT' to
                protect the BMGR data area

                Some additional changes were inspired by Daniela Engert and
                avoid the nasty CHKDSK screen while booting W2K (ver 3.36)

                Another (not DFSee related) thing you might do to avoid
                any conflicts is to hide your HPFS volumes from WIN2000.
                If you don't you will sometimes be prompted with the
                frightening: "Volume is not formatted, format it now?"
                If you reply with "YES" you just lost your HPFS partition!

                To hide a volume from normal WIN2000 programs like Explorer:

                Start
                  Settings
                    Control Panel
                      Administration Tools
                        Computer Management
                          Disk Management

                            Now select the HPFS partition from the list,
                            based on drive-letter and/or partition size.
                            Use right mouse button to get the context-menu

                              Change Driveletter and paths ...

                              Now click the [remove]  button

                This will only remove the DRIVE-LETTER association for that
                partition in WIN2000, the partition itself is not touched!
_______________________________________________________________________________

 WALK       [disk]               = Select disk and walk MBR/EBR chain, reset

 Purpose:       Show all partitioning information for the specified disk

 Parameters:    disk    optional   disk nr, default is current if open or 1

 Options:       -r                 reset previously forced geometry
                -R                 open the disk in Read-only  mode
                -R-                force the disk in Read-write mode

 Output:        Disk Geometry, MBR and all linked EBRs in partition format.
                EBR chaining errors like backward links and logical loops
                will be detected and warnings or errors will be displayed.

 Remarks:       The dfs_number variable for REXX will be set to nr-of-disks
                See also: DISK command (dfscmds.txt)
_______________________________________________________________________________
