logo
http://www.partition-saving.com
Copyright © 1999-2019 D. Guibouret

Manual

Table of contents

  1- License and preface
  2- Introduction
  3- System requirements
  4- Interface features/functions
     a) Textual windows interface
     b) Command line interface
  5- Using the program
  6- Saving an element
     a) Support choice:
     b) Source element choice:
     c) Part to save:
     d) Swap files directory:
     e) File choice:
     f) File size choice:
     g) Compression choice:
     h) Log file choice:
     i) Saving window:
     j) Options file creation:
     k) Examples:
  7- Restoring an element
     a) Backup file choice:
     b) Log file choice:
     c) Destination element choice:
     d) Restoring window:
     e) Examples:
  8- Copying an element
     a) Support choice:
     b) Source element choice:
     c) Part to save:
     d) Destination element choice:
     e) Copying window:
     f) Examples:
  9- Copying a backup file
 10- Verifying a backup file
 11- Updating Windows 2000/XP/Vista/Seven registry
     a) Support choice where Windows is installed:
     b) Element choice where Windows is installed:
     c) Directory where Windows is installed:
     d) Disk choice where partition to update is:
     e) Partition to update choice:
     f) Drive letter of partition to update:
     g) Confirmation:
     h) Example:
 12- Updating Windows Vista/Seven boot configuration
     a) Bootable support choice:
     b) Bootable element choice:
     c) Boot configuration data file choice:
     d) Disk where partition to update is choice:
     e) Partition to update choice:
     f) Boot entry to update choice:
     g) Confirmation:
 13- Updating BOOTSECT.DOS/BOOTSECT.BAK file
     a) Support choice where BOOTSECT.DOS/BOOTSECT.BAK file is:
     b) Element choice where BOOTSECT.DOS/BOOTSECT.BAK file is:
     c) Confirmation:
 14- Fixing disk physical definition into boot sector
     a) Support choice where fixing boot sector:
     b) Element choice where boot sector is:
     c) Correction of first sector value:
     d) Choice of new physical definition:
     e) Giving manual values:
     f) Correction of support number value:
     g) Confirmation:
 15- Replacing a boot sector or a superblock by its copy
     a) Support choice where copying boot sector/superblock:
     b) Element choice where boot sector/superblock is:
     c) Choice of copy to use:
     d) Exploring partition:
     e) Confirmation:
 16- Simulating an element
     a) Use of driver:
     b) Simulating an element:
     c) Remarks:
 17- Creation of files on NTFS drive
 18- Reset bad sectors in filesystem
     a) Support choice where bad sectors shall be removed:
     b) Element choice where bad sectors shall be removed:
     c) Confirmation:
     d) Execution:
 19- Explore a partition
     a) Choice of support where partition to explore is:
     b) Choice of partition to explore:
     c) Exploration window:
     d) View window:
     e) Edit window:
     f) Copy destination:
     g) Copy execution:
     h) Execution in command line mode:
 20- Explore a backup
 21- Change of boot partition
     a) Choice of disk where partitions table is:
     b) Boot partition choice:
     c) Confirmation:
 22- Create files marking drives to use
 23- Load an options or marker file
 24- Options file contents
 25- Mounting a partition
 26- Notes on what elements can be saved
     a) The complete disk:
     b) The Master Boot Record (MBR):
     c) First sectors of disk:
     d) Partitions table (MBR):
     e) Partitions table (GPT):
     f) Partitions (all sectors):
     g) Partitions (only occupied sectors):
     h) FAT (12, 16 and 32) partitions (DOS/Windows):
     i) Ext2fs/ext3fs/ext4fs partitions (Linux):
     j) NTFS partitions:
     k) Boot sector/superblock:
     l) Floppy disks:
     m) DOS/Windows/Linux devices:
     n) Raw files:
 27- Differences between DOS and Windows versions
     a) All versions of Windows:
     b) Windows before Windows 95:
     c) Windows 95/98/Me:
     d) Windows NT/2000/XP/Vista/...:
     e) Windows 64 bits:
 28- Differences between DOS and Linux versions
     a) All versions of Linux:
     b) Secured versions of Linux:
     c) Linux 64 bits:
 29- Log file
 30- What is not supported
 31- What cannot be tested
 32- Acknowledgements


1- License and preface

This program may be copied and freely redistributed. It may not be sold in any way, either alone or included in another program. All that is in this package must be kept together in its original form.

This program is offered as-is without any guarantee. No pursuit can be engaged against its author in case of damages due to this program.

This file is the complete version of manual and has many details. If you begin to use Partition-Saving, you can read the HOWTO before to see how to use it, then come back to this file if you need further details.

All remarks are welcome.


2- Introduction

The goal of this program is to achieve saving, restoring and copying of elements of storage device. An element can be a whole hard disk, a floppy disk, the Master Boot Record (first sector of hard disk containing boot code), the partitions table or a partitions. This permits saving hard disk contents to restore it later in case of a problem, without losing time reinstalling and reconfiguring software.
This program allows running the following tasks:

For detailed information about partitioning and this program, please read additional information.


3- System requirements

Hardware:

Software: To use DOS version, you need a bootable DOS floppy or CD (or a DOS partition on your disk). If you do not have one, you can use the boot disk that includes Partition-Saving (see spartbdk documentation) to create a bootable floppy or CD. You can also create your own floppy disk (see FAQ question 10).
To use Windows version, you need a second Windows installation or a WinPE or BartPE CD or use the Windows Vista/Seven repair console because program cannot save/restore the active system.
To use Linux version, you need a second Linux installation or a liveCD or use the repair console that is on most installation CD because program cannot save/restore the active system.
Using this program with an emulator with accessing a not emulated disk is not recommended (especially if it runs in a multitasking environment).
This program shall be used after a boot of computer without leaving any OS into some hibernation mode because in this case modification made by this program can disallow this OS booting back or OS can undo what program does.
You will need also a FAT, NTFS or ext2 partition (or any other filesystem for which you have a DOS driver that allows access to it) to create backup file (this is not needed if you merely want to copy a partition, since no file is created).


4- Interface features/functions

Two interface types are available:

The default interface is the first one. The second one is here to resolve some incompatibility issues on some computers.
To decide which interface to choose, please read chapter 5.
a) Textual windows interface

Interface can be used with keyboard or mouse. Keys common to all windows are:

If no item seems to be selected, press one of these keys to select first or last one.
In general, Enter key activates Ok button (if no other button is selected) and Escape key activates Cancel button.
Various features of windows are presented below:
b) Command line interface
This interface is more basic and can only be used with the keyboard. Pressing the Escape key at any time stops execution of the program.
Various features are:


5- Using the program

Usage:
savepart.exe [-l en|fr|fr_2] [-cm|-nm|-pm] [-f <options file>] [-fp <partition marker file>|-fd <device marker file>] [-ff <drive marker file>] [-fnc] [-ncd] [-ncs] [-nvd|-vd] [-nvf|-vf] [-tds] [-cui|-tui|-tuix|-bui|-buix] [-beep|-beep=<nb>] [-utf8|-noutf8] [-force] [-nocrc] [-noroot] [-hiber=warn|exit|ignore] [-term <terminal>] [-termopt <terminal command execution flag>] [-a|-b|-c|-d|-e|-g|-i|-k|-m|-n|-r|-s|-t|-u|-v|-w|-x|-z]
To use the Windows version, spartwin.exe (32 bits) or spartw64.exe (64 bits) shall be used instead of savepart.exe.
To launch the Linux version, spartlnx.run (32 bits) or spartl64.run (64 bits) shall be used instead of savepart.exe.
In Windows and Linux versions, same options are available, but some of them will have no effect (see below).

  -l: this option allows you to select which language to use. You only have to use this option if the automatically recognised language is not correct. If an error occurs before this option is analysed, the error message will be written with the automatically detected language. Recognised languages are:

In DOS, detection of language sets language to French when detecting France, French Canada, French Guyana, French Antilles or French Polynesia settings, otherwise it is set to English.
In Windows, detection of language sets language to French when language settings are French one, otherwise it is set to English.
In Linux, detection of language sets language to French when "LANG" or "LC_CTYPE" environment variables begin with "fr" (whichever case is used). If characters are wrongly displayed (either with square or interrogation mark), you could have to change the terminal settings from UTF-8 to your country code page (as ISO-8859-1 or ISO-8859-15 for France) and you need to launch program again.
fr_2 is to be used in case accents are not well displayed. It is not automatically detected.

  -cm: this option is the default way the mouse is utilised.

  -pm: this option is another way to utilise the mouse that can be used in case the first one does not work (it is default method when using DOS version on Windows NT/XP). Using this method may prevent detecting some double clicks. This option is equivalent to -cm into Windows version. In Linux version, program does not try to install its own mouse handler but fully relies on ncurses one.

  -nm: this option disables the mouse. You would have to use it only if mouse use seems to pose a problem with 2 previous methods.

  -f <options file>: this option allows you to use batch mode. To understand the contents of this file, please read chapter 24.

  -fp <partition marker file>|-fd <device marker file>: this option allows you using another way to designate the partition (-fp) or device (-fd) to save or restore: program searches for marker file you give (by scanning all partitions or devices) and uses the partition/device on which this file is found. To get more information on these options, please read chapter 22.

  -ff <drive marker file>: this option allows you using another way to designate the drive where is backup file: program searches for marker file you give (by scanning all partitions or devices, then all drives) and uses the drive on which this file is found with using the name of this file as base for backup file name. To get more information on this option, please read chapter 22.

  -fnc: this option disables confirm of found partition/drive when using -fp, -fd and -ff options.

  -ncd: this option disables the check that created/read file is not on saved/restored element. It is generally recommended only if DOS drive letter attribution is wrong. This option has no influence in Windows and Linux versions (this check cannot be disabled).

  -ncs: this option disables the check on free size on drive where backup file is created. This is a workaround in case the driver report a wrong free size, but you have to be aware when using this option to not provide a too big maximum file size else saving will fail.

  -nvd|-vd: this option disables/enables the check that sectors are correctly written. It is disabled as default. This speeds up restoring, but may prevent detecting bad sectors on the disk. The check that sectors are correctly written cannot be enabled in Windows and Linux versions (less for floppy disks in Windows 9x).

  -nvf|-vf: this option disables/enables the check that files are correctly written and that sectors are correctly written when using DOS devices access. It is disabled as default. This speeds up saving (and/or restoring), but created files or restored devices may be incorrect because the disk where they are written is damaged. The check that files are correctly written cannot be enabled in Windows and Linux versions.

  -tds: this option enables check of disk size with relying on partitions table content (for disk with extended access) or with searching last cylinder (for disk with standard access). This option is needed only if partitions do not appear on displaying of what can be saved/restored.

  -cui|-tui|-tuix|-bui|-buix: this option allows you to select the user interface:

If this option is not given, textual window interface is used. This option has to be used only if this interface poses a problem (for example nothing appears when the program begins). In this case, you can first try the -bui option, and if it still does not work, use the -cui one.

  -beep|-beep=<nb>: some beeps are generated at regular time when performing backup/restore (see "beep=" option to get more details). Without value, beeps are generated every 10 seconds, else they are generated every <nb> seconds.

  -utf8|-noutf8: forces use or not use of UTF-8 terminal capability in Linux version. The default behaviour is to detect it automatically.

  -force: allows testing all filesystem types on a partition even if they are not compatible with partition type. On restoration forces it even in case destination does not match constraints stored in backup (in this case, there is NO GUARANTEE on result). Constraints that are still checked are that type of support is the same (you cannot restore backup of a disk on a partition), size of sector is the same and that size of support is at least equal to size in backup. Constraints that are not checked depend on what is in backup but can be that physical definition (number of heads, cylinders, first sector) is the same or support is not bigger than maximum size. That can lead to big amount of space unused at end or wrong partition definition leading it to be unreadable or unbootable. Use of some capability of this program can correct some of these problems (as fixing of physical definition). This option shall be used only in case of troubles and when you know what you do.

  -nocrc: avoids program to stop in case of backup file's checksum having an invalid checksum. Depending on used backup options, restore could fail for some other reason (as when file is compressed, decompression algorithm will certainly be unable to uncompress data). As the backup file is damaged, obtain restoration will be corrupted.

  -noroot: avoids program to check if user has administrator's rights. It only avoids a potential warning message telling all support could be not seen in case user does not have administrator's rights.

  -hiber=warn|exit|ignore: what program shall perform if it finds an hibernated operating system. An hibernated operating system does not have flushed content of disk and will not refresh it on startup, so modifying disk could lead to incoherences or corruptions. As default, program searches for such system to warn you in case it finds some.

  -term <terminal>: this option is specific to Linux and Windows versions.
In Linux version, if program finds it does not run in a terminal, it launches itself into a terminal with using the "xterm" command (this mechanism is useful if you double click on program from a file explorer). This option allows setting command to use to create the X terminal in which running program instead of "xterm". If <terminal> is equal to "no", program does not try to create a terminal even if it finds it is not executed into a terminal.
In Windows version, program tries to launch a new console to ensure the mouse quick edit mode is disabled (thus allowing use of mouse). Using this option (whatever <terminal> value is) disables this behaviour.

  -termopt <terminal command execution flag>: this option is specific to Linux version. It allows giving flag used by terminal program to execute a command with arguments. It is "-e" as default that is value for "xterm" program.

  -a|-b|-c|-d|-e|-g|-i|-k|-m|-n|-r|-s|-t|-u|-v|-w|-x|-z: this option allows selecting which action to do:

If none of these options are given, the program asks what you want to do screenshot. For information about each action, please read subsequent chapters.

Return code of program can be one of the following:

Remarks:


6- Saving an element

This is the part executed when you use the -s option or select it when the program asks you.

Execution follows the diagram below (if not in batch mode):


            Support choice
                  |
                  V
        Source element choice
                  |
                  V
            [Part to save]
                  |
                  V
        [Swap files directory]
                  |<------------------------+---+
                  V                         |   |
             File choice                    |   |
                  |                         |   |
                  V                         |   |
           File size choice                 |   |
                  +-------------------------+   |
                  V                             |
          [Compression choice]                  |
                  |                             |
                  V                             |
           [Log file choice]                    |
                  |                             |
                  V                             |
            Saving window                       |
                  +-----------------------------+
                  V
        Options file creation
                  |
                  V
                 End
a) Support choice: screenshot
You have to choose the disk, floppy drive, DOS/Windows/Linux device or raw file where the element to be saved is located.
Hard disk access modes are: For floppy drive, access is always standard access and for DOS/Windows/Linux devices it appears as extended for Partition-Saving, but as it is the DOS/Windows/Linux driver that accesses the device, it is this last one that choose access mode.
b) Source element choice: screenshot
This window allows you to select what part of the disk to save. For floppy drive, this window does not appear.
For DOS/Windows devices, you can choose the device to save from the list given you which DOS/Windows understands as having a sector access. For the DOS version, this will be limited to those having FAT filesystem as it is the only filesystem known by DOS. For Linux devices, it gives list of block devices that appear into /etc/fstab, /etc/auto.master, /etc/autofs/auto.master files and that are not mounted or all detected devices if /dev/fuse file exists.
For raw files, you can choose the name of the file to use as file of support.

Remarks:

c) Part to save:  screenshot
This window only appears if chosen partition is of a type which permits saving only occupied sectors. In this case, it proposes the following choices: If partition to save is not a partition for which saving only occupied sectors is available or if you have chosen an element that is related to disk, this window will not appear and all sectors will be saved.
To have more information on saving only occupied sectors, please read chapter 26.

Remark:

d) Swap files directory: screenshot
This window appears only if you chose "Element without swap files" or "Element on itself without swap files" option in the previous window. It allows telling the program which directory contains the swap files. In addition to the directory you choose here, the program also searches for them in the root directory (you can obviously give the root directory here also). As a general rule, swap files are either in the root directory or in the Windows directory. To select the directory you have to go into the tree (with displaying subdirectories of a directory by pressing the "+" key when it is selected if necessary) until you reach it, then press Enter or click the Ok button.
e) File choice: screenshot
In this window you can choose the name and location of the file in which to save partition data. For this purpose you can type into "File" line the name of the file (with possibly its path) or select one from the files list or select another directory with drives and directories lists. By default "*.*" is displayed in DOS and Windows or "*" in Linux, which means that all files are shown. You can also create some directory (this shall NOT be done on the saved partition even if you chose to save it on itself) or mount a partition. Mounting a partition allows you to access a partition that cannot be used by DOS/Windows, such as an NTFS (for DOS version) or ext2 partition you want to write a backup file on. For have more details on mounting a partition, please read chapter 25.
A second window gives you the option to use automatic naming and log file. With automatic naming, the program will generate a file name automatically for following files if several files are needed. To accomplish this purpose, the program uses the first filename and changes (or adds) the two last characters of file extension (last three if more than 100 files are needed) by file number (with using 0 for number of first file). For example if your first file is called "disk_c.par", the second one will be "disk_c.p01", the third "disk_c.p02", ..., the hundred and first "disk_c.100". Log file will enable storing error messages in a file (see chapter 29).
A third window gives you the list of drives with free space and the full size of the partition (without taking into account the fact that only occupied sectors might be saved and whether compression is used).

Remarks:

f) File size choice: screenshot
This window permits you to choose the maximum size you want for the file. If more space is needed to save the element, a new file will be asked of you when this one is full. If free space on the drive is less than 10 MB, asked size is in kB, else it is in MB. This maximum size cannot be bigger than drive free space or 2047 MB, whichever is smaller. If you used the "-ncs" option, drive free space is not checked.
If you enter 0, you go back to the file choice window.
To give the size you can either use the line entry or choose a predefined value into the list.
g) Compression choice: screenshot
If you have enough memory, a window asks which compression level you want to use to compress data. The level goes from 0 (no compression) to 9 (maximum compression). Level generally used by the compression routine is level 6. The higher the compression level, the longer the execution time will be (but only a small change when expanding).
If you do not have enough memory, a window will inform you of this. In this case no compression is done (<=> 0 level).
This window will be displayed only for the first file (for subsequent files the same compression rate is used).
The compression algorithm used is the gzip algorithm.
h) Log file choice:
This window appears only in case you check option to create log file when the name of the backup file is requested. You have to give the name of the file where you want to store all errors message displayed by program. You can refer to chapter 29 to get more details on log file.
i) Saving window: screenshot
This window shows the backup progress.
The upper progress bar shows progress for element being saved. The lower progress bar shows progress for file in relation to its maximum size. Consequently, it is not unusual for this progress to not reach 100% when saving ends.
Remaining time is an estimate of remaining time. Its accuracy is strongly influenced by compression or saving of only occupied sectors.
Errors list is the list of errors detected when reading sectors on the disk. If you have the same errors when restoring and if, when you use a disk checking program (like surface checking with scandisk), bad sectors appear, these errors have no consequence (if there was no data on these sectors before saving, but that is a rule of the OS).
If the maximum file size you have given is not enough to save the entire element (progress bar for file reaches 100%), a new file name is asked of you with a new maximum size (if you use automatic naming, this happens automatically, with the same maximum size as the first file).
While saving is running, you cannot activate the Ok button (only cancel button can be activated to stop saving). When saving is finished, the Ok button becomes active, the cancel button inactive, and line marked "State" changes from "Running ..." to "Ended.".
j) Options file creation:  screenshot
If you do not use batch mode (or if some options have been added to those given in batch mode), a window will ask you if you want to create an options file that will allow you to use batch mode for future save/restore of this partition. If you answer "yes", a window will ask you to give its name. This file will contain all the options you have used. Another window is displayed to allow you adding a comment at begin of this file (program automatically adds ";" before comment).

Remarks:

k) Examples: 
Suppose you have 2 hard drives partitioned as described below (next to partition type are <DOS>|<Linux> drive names):
Disk 1
Main partition 1:
DOS FAT 32              (C:|hda1)
Main partition 2:
DOS extended            (  |hda2)
Extended partition 1 of
main partition 2:
DOS FAT 32           (E:|hda5)
Extended partition 2 of
main partition 2:
DOS VFAT 16          (F:|hda6)
Main partition 3:
Linux extfs2            (  |hda3)
Main partition 4:
Empty                   (  |hda4)
Disk 2
Main partition 1:
DOS FAT 32              (D:|hdb1)
Main partition 2:
DOS extended            (  |hdb2)
Extended partition 1 of
main partition 2:
DOS FAT 32           (G:|hdb5)
Main partition 3:
Empty                   (  |hdb3)
Main partition 4:
Linux swap              (  |hdb4)

If you want to save the partition containing the D: drive, you execute savepart.exe -s, then:

From this point, saving proceeds. If 620 MB is not enough to store all data, you will have to give a path and file name for a second file, then its maximum size, etc. Once saving ends, you can decide to create the batch file or not. If you create a batch file and burn files onto CD, put the batch file with the first backup file and don't forget to change the path of the backup file in the batch file.

If you want to save the Linux partition, you must:

and then continue as in previous example (since the Linux partition is on the first disk, it is better to create the backup file on the second disk).


7- Restoring an element

This is the part that is executed when you use the -r option or select it when the program asks you.

Execution follows the diagram below (if not in batch mode):


             Backup file choice
                  |
                  V
             [Log file choice]
                  |
                  V
      Destination element choice
                  |<------------------------------+
                  V                               |
           Restoring window                       |
                  +-----> Backup file choice -----+
                  V
                 End
a) Backup file choice: screenshot
This is the same window as the one used for file choice when saving. The selected file header is verified and an error is displayed if it is incorrect.
Automatic naming can be selected for subsequent filenames to be generated automatically (filenames must follow rule described in chapter 6.e). You can also mount a partition if the backup file is on a partition that DOS/Windows/Linux is not able to access.
b) Log file choice:
This window appears only in case you check option to create log file when the name of the backup file is requested. You have to give the name of the file where you want to store all errors message displayed by program. You can refer to chapter 29 to get more details on log file.
c) Destination element choice: screenshot
This window gives a list of elements that are compatible with what is saved in the file. You must choose one of the elements in this list to do a restoration.
At the top of the window is a description of the saved element. Below is the list of compatible elements. In case support where you want to restore backup does not appear, you can choose item before last in list to choose this support and see why it is not compatible.
As last choices, you can create or update a raw file. Creation will create (or replace if file already exists) a file that contains the whole saved support content (so will be as big as this support). Update will modify an already existing file (this one needs to have a coherent size).
For more details on element compatibility, please read chapter 26.
If no compatible element is found, a message tells you this and the program ends.

!!!!! Warning !!!!!: screenshot
Restoring erases all data currently present on the chosen element.
Moreover, you must NOT choose the disk (when restoring a whole disk) or the partition on which the file used for this restoration is located (indeed it would be erased during restoration and thus would no longer be accessible, causing an error and stopping the restoration).
A warning window informs you if the selected file is located on the disk or partition to be restored. This window is only displayed for the first file (for subsequent files, you must NOT access the disk or partition you are restoring) and is not displayed if you used the "-ncd" option.

d) Restoring window: screenshot
This window permits you to watch the restoration progress.
The upper progress bar shows file progress.
The lower progress bar progress for the chosen element.
Remaining time is an estimate of remaining time. Its accuracy is strongly influenced compression, or saving of only occupied sectors.
Errors list contains list of errors that were detected when writing sectors on disk. If errors are the same as those on saving, there is no consequence (if they are not the same, or if they are fewer or more, you can have lost data: run a program like scandisk to try to resolve this problem).
If the element has been saved into several files, you must give them when they are asked of you.
While restoring is running, you cannot activate Ok button (only cancel button can be activated to stop restoring). When restoring is finished, Ok button becomes active, cancel button inactive, and line marked "State" changes from "Running ..." to "Ended.".

!!!!! Warning !!!!!:

e) Examples: 
Consider the same partitioning presented in the above examples for saving partitions, and now you want to restore the partitions previously saved.
In the case of restoring the D: drive, you execute savepart -r and: Once restoring ends, reboot your computer for DOS to take into account modifications done onto the D: drive.

If you want to restore the Linux partition, you do the same things as above. In this case only the third partition of the first disk will be listed as it is the only Linux partition (the Linux swap partition does not have the same filesystem).


8- Copying an element

This is the part executed when you use the -c option or select it when the program asks you.

Execution follows the diagram below:


            Support choice
                  |
                  V
        Source element choice
                  |
                  V
            [Part to save]
                  |
                  V
      Destination element choice
                  |
                  V
            Copying window
                  |
                  V
                 End
a) Support choice: 
Please refer to the same description in the "saving element" chapter (chapter 6.a).
b) Source element choice: 
Please refer to the same description in the "saving element" chapter (chapter 6.b).
c) Part to save: 
Please refer to the same description in the "saving element" chapter (chapter 6.c).
d) Destination element choice: 
Please refer to the same description in the "restoring element" chapter (chapter 7.c) replacing all references to "file" by "element to copy".
e) Copying window: 
This window permits you to follow copying progress.
Upper progress bar is progress for the element being copied.
Lower progress bar is progress for the destination element.
Remaining time is an estimate of remaining time. Its accuracy is strongly influenced by whether all sectors or only occupied sectors are copied.
Errors list is the list of errors that were found when reading sectors on the element to be copied or when writing sectors on the destination element. If some errors appear, it is advisable to use scandisk or an equivalent program on the faulty element.
As long as the copy is running, you cannot press Ok button (only cancel button is active to stop copying). Once copying is finished, Ok button becomes active, cancel button inactive and line marked "State" changes from "Running ..." to "Ended.".

!!!!! Warning !!!!!:

f) Examples: 
Take the same partitioning presented above in the examples of saving a partition, and now you want to copy the partition containing the D: drive onto the partition containing the E: drive (assuming that size is compatible).
For that purpose, you run savepart -c and: From this point, copying begins. Once this is ended, reboot your computer.


9- Copying a backup file

This is the part executed when you use the -d option or select it when the program asks you.

This part allows you copying files, modifying their compression rate or maximum size. In case backup files contains all sectors of a disk or a partition, you can copy only a partition or occupied sectors of the partition (such as you can restore obtained files on another partition than the source one).

Execution follows the diagram below:


                       First file choice
Contains all sectors          |    Contains occupied sectors
           +------------------+------------------+
           V                                     |
   Ask for extraction                            |
           |    No extraction                    |
           +------------------------+            |
Extraction |                        |            |
           V                        |            |
   Source files check               |            |
           |                        |            |
           V                        |            |
  Part to copy choice               |            |
           |                        |            |
           +------------------+-----+------------+
                              |
                              V
                  First destination file choice
                              |
                              V
                            Copy
                              |
                              V
                             End

Program begins with asking you the source filename (please read chapter 7.a).

If file contains a backup of all sectors, program asks if you want to extract a partition (in case of a disk backup) or occupied sectors (in case of partition, floppy disk or DOS device backup)screenshot.

If you choose to extract a part of the file, program asks all backup files to check them. For the remaining part of execution, all these files shall be accessible simultaneously. It is better to avoid using this option in case the saving signalled some bad sectors. Once files are checked, program asks what you want to copy (this is similar to chapters 6.b to 6.d), then performs copy with simulating a saving (as into chapters 6.e to 6.h).

In case you do not choose to extract a part of the file, or if you have no choice, program asks the name and maximum size of the destination file and its compression rate (please read chapters 6.e, 6.f and 6.g), then copy begins. The copying window displays progress for the source file with the upper progress bar and progress for the destination file with the lower progress bar. If several source or destination files are necessary, they will be asked of you when they are needed.

Remarks:


10- Verifying a backup file

This is the part that is executed when you use the -t option or select it when the program asks you.

This permits verifying that backup files are valid. This verification consists of checking file headers, size and checksum of data (once they are expanded if they were deflated). If a saving was done in several files, you are obliged to check all files. No data is written on disk or is modified inside the files.

Execution begins with asking source filename (please read chapter 7.a). The checking window shows in the upper progress bar the state of the check for the current file. If saving was done in several files, subsequent files will be asked of you.


11- Updating Windows 2000/XP/Vista/Seven registry

This is the part that is executed when you use the -u option or select it when the program asks you.

Windows 2000 and followings store partition position in the registry in order to preserve association between a partition and its corresponding driver letter. Partition position is composed of two parts and depends on partitions table type:

So if you copy a partition onto another disk (without copying partitions table) or if you move the beginning of a partition (for MBR partitions table), you have to update the information in the registry for each partition that you moved for Windows to be able to still use the same drive letter. In the case of restoring a partition which has not been moved, this is not necessary.

Execution is composed of 2 parts: first, to designate where Windows is installed so that the program can find the registry file; second, to give the partition to be updated in this registry. If you copy the Windows 2000/XP/Vista/Seven partition, the Windows installation that should be updated is the one that was the destination of the copy.

It shall be noticed that this option does not allow to create a new drive letter into registry: you can only assign an already existing drive letter. This is not a problem as the need for this option is to set the drive letter of a source partition to the destination partition when restoring/copying to a destination partition that is not the same than source one.
In case you need to create a new drive letter, you can either use the Windows disk management tool (if it is not for the system partition) or edit registry with booting with a WinPE or BartPE CD.

Execution follows the diagram below:


    Support choice where Windows is installed
                        |
                        V
    Element choice where Windows is installed
                        |
                        V
      Directory where Windows is installed
 +--------------------->|
 |                      V
 |  Disk choice where partition to update is
 |                      |
 |                      V
 |        Partition to update choice
 |                      |
 |                      V
 |    Drive letter of partition to update
 |                      |
 |                      V
 |                Confirmation
 |                      |
 |                      V
 |         Change another drive letter?
 |                  yes |
 +----------------------+
                        | no
                        V
                       End
a) Support choice where Windows is installed: screenshot
You select the disk or DOS/Windows/Linux devices list where the Windows installation whose registry should be updated is located.
b) Element choice where Windows is installed: screenshot
You select the partition (if a disk has been chosen in the first window) or the DOS/Windows/Linux device (if DOS/Windows/Linux devices have been chosen in the first window) where the Windows installation whose registry should be updated is located.
c) Directory where Windows is installed: screenshot
You select the Windows installation directory. As a general rule, this directory is called "WINDOWS", unless you specified another name when installing it. If you give a wrong directory name, or if the installed Windows version is not correct, you will get an error message telling you that the registry file has not been found.
d) Disk choice where partition to update is: screenshot
You choose the disk which has the partition whose registry definition you want to update.
e) Partition to update choice: screenshot
You choose the partition for which you want to update the definition in the registry.
f) Drive letter of partition to update: screenshot
This window shows a list of driver letters that can be modified with their current definition. The first column is the drive letter, the second is the disk identifier where the corresponding partition is located, and the third column is the first byte of the partition on the disk. The last column displays the two previous columns as given by regedit.
You must choose from this list the drive letter you want to be associated with the partition selected with two previous windows. The program will modify the corresponding definition for this letter with the values defined at the top of the window.
g) Confirmation: screenshot
The program asks you to confirmation the registry modification. It gives you the key name that will be modified, its previous and new values. The value is composed of 12 hexadecimal digits, the first four being the disk number, last eight the offset of the partition on the disk (it is the same format as the last column of previous window).
h) Example:
Disk 1
Main partition 1:
Windows XP (C:)
Main partition 2:
Extended partition
Extended partition 1
of main partition 2:
Data (E:)
Extended partition 2
of main partition 2:
Swap file (F:)
Disk 2
Main partition 1:
Windows XP (D:)
Main partition 2:
Extended partition
Extended partition 1
of main partition 2:
Data (G:)
You have copied the Windows XP partition from disk 1 to disk 2. In this case, drive letter of Windows XP on disk 2 shall be C: for this Windows to be able to boot. So, you have to modify registry of Windows XP on disk 2 to swap drive letters.
For this, you have to launch Partition-Saving, choose the update registry option, choose disk 2 and first partition as partition where Windows is installed. Then you select first partition of first disk and give it the D: letter. Then you launch Partition-Saving again, again select first partition of second disk as Windows partition, then select first partition of second disk to give it the C: drive letter. If you copied also the data partition, you have to perform the same thing for second partitions with drive letters E: and G:.
Once you have performed this, if you boot with the first disk Windows XP, you still have the same configuration as above (this one has not been modified). But if you boot with the Windows XP on second disk, you get (considering you also swap data partitions drive letters):
Disk 1
Main partition 1:
Windows XP (D:)
Main partition 2:
Extended partition
Extended partition 1
of main partition 2:
Data (G:)
Extended partition 2
of main partition 2:
Swap file (F:)
Disk 2
Main partition 1:
Windows XP (C:)
Main partition 2:
Extended partition
Extended partition 1
of main partition 2:
Data (E:)
Note: once you done this, it can be a good idea to give partitions a different name to not mix them.


12- Updating Windows Vista/Seven boot configuration

This is the part that is executed when you use -w option or select it when the program asks you.

In order to manage boot, Windows Vista/Seven store into a file which partitions are bootable and where they are on disk following a way near the one used to associate a drive letter to a partition. This is similar to the way BOOT.INI works on Windows XP, but file cannot be edited because it is binary.
This option allows you modifying information in case you moved a system partition (either it is copied onto another disk, or its beginning position is modified on disk) and you have Windows Vista/Seven installed on your computer.

Execution follows the diagram below:


                  Bootable support choice
                             |
                             V
                  Bootable element choice
                             |
                             V
               [Boot configuration file choice]
                             |
                             V
           Disk where partition to update is choice
                             |
                             V
                Partition to update choice
 +-------------------------->|
 |                           V
 |              Boot entry to update choice
 |                           |
 |                           V
 |                      Confirmation
 |                           |
 |                           V
 |                  Change another entry
 |                       yes |
 +---------------------------+
                             | no
                             V
                            End
a) Bootable support choice: screenshot
This window permits you to choose on which support is file containing boot configuration data. In most cases this file is on bootable partition of the computer that is on first disk. This partition is often a small 100 MB partition that appears first on disk or the partition where Windows is installed.
The file containing boot configuration is named "\Boot\BCD", you can check for this file existence to know which support to choose (note: this file can be hidden).
b) Bootable element choice: screenshot
This window permits you to select partition on which boot configuration data are.
c) Boot configuration file choice: screenshot
This window is optional. It is displayed only if no boot configuration data file or both of them are found.
Boot configuration data file is "\Boot\BCD" for MBR BIOS and "\EFI\Microsoft\Boot\BCD" for UEFI BIOS. If both or none of them exist on selected partition, program ask you which one to use. You can also enter another filename.
As the window is not displayed if only one of the file is present, if you want to use another file, you can do it through using the "boot_BCD_file" option in options file.
d) Disk where partition to update is choice: screenshot
This window permits you to select disk that contains partition that was moved and that need an update of its boot information.
In most cases, only system partitions (those having a Windows installation as Windows does not manage others systems) need such an update, those containing only data do not need it.
e) Partition to update choice: screenshot
This window permits you to select partition that was moved.
f) Boot entry to update choice: screenshot
This window shows a list of boot entries that are defined with their current configuration. Above list is the description of chosen partition: displayed values will replace the ones in list for the selected entry.

The mostly encountered entries are the following:

As it is described above, several entries can reference the same partition. So if you moved the corresponding partition, you have to update all these entries one by one. What is described is a typical installation, you have to look at current value of entries to know which ones are linked to the same partition.

If an entry appears with all its data to 0, this means there was incoherence into its data or program gets a problem to read them. You have to be careful when updating it, it can lead to some others incoherence.

If an entry appears with a name between "{...}", it means program was not able to find its name and it uses the default one depending on entry type. If name is "{Unable to get name}", it is that even entry type cannot be found.

If a window is shown before, informing you that all entries were not read, these entries are not displayed and you cannot update them.

Example:
The screenshot shows the case where Windows Vista was not installed on the bootable partition (this can be deduced because two identifiers appear). If you move the Vista partition, you have to update the 2 first entries, and if you move the bootable partition, you have to update the 3 last entries.
If Windows Vista had been installed on the bootable partition, the 5 entries would have the same identifier and you would have to update all of them if you move the partition.

g) Confirmation: screenshot
This window requests you if you confirm the modification of entry you chose.


13- Updating BOOTSECT.DOS/BOOTSECT.BAK file

This is the part that is executed when you use -b option or select it when the program asks you.

In order to manage multiboot with another DOS or Windows version, Windows XP/Vista/Seven saves the boot sector of other Windows versions into BOOTSECT.DOS or BOOTSECT.BAK file on the same partition and modifies this boot sector to set a new one (this one asks for the Windows version to run depending multiboot configuration). If you choose to launch previous Windows version, it reads the BOOTSECT.DOS/BOOTSECT.BAK content and run it. Consequently, if you copy to another disk or move the begin of the partition where the other Windows version is, this file needs to be modified to reflect that. This option is for that purpose.

Warning: This option only modifies some parameters in BOOTSECT.DOS/BOOTSECT.BAK to take into account changes that may have been made in the boot sector; it does not allow creating or completing a BOOTSECT.DOS/BOOTSECT.BAK file.

Execution allows choosing the partition on which BOOTSECT.DOS/BOOTSECT.BAK file is located to update it according to the current boot sector of this element. Execution follows the diagram below:


Support choice where BOOTSECT.DOS/BOOTSECT.BAK file is
                     |
                     V
Element choice where BOOTSECT.DOS/BOOTSECT.BAK file is
                     |<-------+
                     V        |
                Confirmation  |
                     |        |
                     +--------+
                     |
                     V
                    End
a) Support choice where BOOTSECT.DOS/BOOTSECT.BAK file is: screenshot
You have to choose disk, floppy disk or DOS/Windows/Linux devices list on which is the BOOTSECT.DOS/BOOTSECT.BAK file to modify.
b) Element choice where BOOTSECT.DOS/BOOTSECT.BAK file is: screenshot
You have to choose the partition (if a disk has been chosen in first window) or DOS/Windows/Linux device (if DOS/Windows/Linux devices has been chosen in first window) on which is the BOOTSECT.DOS/BOOTSECT.BAK file to modify.
c) Confirmation: screenshot
The program asks you to confirm the BOOTSECT.DOS/BOOTSECT.BAK file modification. If you confirm, it will be modified to update some parameters according to those in the current element boot sector.
This confirmation is requested for each file to update (first BOOTSECT.DOS then BOOTSECT.BAK). If one of them does not exist or has wrong format, you will get an information or error message. As these files depend on which Windows versions are installed, it is not always an error for one of these files to not exist.
If you want to modify files others than default ones, you can give name of file to modify by using "file=" option of options file.


14- Fixing disk physical definition into boot sector

This is the part that is executed when you use -a option or select it when the program asks you.

This option permits you to change number of heads and number of sectors per track that are stored into FAT and NTFS boot sector.
This can be needed in case you have a problem as "NTLDR missing" or "IO.SYS not found" when booting and when you explore this partition you see these files (if you do not see them, you need to copy them with using SYS program in DOS/Windows 9x case or with using recovery console for Windows NT/2000/...). This error can be generated because physical definition of disk into boot sector is wrong (note: SYS and recovery console allow fixing this error also).

Execution follows the diagram below:


    Support choice where fixing boot sector
                     |
                     V
      Element choice where boot sector is
                     |
                     V
      [Correction of first sector value]
                     |
                     V
       Choice of new physical definition
                     |  Using predefined value
         +-----------+-------------------------+
         |                                     |
         V                                     |
Giving manual values                           |
         |                                     |
         +-----------+-------------------------+
                     |
                     V
      [Correction of support number value]
                     |
                     V
                Confirmation
                     |
                     V
                    End
a) Support choice where fixing boot sector:screenshot
You have to choose disk, floppy disk or DOS/Windows/Linux devices list on which is the partition or device for which boot sector shall be modified.
b) Element choice where boot sector is: screenshot
You have to choose the partition (if a disk has been chosen in first window) or DOS/Windows/Linux device (if DOS/Windows/Linux devices has been chosen in first window) on which is the boot sector to modify.
c) Correction of first sector value: screenshot
This window is displayed only if program finds that first sector value is wrong in boot sector. This value gives number of sectors on disk that are before the partition. In case this value is wrong, it can disallow the partition to boot if it is a bootable one. If it is not a bootable one, this has no consequence. In case you want to correct this value, you have to confirm it. The change will be effective only if you do not cancel execution in following windows.
If you want to choose another value than the one found by program (without it being current value), you can set it through options files (see "fix_first_sector" option).
d) Choice of new physical definition: screenshot
This window displays current values of boot sector and a list of predefined values. Content of this list depends on the support and the OS (some values can be missing) and it is normal that these values are different (this is the reason why fixing them in boot sector is needed).
These values can be: This list ends with an option to enter manual values (see below) and an option to keep current values (if you want to update first sector value without changing heads/sectors numbers).

Note: using values different from standard numbers for a disk using standard access is certainly a bad idea, because only these numbers shall be correct.

e) Giving manual values: screenshot
These windows are displayed in case you choose last option into previous window. They allow you to enter numbers you want in case no predefined value seems correct. Giving bad values will in most cases not result in lost of data (partition will not boot), but it is better to be cautious. Often correct values are power of 2 (16, 32, 64, ...) or power of 2 less 1 (63, 255, ...).
f) Correction of support number value: screenshot
This window is displayed only if program finds that support number value is wrong in boot sector. This value should be 0 for a removable media and 128 for a fixed media. In case this value is wrong, it can disallow the partition to boot if it is a bootable one. If it is not a bootable one, this has no consequence. In case you want to correct this value, you have to confirm it. The change will be effective only if you do not cancel execution in following windows.
If you want to choose another value than the one found by program (without it being current value), you can set it through options files (see "fix_disk_number" option).
g) Confirmation: screenshot
The program asks you to confirm the boot sector modification. If you confirm, boot sector and its copy (if there is one) will be modified.


15- Replacing a boot sector or a superblock by its copy

This is the part that is executed when you use -k option or select it when the program asks you.

This option permits you to replace a boot sector for a FAT/NTFS partition or a superblock for an ext2/ext3/ext4 partition with its copy. FAT32, NTFS, ext2, ext3 and ext4 filesystems define a copy of these sectors in order to be able to repair a partition if origin sector is corrupted. You can try to use this option if your partition appears suddenly as of "RAW" type instead of "FAT" or "NTFS" in Windows.

Execution follows the diagram below:


Support choice where copying boot sector/superblock
                     |
                     V
  Element choice where boot sector/superblock is
                     |
                     V
          Choice of copy to use
                     |
                     V
           Exploring partition
                     |
                     V
                Confirmation
                     |
                     V
                    End
a) Support choice where copying boot sector/superblock:screenshot
You have to choose disk or DOS/Windows/Linux devices list on which is the partition or DOS/Windows/Linux device for which boot sector or superblock shall be replaced by its copy.
b) Element choice where boot sector/superblock is: screenshot
You have to choose the partition (if a disk has been chosen in first window) or DOS/Windows/Linux device (if DOS/Windows/Linux devices has been chosen in first window) on which is the boot sector or superblock to replace.
c) Choice of copy to use: screenshot
This window gives list of boot sector or superblock copies that seem valid. In most cases, this list is either empty (no found copy) or has one item only. If several copies are found, it is better you explore partition (see next window) for each of them to check which one is the correct one.
When choosing a copy, if it is identical to current sector, program stops its execution as it does not need to update it. It shall be noticed that it is not unusual to have a superblock copy different from current one (even if current one is valid) because this one contains data that are updated with use (as number of free blocks) and ext2/ext3/ext4 Linux driver does not always maintain copy up-to-date.
d) Exploring partition: screenshot
This window requests you if you want to explore partition with using the copy of boot sector/superblock. This permits you to check if its content is valid with using this copy. Exploring runs as described into chapter 19, partition being mounted read only. When you exit exploration, you come back to this execution.
e) Confirmation: screenshot
The program asks you to confirm the boot sector/superblock modification. If you confirm, boot sector/superblock is replaced by its copy.
In ext2/ext3/ext4 case, as superblock copy can be not up-to-date, partition checking is forced for the next time it will be mounted for the superblock to be corrected.


16- Simulating an element

This section covers the use of the driver (DRVPART.SYS) and the options "-m" and "-i" for savepart. The purpose of this driver is primarily to allow access to a partition contained in a backup file in order to recover some files.
Note:
Because of option to explore a backup (see chapter 20) that has more capacity, this part is deprecated and will not be maintained in case of major change in backup file format.

a) Use of driver:
DRVPART.SYS is a DOS driver that allows simulating that a new drive letter is present. This drive is simulated with a backup file created previously.
As with all DOS drivers, DRVPART.SYS must be loaded into memory with the help of CONFIG.SYS. This text file is on the boot disk (either C: or A: depending on whether you boot from hard disk or floppy disk). For the driver to be loaded you have to add at the end of this file the line:
DEVICE=<path>\DRVPART.SYS <options>
where <path> is the directory where DRVPART.SYS is located. Once this line has been added, the next time you boot your computer, you will have a new drive (the drive letter is defined by DOS and is the next letter following those of your last drive).
DRVPART.SYS can have 2 parameters: Examples:
DEVICE=C:\DRVPART.SYS
Driver is loaded with default values of 512 bytes for sectors size and 1024 kB for memory.
DEVICE=C:\DRVPART.SYS 512 4096
Driver is loaded with values of 512 bytes for sectors size and 4096 kB for memory.

Memory allocated by the driver is a memory block which allows temporarily storing sectors requested by others programs. As needed, this size can dynamically be increased/decreased (but never goes bellow the size defined when loading). The worst case of memory use is certainly when a program wants to know free space on the drive (as when you do a "dir").
Memory used by the driver is XMS or EMS memory (depending on what is present). These are standard memory types (you do not need specific hardware) called XMS or EMS depending on the way it is managed. XMS memory is managed by HIMEM.SYS driver (a DEVICE=<location>\HIMEM.SYS line has to be present at the beginning of the CONFIG.SYS file) and EMS memory is managed by EMM386.EXE driver (or some other that does the same thing) (a DEVICE=<location>\EMM386.EXE line has to appear in CONFIG.SYS file just after the one containing HIMEM.SYS). If neither of these two types of memory is present, driver will not be loaded. Note that using EMS memory can limit useful memory size to 32 MB.
Driver can generate following messages when loading:

If one of the last three messages is displayed, the driver is not loaded.
b) Simulating an element:
Once the driver is loaded into memory, "-m" and "-i" options of savepart can be used (or associated actions appear in lists of actions if you do not specify an action option).
The first option ("savepart -m") or the choice "Simulate an element" in actions allows you to give the list of files to use in order to simulate the element they contain. Execution is done in the same way as when testing a backup file (chapter 10). Once execution has correctly ended, you will be able to use the added drive through the driver as if it is the partition that is in the backup file (If no element is simulated, accessing this drive returns an error).
The second option ("savepart -i") or the choice "Get information from driver" in actions allows getting information from driver (drive simulated, sector size and files used if an element is simulated) and stopping simulating an element if there is one simulatedscreenshot.
When simulating an element, more EMS/XMS memory can be needed by the driver. Unfortunately running savepart when only XMS memory is available means that savepart uses the whole memory and it is not possible to allocate more memory for the driver. In this case you will certainly get a "You do not have enough EMS or XMS memory: <n> kB free memory are needed." errorscreenshot. In this case you have to use the ALLOCXMS.COM program giving it <n> as a parameter in order for memory to be allocated before running savepart, then you can run savepart again (example: ALLOCXMS.COM 1024 will allocate 1024 kB memory). As this size depends on the partition simulated, it cannot be known (and so allocated) sooner. ALLOCXMS can display following messages:
c) Remarks:


17- Creation of files on NTFS drive

This option appears only when you are running the program under Windows NT and following. It allows you to create a file on a NTFS partition which can be used as a backup file by using partition mounting once you are running from DOS. This is due to fact that the program is not able to create files on a NTFS partition (only to read/write and resize) when it runs from DOS, so files you create here serve as a base. This option asks you names of files to be created until you hit the 'Cancel' button. If you use automatic naming, instead of asking you several files, it asks number of files you want to create.

Remarks:

Example:
You want to save a partition with 4 GB data into 680 MB files (to be able to burn them) with using partition. In this case you will have to create: 4*1024 / 2 / 680 = 3.011 => 6 files.


18- Reset bad sectors in filesystem

This is the part that is executed when you use -z option or select it when the program asks you.

This option allows removing that sectors are marked as wrong on a filesystem. It does not allow correcting bad sectors, it shall only be used in case you restore/copy a partition with bad sectors on another hard drive. This is automatically done by program when restoring but in case where source and destination disks and partitions are identical: in this case program thinks it performs restoration on the saved partition and so does not reset bad sectors information.

So this option shall only be used in one case: the one where you got an "X" into the "Idem" column on restoring/copying even when disk is not the same as the source one.

Notes:

Execution follows the diagram below:

 Support choice where bad sectors shall be removed
                         |
                         V
 Element choice where bad sectors shall be removed
                         |
                         V
                    Confirmation
                         |
                         V
                     Execution
                         |
                         V
                        End
a) Support choice where bad sectors shall be removed: screenshot
You have to choose disk, floppy disk or DOS/Windows/Linux devices list where filesystem to modify is.
b) Element choice where bad sectors shall be removed: screenshot
You have to choose partition (if a disk was selected into first window) or DOS/Windows/Linux device (if DOS/Windows/Linux devices list was selected into first window) on which bad sectors information shall be removed.
c) Confirmation: screenshot
Program asks for you confirmation of filesystem modifications. If you confirm, all bad sectors will be marked as valid back.
d) Execution: screenshot
Filesystem modification is running. Depending on filesystem type and partition size this can need more or less time (faster being for ext2 partition and slower for FAT partitions).


19- Explore a partition

This is the part that is executed when you use -e option or select it when the program asks you.

This option allows you navigating into a partition to copy or edit some of its files.
Execution follows the diagram below when used with textual window interface:


      Choice of support where partition to explore is
                         |
                         V
           Choice of partition to explore
                         |
                         V
+---------------> Exploration window
|                        |
|     +------------------+----------------------+
|     |                  |                      |
|     V                  V                      V
| View window        Edit window         Copy destination
|     |                  |                      |
|     |                  |                      V
|     |                  |                Copy execution
|     |                  |                      |
+-----+------------------+----------------------+
When it is used with command line interface, part starting from "Exploration window" is replaced by a command line prompt allowing using commands described in chapter 19.h.
a) Choice of support where partition to explore is: screenshot
You have to choose disk, floppy disk or DOS/Windows/Linux devices list where filesystem to explore is.
b) Choice of partition to explore: screenshot
You have to choose partition (if a disk was selected into first window) or DOS/Windows/Linux device (if DOS/Windows/Linux devices list was selected into first window) you want to explore.
c) Exploration window: screenshot
This window is the explorer window. It contains following items:
d) View window: screenshot
This window is a simple hexadecimal viewer to view file content. Actions that can be performed in this viewer are:
e) Edit window: screenshot
This window is a simple text editor. You can modify a file then save changes you made. This window is composed of:
Actions that can be performed in this editor are:
f) Copy destination: screenshot
This window permits you to choose where to copy selected files. In case you have selected one file that is not a directory, you can give it another name, else you can only give the directory where all files will be copied.
g) Copy execution: screenshot
This window shows files being copied and encountered errors.
Above the "->" line is the source file name in relative from source directory and below this line is the destination file name in relative from destination directory. In most case these two names are the same unless you copy from a partition with long filenames to a partition that does not support them (by using DOS access): program will use short names from corresponding long names, but it does not ensure that on destination partition this short name corresponds to the same file as the one from source partition. In this case it is better to use mounting mechanism to access FAT partition with enabling long names.
List of errors program gets is below the copied file names.
In case program found you try to copy a file to an existing file it asks if you want to overwrite it. A second check is done in case file is read-only.
When copy ends, the "Ok" button becomes active and the "->" line is changed into a message to signal if copy ends or was canceled before (either because you cancel it or because of some fatal error).
Notes:
h) Execution in command line mode:
When exploration is done with command line interface, you get a "> " prompt after having chosen partition or backup file to explore. From this prompt, you can execute several commands to read or modify content of explored partition. The prompt allows using following special keys: When you are inside a function declaration, prompt is preceded with "func <function name>", when interpreter is searching for a label, prompt is preceded with "label <label name>".
Exploration in command line mode uses several concepts that are common to shell interpreters that are described hereafter. But this shell interpreter has a quite reduced set of capabilities.
Variables
Variables allow storing some value to reuse it later. A variable has a name composed of any characters less "=", "<", "%" and "+". Some variables are reserved and cannot be modified: Value of a variable can be obtained with setting its name between "%" (%<variable>%). If you want to use the "%" character in a command you have to double it ("%%"). A variable can be set through the "set" command. A variable can be undefined through "unset" command. A variable can be defined as local through "local" instruction, in which case it is not visible when calling a script or a function and any future change done to this variable is not visible from function's caller.
When starting exploration, environment variables that are defined in system are automatically defined. Those corresponding to variables with a reserved name are discarded.
Error status
When executing a command, this one can generate an error or not. This information can be used to decide what to perform after command execution. This can be automatically done through the error status or checked through the "if" instruction. The error status is used when a command ends with an error and can be set through the "onerror" command which has several options: The "if" instruction has a specific condition ("error") to test if last executed command ends with an error or not.
Scripts
A script is a text file containing commands to execute. There shall be one command per line (empty lines and lines starting with ";" are ignored).
A script can be called through "ecall" or "scall" instruction followed by script name and its arguments. The whole file is executed until reaching its end or executing an instruction to terminate it ("exit", "quit", "end" or "return").
A script gets variables of its caller less those that were declared local and those corresponding to its arguments and gets error status and current directory of its caller. Changes it performs to variables, error status or current directory are discarded when it ends.
Functions
Functions are a list of instructions that can be called with some arguments. Functions are declared through "func <function name>" and ends at first "endfunc" instruction. They can be called though "fcall" instruction followed by function name and its arguments. A function remains local to the script where it is declared.
A function gets variables of its caller less those that were declared local and those corresponding to its arguments and gets error status and current directory of its caller. Changes it performs to variables are visible in its caller unless it declares a variable as local. Changes performed on current directory are kept when it ends. Changes performed to error status are discarded when it ends.
Labels
A label is a point of a script that can be reached through the "goto" instruction. It allows performing jump to avoid executing some part of a script or on contrary to loop over a part of a script (for this last case it shall be a "goto" done from "if" instruction or there shall be some other jump to go outside of the loop to not end in infinite loop execution). You can jump to a label that is still not declared in which case, all instructions until declaring this label are ignored less label and function declarations.
Labels are declared through ":<label name>" with label name that is composed of any character less " " or "%". A label is local to a script or a function and shall be unique among this script or function. You cannot reach a label declared elsewhere than current function or script in the exception of the "onerror goto <label name>" construction (if current script or function does not define this label and the error status was set from outside of this script or function, it is searched in caller). Trying to jump to a label that is not declared in a script or function ends with an error.
Current directory
When an instruction is executed, it is performed from a point in the directory tree called current directory (if you list directory content without providing some directory name, it will be content of this current directory). Because of the way exploration is done, there is two current directories notion: This is needed because program does not have same capability set depending on it is working on a filesystem it explores or filesystem it access through standard filesystem access (details is given in each command description). To avoid conflict in directory naming, most commands comes in two flavours: When being expressed in absolute, At start of exploration, explored partition current directory is its root directory and standard filesystem current directory is the last one you accessed.
There is a case where the explored partition's current directory and standard filesystem's current directory match, it is when you change standard filesystem's current directory to one of the explored partition through its mount point (unless you mounted some partition before starting exploration, this one is "0:" in DOS/Windows case or "//0" in Linux case): in that case changing explored partition current directory or standard filesystem current directory changes both directories (until you set standard filesystem current directory to some other directory tree than in explored partition one).
Example (considering having explored partition mounted as "0:"):
scd 0:\a_directory
; From this point both explored partition and standard filesystem current
; directories are "a_directory" on explored partition
ecd a_subdir
; Both are now "a_directory\a_subdir"
scd ..
; Both are "a_directory" again
scd C:\
; Explored partition current directory is still "a_directory" and filesystem
; current directory is "C:\"
ecd a_subdir
; Only explored partition's current directory has been modified to
; "a_directory\a_subdir"
Commands
This chapter describes all commands that can be used during exploration. In these descriptions: When commands have options starting with "-", you can force stopping options analysis with providing a "--" option (in case you want to use some file name starting with "-" as in "ecp -- -start_with_- .").
Some commands accept wildcard characters in filename (as "*" to match any sequence of characters). In that case, they use Linux convention (that means that "*.*" will only match files that have a dot in their name where DOS convention would have matched all files, you have to use "*" for that).
Commands you can use are the following:
Command Arguments/Description/Example
asfilename [-k] <string>
Transform the string such as some specific characters will be considered as valid in a filename (" ", "<", ">", "[", "]", "?", "*", "/", "\", ":", characters before " " and characters after "~").
In case "-k" is used, path separator characters ("\", "/" and ":") are kept as such.
A typical use of this command is to avoid some filename containing a space to be interpreted as being two arguments when being used with other commands.
;----------
asfilename a file with spaces
;----------
Outputs "a<20>file<20>with<20>spaces".
asstring <string>
Transform the string such as the specific characters are set back to ASCII (reverse operation of "asfilename").
In case a character matches an UTF-16 one, a warning is displayed and this character is replaced by "_".
;----------
asstring a<20>file<20>with<20>spaces
;----------
Outputs "a file with spaces".
[es]call <script> <argument>*
Read the given <script> on explored partition or system directory and executes it with using the given arguments. When the script returns, execution continues unless scripts ends with the "exit" or "quit" instruction.
Called script gets all variables that exist in caller less those corresponding to caller's argument and those declared as local. Variables that are set or modified during script execution are not retrieved by caller. The same applies for the error status and for current directory.
;----------
ecall my_script.txt first second
;----------
Reads the "my_script.txt" file and executes it with "first" and "second" as arguments.
[es]cat [-i|-c] <file>+
Display the given <file>. In case several files are given, they are displayed one after the other. Filename can contain some wildcard characters in which case all matching files are displayed (order is directory order). Binary files are displayed in hexadecimal form. Options are used in case of wildcard match and are:
  • -i: ignore case in file matching,
  • -c: force case matching.
Default use of case matching depends on used filesystem type (no case matching on FAT and NTFS filesystems, with case matching on ext2/3/4 filesystems).
;----------
ecat file1.txt file2.txt
;----------
Displays content of "file1.txt" and "file2.txt" files.
[es]cd [<directory>]
Displays name of the explored partition's current directory ("ecd") or of the standard filesystem's current directory ("scd") if no directory name is given or change explored partition's current directory or standard filesystem's current directory to the given one.
;----------
ecd
;----------
Displays name of current directory of explored partition.

;----------
scd system
;----------
Changes standard filesystem's current directory to "system" sub-directory.
[es]cp [-a|-i|-c|-d|-f|-k|-s|-p|-r|-v|-8.3|-asc|-lfn|-u16] <source path>+ <destination path>
Copy <source path> to <destination path>. "ecp" copies files from explored partition to standard filesystem and "scp" copies files from standard filesystem to explored partition. With "ecp" you can copy files from explored partition to itself with using the explored partition mount point.
In case name of only one file is given into <source path>, <destination path> can be name of a file (copy with renaming) or of a directory (copy to this directory). In case there is several <source paths>, or it contains wildcard characters or it is a directory name, <destination path> shall be a directory:
  • if it does not exist and there is only one <source path>, it is a copy with renaming,
  • if it does not exist and there is several <source paths> (or with wildcard characters), it is an error,
  • if it exists, <source path> is copied to this directory with keeping the same name.
Options are:
  • "-a": append <source path> content to content of <destination path> with creating it if it does not exist (cannot be used with "-r"),
  • "-i": ignore case in name to match <source path> names (default: depends on filesystem kind),
  • "-c": force case matching,
  • "-d": use modification date of source file as modification date of destination file instead of using current date,
  • "-f": force overwrite of destination files if they exist (default: asked to user),
  • "-k": do not overwrite destination files if they exist,
  • "-s": do not overwrite read-only destination files,
  • "-p": pause between each screen displaying,
  • "-r": recursive copy (default: not recursive) (ecp only),
  • "-v": display name of all copied files (default: do not display files name),
  • "-8.3": force not using long file names if explored partition supports them but not standard filesystem (default: asked to user) (ecp only),
  • "-asc": force not using file name with UTF-16 characters if explored partition supports them but not standard filesystem (default: asked to user) (ecp only),
  • "-lfn": disallow copy if explored partition supports long file names but not standard filesystem (ecp only),
  • "-u16": disallow copy if explored partitions supports file names with UTF-16 characters but not standard filesystem (ecp only).
;----------
ecp *.txt .
;----------
Copies all files with ".txt" extension to current directory of standard filesystem.

;----------
ecp a_file.ext 0:\
;----------
Copies "a_file.txt" file to root directory of explored partition (if this one is mounted as "0:").

;----------
scp to_explored_root.txt \
;----------
Copies "to_explored_root.txt" file to root directory of explored partition.
[es]dir [-on|-oe|-od|-os|+on|+oe|+od|+os|-tb|-tc|-td|-tf|-tl|-tp|-ts|-i|-c|-p|-s]* <path>*
Display list of files given into "<path>". "edir" lists files on explored partition and "sdir" lists files on standard filesystem. If no "<path> is provided, current directory is used. "<path>" can contain some wildcard characters. Options are:
  • "-on": sort output by name,
  • "-oe": sort output by extension,
  • "-od": sort output by modification date,
  • "-os": sort output by size,
  • "+on": sort output by name in reverse order,
  • "+oe": sort output by extension in reverse order,
  • "+od": sort output by modification date in reverse order,
  • "+os": sort output by size in reverse order,
  • "-tb": list only block devices,
  • "-tc": list only character devices,
  • "-td": list only directories,
  • "-tf": list only files,
  • "-tl": list only symbolic links,
  • "-tp": list only named pipes,
  • "-ts": list only sockets,
  • "-i": ignore case in file name matching (default: depends on filesystem kind),
  • "-c": force case in file name matching,
  • "-p": pause between each displayed page,
  • "-s": print only name of files with replacing spaces with "<20>" and tabulations with "<09>" and ignoring current and upper directories such as output can be used as argument when calling function or script.
When several "-o?" options are set, last one is used. If no "-o?" option is set, order is the one of storage in the directory. When several "-t?" options are set, output is a combination of each requested kind of files.
;----------
edir
;----------
Displays content of current directory on explored partition.

;----------
sdir -p -tf -td firstdir/* seconddir/*.txt
;----------
Displays all files and directories from "firstdir" and those ending by ".txt" in "seconddir".

;----------
set CURDIR_LIST<edir -s
;----------
Sets into "CURDIR_LIST" variable content of current directory with ensuring each whitespace separated word is the name of a file.
dispsize  
Update screen size program uses. If LINES or COLUMNS environment variables are defined, it uses them else it detects current screen size. This is useful with command having "-p" option to display output per page for this length to be correctly managed.
;----------
dispsize
;----------
Detects current screen size and use it.

;----------
set COLUMNS=100
set LINES=50
dispsize
;----------
Uses a screen size of 100 rows and 50 lines.
echo <expression>
Displays "<expression>".
;----------
echo %COLUMNS% %LINES%
;----------
Displays value of "COLUMNS" and "LINES" environment variables.
end [<end code>]
Ends current script and comes back to caller. If <end code> is not provided or is 0, script ends without error else it ends with an error (but error status treatment is not performed at its level but at its caller level). <end code> value cannot be retrieved by caller (only if it is equal to 0 or not).
;----------
end
;----------
Ends script without error.

;----------
end 1
;----------
Ends script with an error.
exit [<exit code>]
Exits program. If <exit code> is not provided or is 0, program ends without error else it ends with an error (but error status treatment is not performed).
;----------
exit
;----------
Exits program without error.

;----------
exit 1
;----------
Exits program with an error.
expr <expression>
Computes "<expression>" and displays result. An expression can be:
  • "+ <integer value>": displays "<integer value>",
  • "- <integer value>": displays negation of "<integer value>",
  • "not <integer value>": displays 0 if <integer value> is different from 0, 1 else,
  • "<integer value 1> +|-|*|/|mod <integer value 2>": displays sum, difference, multiplication, division, modulus of the two integer values,
  • "<string value 1> - <string value 2<": displays -1, 0 or 1 depending on if "<string value 1>" is before, equal or after "<string value 2>" when considering alphabetical order (ASCII comparison),
  • "<integer value 1> and <integer value 2>": displays 1 if both integer values are different from 0, 0 else,
  • "<integer value 1> or <integer value 2>": displays 0 if both integer values are 0, 1 else,
  • "<integer value 1> xor <integer value 2>": displays 0 if both integer values are 0 or both are different from 0, 1 else,
  • "<integer or string value 1> =|!=|>|>=|<|<= <integer or string value 2>": displays 1 if comparison is true, 0 else. If both values are integer ones, comparison is a numerical one, else it is a textual one.
If you want to perform operations with more than 2 values, you have to split it into several expressions with using intermediate variables.
;----------
expr 3 or 0
;----------
Displays 1.

;----------
expr 4 + 5
;----------
Displays 9.

;----------
expr aaa - bbb
;----------
Displays -1.

;----------
expr aaa < bbb
;----------
Displays 1.

;----------
set FIRST<expr 4 + 5
expr %FIRST% * 10
;----------
Displays 90.
fcall <function> <arguments>*
Calls the given function with the arguments. The function shall already have been defined into current script. <arguments> are a list of spaces or tabulations separated words. In case you want to have spaces or tabulations in an argument you have to replace them with <20> or <09> or use "asfilename" command on it (and use "asstring" inside function to decode it).
;----------
fcall a_function
;----------
Executes "a_function" function.

;----------
set DIR_CONTENT<edir -s
fcall treat_list %DIR_CONTENT%
;----------
Calls "treat_list" function with content of current directory with ensuring whitespaces are correctly managed on filename.
func <function name>
Defines a function named "<function name>". No function having this name shall have already been defined in current script. Function definition extends until the first "endfunc" instruction. It can contain any kind of command less definition of another function.
;----------
func print_hello
echo hello
endfunc
;----------
Defines a function that just displays "hello".
goto <label name>
Continues execution at label named "<label name>". If label has already been defined, execution continues from it else program waits for its definition. If script or function ends without this label to be defined, it is an error.
;----------
goto label
echo Not displayed
:label
;----------
Continues execution from "label" label and so "Not displayed" is not displayed.
help [<command>]
Displays a summary of all commands if no "<command>" is provided else displays "<command>" options.
;----------
help
;----------
Displays summary of all commands.

;----------
help if
;----------
Displays help of "if" command.
if [not] <condition> <command>
Execute the "<command>" if "<condition>" is true (or false if it is preceded by "not").
"<command>" can only be a single command different from label or function definition. If you want to perform several commands you have to use the "goto", "fcall", "scall" or "ecall" command.
"<condition>" can be:
  • "error": true if previous command ends with an error,
  • "defined <variable name>": true if variable "<variable name>" is defined (variable name shall not be surrounded with "%" because it is its name you want to test, not its value, unless the name of the variable you want to test is defined by another variable),
  • "[es]exist <filename>": true if "<filename>" exists and is any kind of file or directory,
  • "[es]file <filename>": true if "<filename>" exists and is an ordinary file,
  • "[es]dir <filename>": true if "<filename>" exists and is a directory,
  • "[es]link <filename>": true if "<filename>" exists and is a symbolic link,
  • "[es]socket <filename>": true if "<filename>" exists and is a socket,
  • "[es]pipe <filename>": true if "<filename>" exists and is a pipe,
  • "[es]block <filename>": true if "<filename>" exists and is a block device,
  • "[es]char <filename>": true if "<filename>" exists and is a character device,
  • "<expression>": true if "<expression>" is different from 0. "<expression>" can be any expression of "expr" command.
In conditions testing file existence, version starting with "e" is for files on explored partition and version starting with "s" is for files on standard filesystem.
If you want to perform complex conditions, you will have to split them on several "if" commands with using "goto" command.
;----------
if error exit
;----------
Exits program if previous command ends with an error.

;----------
if exist COLUMNS goto set_size
if not exist LINES goto do_not_set_size
:set_size
dispsize
:do_not_set_size
;----------
Force screen size update in case either COLUMNS or LINES variable is defined.
local <variable name>+
Define <variable name> variable as local: any change to this variable following this command will not be visible to function caller and any call to another function or script from this point in function will not get this variable.
;----------
func var_management
echo %A_VARIABLE%
set A_VARIABLE=set back to caller
local A_VARIABLE
set A_VARIABLE=no more modified for caller
fcall another_function
endfunc
;----------
This function displays value of "A_VARIABLE" variable then modifies it before declaring it as local. For caller of this function, variable "A_VARIABLE" will have "set back to caller" value when calls of this function ends. When this function calls "another_function", this one will not see the "A_VARIABLE" variable.
[es]mkdir <directory>
Creates <directory> directory on explored partition ("emkdir") or on standard filesystem ("smkdir").
;----------
emkdir a_subdir
;----------
Creates "a_subdir" directory in current directory of explored partition.
[es]more [-i|-c] <file>+
Display the given <file> with pausing between each screen display. In case several files are given, they are displayed one after the other. Filename can contain some wildcard characters in which case all matching files are displayed (order is directory order). Binary files are displayed in hexadecimal form. Options are used in case of wildcard match and are:
  • -i: ignore case in file matching,
  • -c: force case matching.
Default use of case matching depends on used filesystem type (no case matching on FAT and NTFS filesystems, with case matching on ext2/3/4 filesystems).
;----------
emore file1.txt file2.txt
;----------
Displays content of "file1.txt" and "file2.txt" files.
mount  
Mount a new partition under a drive number. Partition to mount is interactively asked.
;----------
mount
;----------
Starts request to mount a new partition.
emount  
Displays drive number under which explored partition is mounted.
;----------
emount
;----------
Displays "0:" (on DOS/Windows) or "//0" (on Linux) if no other partition was mounted before explored one.
smount  
List all available drives.
;----------
smount
;----------
Displays
C:
[...]
0:
[...]
on DOS/Windows or
/
[...]
//0
[...]
on Linux (the [...] parts being remaining list of drives).
onerror continue|end|exit|goto <label>|return
Defines the behaviour in case an error is encountered:
  • "continue": continues execution with following commands,
  • "end": ends the current script with an error,
  • "exit": ends the program with an error,
  • "goto <label>": go to the given <label> and continues execution from this point,
  • "return": ends the current function or script (if not inside a function) with an error.
More details are given in the error status description.
;----------
onerror end
;----------
Sets that the script shall be ended in case of error.
printcmd none|read|exec|both
Prints commands that will be executed or stop printing them:
  • "none": stop printing commands,
  • "read": print commands when they are read,
  • "exec": print commands when they are executed (after variables expansion),
  • "both": print commands when they are read and executed.
;----------
printcmd exec
[...]
printcmd none
;----------
Prints all commands present in "[...]" then stop printing them.
quit [<exit code>]
Exits program. If <exit code> is not provided or is 0, program ends without error else it ends with an error (but error status treatment is not performed).
;----------
quit
;----------
Exits program without error.

;----------
quit 1
;----------
Exits program with an error.
return [<exit code>]
Exits function or script if not inside a function. If <exit code> is not provided or is 0, function ends without error else it ends with an error (but error status treatment is not performed at its level but at caller's level).
;----------
return
;----------
Exits function without error.

;----------
return 1
;----------
Exits function with an error.
[es]rm [-i|-c|-f|-k|-p|-r|-v]* <file>+
Removes <file> files and directories on explored partition ("erm") or standard filesystem ("srm"). Name of files can have some wildcard characters. A directory can be removed only if it is empty unless the "-r" option is used. Options are the following:
  • "-i": ignore case in file name matching (default: depends on filesystem kind),
  • "-c": force case in file name matching,
  • "-f": force removing files (default: asked to user),
  • "-k": do not remove read-only files,
  • "-p": display per page,
  • "-r": recursively remove directories (default: not recursive) (erm only),
  • "-v": list all removed files (default: not listed).
;----------
erm -f *.tmp
;----------
Removes all files ending with ".tmp" on current directory of explored partition without requesting confirm.
set [<variable name>[[+]=<variable value>]|[[+]<<command>]]
Sets or displays value of an environment variable. If no <variable name> is given, it displays all variables value. If a <variable name> is given without value or command, it displays value of this variable. If <variable name> is followed by
  • "=<variable value>": it sets <variable value> to the variable,
  • "+=<variable value>": it appends <variable value> to current value of the variable,
  • "<<command>": <command> is executed and its output is set to the variable,
  • "+<<command>": <command> is executed and its output is appended to current value of the variable.
;----------
set A_VARIABLE=hello
set A_VARIABLE
;----------
Sets "hello" into "A_VARIABLE" then displays it.

;----------
set A_VARIABLE+<asstring <20>world
;----------
Executes "asstring <20>world" and appends its output (" world") to "A_VARIABLE" (using "asstring" instead of "echo" is to be able to get space at begin else it would have been discarded by "echo" command).

;----------
set A_VARIABLE+=!
;----------
Appends "!" to "A_VARIABLE" (so this one is now "hello world!").
shift [<shift number>]
Removes the first <shift number> script or function arguments and shift following ones accordingly. In case no <shift number> is given, it shifts one argument. In case <shift number> is bigger than number of arguments, all are shifted (so there is no more any argument). "@" and "#" variables are updated accordingly.
;----------
func shift_args
shift
echo %1%
shift 3
echo %1%
echo %@%
endfunc
;----------
If function "shift_args" is called with "one two three four five six", it displays "two", then "five" and "five six".
shiftvar <variable name> [<shift number>]
Split value of variable <variable name> into whitespace separated words, removes the first <shift number> ones with displaying them and sets remaining ones into value of <variable name>. If <shift number> is not given, first word is removed. In case <shift number> is bigger than number of words in value of <variable name>, all are displayed and variable is empty.
;----------
set A_VARIABLE=one two three four five
shiftvar A_VARIABLE 2
;----------
Displays "one two" and "A_VARIABLE" is "three four five".
[es]tofile <file>([[+]=<content>]|[[+]<<command>])
Writes <content> or output of <command> into <file>. In case <file> already exists, it is overwritten. If <content> is preceded with "+=" instead of "=" or <command> is preceded with "+< instead of "<", <content> or output of <command> is appended at end of <file> (if it does not exist, it is created).
;----------
etofile out.txt=hello
;----------
Writes "hello" into file "out.txt" of current directory on explored partition.

;----------
etofile out.txt+<asstring <20>world
;----------
Appends " world" at end of file "out.txt".
unset <variable name>
Remove definition of the variable <variable name>. Value of this variable is no more available and trying to use it generates an error.
;----------
unset A_VARIABLE
;----------
Remove definition of "A_VARIABLE".


20- Explore a backup

This is the part that is executed when you use -v option or select it when the program asks you.

This option allows you navigating into the content of backup files such as you can extract some files. It does not allow modifying file content.

Files that can be explored are all those containing either a disk (you have to select a partition), or the backup of a partition with a FAT12/16/32, NTFS or ext2/3/4 filesystem. If backup was made in several files, all files shall be readable at the same time. Files can be compressed or not.

Execution is the same as for chapter 19 but with the a) and b) steps replaced with ask and check of all backup files (similar to chapter 10).

Notes:


21- Change of boot partition

This is the part that is executed when you use the -g option or select it when the program asks you.

This option allows you to change the partition used to boot your computer. It can be needed in case you copied the content of your boot partition from one partition to another.

Execution allows choosing the disk where you want to update partitions table then partition you want to set as boot one. Execution follows the diagram below:


    Choice of disk where partitions table is
                     |
                     V
           Boot partition choice
                     |
                     V
                Confirmation
                     |
                     V
                    End
a) Choice of disk where partitions table is: 
You have to choose disk where you want to update partitions table to change boot partition. In most cases, it is first fixed disk unless you have some boot manager that allows changing boot disk.
In case chosen disk does not have any partition or does not use the MBR partitionning scheme, the program ends with an error message.
b) Boot partition choice: screenshot
This window gives you the list of main partitions on the chosen disk (only main partition can be boot one) and inform you of the current boot partition. You have to select the one you want to use as boot partition.
c) Confirmation: screenshot
The program asks for you confirmation of partitions table modification. You can have a specific message in case chosen partition is a main partition declaring extended ones, as it is not expected to have this kind of partition as boot one as it does not contain directly a filesystem.
Once you confirm the choice, program modifies the partitions table and ends.


22- Create files marking drive to use

This option allows creating marking files that can be used with "-fp", "-fd" or "-ff" options. These files are some standard empty files or files containing options (with same format than for options file) that are used by program to retrieve a partition on backup/restore. This is a workaround to the fact that drive name can be different depending on used OS (this means that the C:\ drive within DOS can be different from the C:\ drive within Windows). You have to provide a unique file name among all partitions (for a given directory) such as the partition where this file is can be identified.
Running of this option is done in three steps:

If program detects that partition where backup files are uses NTFS filesystem, it automatically creates some empty files (as into chapter 17) for them to be used. Number of files is computed depending on free size on source partition and of maximum size you provide with considering compression is used. If it finds that some files with the same name already exist, it will ask you to confirm before overwriting them.

Once these files have been created, you can use the program on another OS with following command line: "savepart -fp <name of first file> -ff <name of second file>. In both cases, name shall not contain a drive name ("marker.par" and not "C:\marker.par"). It will scan all partitions to find these two files and all drives for second file (in case it is on a CD). If it finds only one occurrence of each file, it asks you to confirm the found place (unless you used the "-fnc" option) then perform backup or restore depending on what you request to do. If it does not find one of the files or find one on more than one partition, it does nothing with asking you to fix this first.

Notes:


Example:
If you want to save your C:\ drive to files on the E:\ drive, you can create a "backup" directory on both of them (that avoids getting files in root directory), then launch savepart, choose to create marker files and give for first file "C:\backup\diskc.par" and for second file "E:\backup\diskc.fil" (for the maximum size, choose the one you want depending on what you will do with obtained files). Then you can boot back to DOS (or with a BartPE or Linux CD) and launch savepart with "savepart -fp backup\diskc.par -ff backup\diskc.fil". When you choose to "Save an element", program will scan disks for the given files and if it finds them, it will save the content of C:\ drive (that can have another name or do not appear in this OS) to E:\backup\diskc.f00, E:\backup\diskc.f01, ...
If you want to burn obtained files to a CD/DVD, you can copy all obtained files on root directory of CD with copying also the "diskc.fil" file on first CD (but on root directory also, not into a "backup" directory). Then with using this CD, you can launch "savepart -fp backup\diskc.par -ff diskc.fil" and program will use file on CD. If you had created a "backup" directory on CD with putting the "diskc.fil" in it, you would have launched "savepart -fp backup\diskc.par -ff backup\diskc.fil" but in this case program will complain that if finds two "backup\diskc.fil" markers (one on the E:\ drive, the other one on the CD).


23- Load an options or marker file

This option allows you to load an options file if you did not used the "-f" option on command line or a marking file if you did not used the "-fp", "-fd" or "-ff" option. Once this option has been used, you come back to the screen to select what you want to perform.

First window requests you what you want to load depending on which option you already provided (so if you used the "-f" option or already loaded the options file, this option will no more appear in list, but options to give marker files will still appear).
If you choose one of the marker file options, you can enter its name without its drive name (as "marker.par", not "c:\marker.par"). Program will not search it at once, but only when it needs it (so do not be surprised if it does not complain at once if it does not find it).
If you choose option to load options file, you can select it. You can see its content to check it with the "View file" button. When loading file through this option, following options are ignored:

as user interface was already initialised.
lang= option is ignored if this one was set from command line.
mount= options can be ignored if you mount some support to load options file and mount numbering does no more agree (in this case a message is displayed and files linked to this mount and following ones are ignored).
Less for these options, behaviour is the same as if you used the "-f" option on command line.


24- Options file contents

The options file allows you to restore (or save again) element you have saved. When using savepart with the -f <options file name> option, the various parameters are read from the file instead of being asked of you. Contents of this file can be partial (not covering all the options, in which case missing parameters will be asked), but in this case some rules described below must be followed.
The options file is a text file that allows options to be specified. Each option must be alone on a line.
If the line begins with ";", its a comment line (it is not analysed).
Option content can be defined with an environment variable. In that case, the environment variable must be given between % (example: file=%CONF%.PAR, %CONF% will be replaced by the content of the CONF environment variable). If the environment variable does not exist, an error will be generated. To be able to give the % character inside option contents, you have to double it (example: file=WITH%%.PAR, the file name would be WITH%.PAR).

Options have <option name>=<option value> format. Name and value of each option are the following:

Option Values Default value
mouse yes|no|poll yes
Choice of the method of using the mouse (same as -cm|-nm|-pm option on command line).
Please read command line option description to get more details.
check_drive yes|no yes
Verification that created/read file is not on saved/restored element is disabled when set to "no" (same as -ncd option on command line).
Please read command line option description to get more details.
verify_free_size yes|no yes
Verification of free remaining size on destination drive is not done when set to "no" (same as -ncs option on command line).
Please read command line option description to get more details.
verify_disk_write yes|no yes
Verification that sectors are correctly written is disabled when set to "no" (same as -nvd option on command line).
Please read command line option description to get more details.
verify_file_write yes|no yes
Verification that files are correctly written is disabled when set to "no" (same as -nvf option on command line).
Please read command line option description to get more details.
test_disk_size yes|no|<number> no
This option allows trying to detect disk size if it is set to "yes" (same as -tds option on command line).
Please read command line option description to get more details.
If a number is given, it is number of disk for which trying to detect disk size. In this case, this option can be given several times with different numbers.
lang en|fr|fr_2 automatic detection
Language choice (same as -l option on command line).
Please read command line option description to get more details.
utf8 yes|no automatic detection
Forces use or not use of UTF-8 terminal capability in Linux version.
user_interface console|text|text_bios|text_ext|text_bios_ext text
User interface choice (same as -cui|-tui|-bui|-tuix|-buix option on command line).
Please read command line option description to get more details.
no_crc yes|no no
Disable check of backup file checksum (same as -nocrc option on command line).
no_root yes|no no
Disable check if user has administrator's rights (same as -noroot option on command line).
hiber warn|exit|ignore warn
What to perform if an hibernated operating systems is found (same as -hiber option on command line).
disk <number> asked to user
Gives the disk number to use. This number must be between zero and the number of disks minus one. When saving, this option replaces the first window. When restoring, this option restricts the search of elements to be restored, to elements of the given disk (otherwise, the element is searched for on all the disks). When updating Windows 2000/XP/Vista/Seven registry or updating boot configuration data, this option replaces the choice of the second disk (the one that contains partition to update). When updating BOOTSECT.DOS/BOOTSECT.BAK files, this option replaces the choice of support where these files are.
This option cannot be given if "floppy", "device", "raw_file" or "new_raw_file" option is given.
floppy <number> asked to user
Gives the floppy drive number to use. This number must be between zero and number of floppy drives minus one. When saving, this option replaces the first window. When restoring, this option restricts the search of elements to be restored, to elements of the given floppy drive (otherwise, the element is searched for on all floppy drives). When updating BOOTSECT.DOS/BOOTSECT.BAK files, this option replaces the choice of support where these files are.
This option cannot be given if "disk", "device", "raw_file" or "new_raw_file" option is given.
device DOS/Windows: A-`
Linux: <block device>
asked to user
Gives the DOS/Windows device letter or Linux device file to use. When saving, this option replaces the first two windows. When restoring, this option restricts the search of elements to be restored, to elements of the given device (otherwise, element is searched for on all DOS devices). When updating BOOTSECT.DOS/BOOTSECT.BAK files, this option replaces the choice of support where these files are.
This option cannot be given if "disk", "floppy", "raw_file" or "new_raw_file" option is given.
raw_file <filename> asked to user
Gives name of raw file to use. When saving, this option replaces the two first windows. When restoring, this option reduces search for items to restore that correspond to saved one, to given file with expecting it to already exist for it to be updated. When updating BOOTSECT.DOS/BOOTSECT.BAK file, this option replaces search for support where these files are.
This option cannot be given if "disk", "floppy", "device" or "new_raw_file" option is given.
new_raw_file <filename> asked to user
Gives name of raw file to use. When saving, this option replaces the two first windows. When restoring, this option reduces search for items to restore that correspond to saved one, to given file with creating or overwriting it. When updating BOOTSECT.DOS/BOOTSECT.BAK file, this option replaces search for support where these files are.
This option cannot be given if "disk", "floppy", "device" or "raw_file" option is given.
main_part <number> asked to user
Gives the number of the main partition to use. This number must be between 1 and 4 for MBR partitions table, 1 and 4294967295 for GUID partitions table. If the element to save/restore is directly related to a disk, this option must not be given.
For this option to be used, "disk" or "raw_file" option must be given. For the case of "raw_file", if the file content is not a partitioned disk, this option will be silently ignored.
ext_part <number> asked to user if "main_part" not given, 0 else
Gives the number of the extended partition to use. This number must be between 1 and the number of extended partition corresponding to main partition. It can be used only in case of MBR partitions table.
For this option to be used, "main_part" option must be given. You do not have to give this option if you want to save a main partition.
The pair of options "main_part" and "ext_part" replaces the second window when saving, and the set "disk", "main_part" and "ext_part" replace the second window when restoring. When updating Windows 2000/XP/Vista/Seven registry or updating boot configuration data, "main_part" and "ext_part" replace the choice of the second partition (the one to update). When updating BOOTSECT.DOS/BOOTSECT.BAK files, these options replace the choice of partition where these files are.
only_if_same yes|no no
This option allows considering destination support as valid only if it is identical with saved support (when choosing destination support it has an "X" into "Idem" column). This allows avoiding error when using option file in case something was modified (as some partitions were added/removed since saving which modifies partition numbering).
def_level <number> asked to user if "file" not given, 0 else
Gives the compression level to use. This number must be between 0 and 9. When saving, this option replaces the third window. When restoring, this option is not used (hence can be omitted). If this option is not given and a file name is given (see "file" option below), compression level used is level 0 (no compression).
file <file name> asked to user
Gives the file to use to save/restore element. This option can be given several times in case saving/restoring need several files. In this case, options must be given in order you want files to be used.
max_size <number> [kB|MB] or max asked to user if "file" not given, 2047 MB else
Gives the maximum size that a file can be. If kB|MB is not given, size is in MB. If size is in kB, it must be between 1 and 9999 kB, if it is in MB it must be between 1 and 2047 MB. If "max" is used as value, the program will use minimum between drive free space and 2047 MB. This option can be given several times if saving/restoring needs several files. In this case this option must be given in the same order as file names are given. If this option is given less time than number of file names, the last option will be used for all remaining files. If this option is given more times than number of file names, remaining options will not be used. If this option is not given and some file names are given, maximum size of 2047 MB is used. When restoring this option is not used (hence can be omitted).
check_files_exist yes|no no
This option allows checking that all files needed to restore a backup exist. This avoids getting an error in the middle of the process in case a file is missing. This option cannot work in case files are on some removable media.
filesystem no|fat12|fat16|fat32|ext2|ntfs|MBR|firstsect|parttable|
fat12mem|fat16mem|fat32mem|ntfsmem|ext2mem|
fat12swap|fat16swap|fat32swap|ntfsswap|
fat12memswap|fat16memswap|fat32memswap|ntfsmemswap
asked to user if several choices are available ("no" else)
Gives the filesystem type to use when saving. If this parameter is equal to "no", all sectors are saved without considering filesystem that is on the partition. If this parameter is equal to one of the others possibilities, the program checks that partition to save corresponds to the filesystem of the asked type. If this is the case, only occupied sectors will be saved. Otherwise, an error is displayed.
The options fat12mem, fat16mem, fat32mem, ntfsmem and ext2mem allow saving only occupied sectors, while authorising that the backup file created can be on the saved partition.
The options fat12swap, fat16swap, fat32swap and ntfsswap allow saving only occupied sectors without saving the swap files contents.
The options fat12memswap, fat16memswap, fat32memswap and ntfsmemswap put together the features of both <xxx>mem and <xxx>swap options.
When restoring, this option is not used (the value defined inside the backup file is used).
swap_dir <path name> asked to user
This option allows giving the directory where swap files are located. It is used only when saving and when requesting to not save swap files. <path name> must be the path name from the partition root directory without a drive letter (example: "\" for root directory, "\WINDOWS" for WINDOWS directory). As with the window which requests this information, the program searches for swap files in the root directory also.
quit yes|no|nobadsector no
This option permits to exit program automatically. If it is equal to "yes", program exits at end of saving/restoring/copying (be aware that in the case of saving, if one of the options used from option file has been modified, the window asking if you want to create options file will still appear). It this option is equal to "nobadsector", program will exit only if no bad sectors have been found (otherwise, user can read errors list on screen, then click "Ok" button). If this option is equal to "no" or is not given, user has to click "Ok" button to exit.
reboot yes|no no
This option allows rebooting computer automatically at end of program execution. It is active only when saving or restoring a partition (copying does not take an option file and it is not useful to reboot computer in others cases). If the "quit" option is equal to "no", or "nobadsector" with some errors, or is not given, program will reboot only after the user has clicked on the "Ok" button. If the "quit" option is equal to "yes", or "nobadsector" without any errors, reboot will be done immediately.
automatic_naming yes|no asked to user if "file" not given, "no" else
This option allows using automatic naming. If no "file" option is given, this will only cause the automatic naming checkbox to be checked when asking for the first file name. If one or more "file" options are given, all these options will be first used and if more files are needed, the program will use the last file name, changing its extension with the file number following rules described in chapter 6.e (it does not verify whether the file already exists or not).
nb_files <number> asked to user
This option allows giving number of files to create when creating files on an NTFS drive with using automatic naming. Number must be between 1 and 1000.
windows_disk <number> asked to user
Gives the disk number where Windows is installed. This option is equivalent to the "disk" one but is used in the case of update of Windows 2000/XP/Vista/Seven registry to give disk number where Windows is installed (see chapter 11.a).
window_main_part <number> asked to user
Gives the main partition number where Windows is installed. This option is equivalent to the "main_part" one but is used in the case of update of Windows 2000/XP/Vista/Seven registry to give main partition number where Windows is installed (see chapter 11.b).
window_ext_part <number> asked to user if "window_main_part" not given, 0 else
Gives the extended partition number where Windows is installed. This option is equivalent to the "ext_part" one but is used in the case of update of Windows 2000/XP/Vista/Seven registry to give extended partition number where Windows is installed (see chapter 11.b).
windows_floppy <number> asked to user
Gives the floppy drive number where Windows is installed. This option is equivalent to the "floppy" one but is used in the case of update of Windows 2000/XP/Vista/Seven registry to give floppy drive number where Windows is installed (see chapter 11.a).
windows_device DOS/Windows: A-`
Linux: <block device>
asked to user
Gives the device letter/file where Windows is installed. This option is equivalent to the "device" one but is used in the case of update of Windows 2000/XP/Vista/Seven registry to give device where Windows is installed (see chapter 11.b).
windows_raw_file <filename> asked to user
Gives the file where Windows is installed. This option is equivalent to the "raw_file" one but is used in the case of update of Windows 2000/XP/Vista/Seven registry to give device where Windows is installed (see chapter 11.b).
window_dir <string> asked to user
Gives the directory where Windows is installed (see chapter 11.c).
part_letter A-` asked to user
Gives drive letter that should be modified in the registry for the chosen partition (see chapter 11.f).
boot_disk <number> asked to user
Gives the disk number where Windows Vista/Seven boot configuration data are. This option is equivalent to the "disk" one but is used in the case of update of Windows Vista/Seven boot configuration data to give disk number where these data are (see chapter 12.a).
boot_main_part <number> asked to user
Gives the main partition number where Windows Vista/Seven boot configuration data are. This option is equivalent to the "main_part" one but is used in the case of update of Windows Vista/Seven boot configuration data to give main partition number where these data are (see chapter 12.b).
boot_ext_part <number> asked to user if "boot_main_part" not given, 0 else
Gives the extended partition number where Windows Vista/Seven boot configuration data are. This option is equivalent to the "ext_part" one but is used in the case of update of Windows Vista/Seven boot configuration data to give extended partition number where these data are (see chapter 12.b).
boot_floppy <number> asked to user
Gives the floppy drive number where Windows Vista/Seven boot configuration data are. This option is equivalent to the "floppy" one but is used in the case of update of Windows Vista/Seven boot configuration data to give floppy number where these data are (see chapter 12.a).
boot_device DOS/Windows: A-`
Linux: <block device>
asked to user
Gives the device letter/file where Windows Vista/Seven boot configuration data are. This option is equivalent to the "device" one but is used in the case of update of Windows Vista/Seven boot configuration data to give device letter where these data are (see chapter 12.b).
boot_raw_file <filename> asked to user
Gives the image file where Windows Vista/Seven boot configuration data file is. This option is equivalent to the "raw_file" one but is used in the case of update of Windows Vista/Seven boot configuration data to give device letter where these data are (see chapter 12.b).
boot_BCD_file <string> \Boot\BCD or \EFI\Microsoft\Boot\BCD or asked to user
Gives the name of the file that contains Windows Vista/Seven boot configuration data (see chapter 12.c).
boot_entry <string> asked to user
Gives the name of boot entry to update when updating Windows Vista/Seven boot configuration data (see chapter 12.e).
source_disk <number> asked to user
Gives the disk number where element to copy is. This option is equivalent to the "disk" one but is used in case of copying an element to give source of copy (see chapter 8.a).
source_main_part <number> asked to user
Gives the main partition number to copy. This option is equivalent to the "main_part" one but is used in the case of copying an element to give source of copy (see chapter 8.b).
source_ext_part <number> asked to user if "source_main_part" not given, 0 else
Gives the extended partition number to copy. This option is equivalent to the "ext_part" one but is used in the case of copying an element to give source of copy (see chapter 8.b).
source_floppy <number> asked to user
Gives the floppy drive number to copy. This option is equivalent to the "floppy" one but is used in the case of copying an element to give source of copy (see chapter 8.a).
source_device DOS/Windows: A-`
Linux: <block device>
asked to user
Gives the device letter/file to copy. This option is equivalent to the "device" one but is used in the case of copying an element to give source of copy (see chapter 8.b).
source_raw_file <filename> asked to user
Gives the raw file to copy. This option is equivalent to the "raw_file" one but is used in the case of copying an element to give source of copy (see chapter 8.b).
dest_disk <number> asked to user
Gives the disk number where to copy element. This option is equivalent to the "disk" one but is used in case of copying an element to give destination of copy (see chapter 8.d).
dest_main_part <number> asked to user
Gives the main partition number that is destination of copy. This option is equivalent to the "main_part" one but is used in the case of copying an element to give destination of copy (see chapter 8.d).
dest_ext_part <number> asked to user if "dest_main_part" not given, 0 else
Gives the extended partition number that is destination of copy. This option is equivalent to the "ext_part" one but is used in the case of copying an element to give destination of copy (see chapter 8.d).
dest_floppy <number> asked to user
Gives the floppy drive number that is destination of copy. This option is equivalent to the "floppy" one but is used in the case of copying an element to give destination of copy (see chapter 8.d).
dest_device DOS/Windows: A-`
Linux: <block device>
asked to user
Gives the device letter/file that is destination of copy. This option is equivalent to the "device" one but is used in the case of copying an element to give destination of copy (see chapter 8.d).
dest_raw_file <filename> asked to user
Gives the raw file that is destination of copy. This option is equivalent to the "raw_file" one but is used in the case of copying an element to give destination of copy (see chapter 8.d).
dest_new_raw_file <filename> asked to user
Gives the raw file that is destination of copy. This option is equivalent to the "new_raw_file" one but is used in the case of copying an element to give destination of copy (see chapter 8.d).
mount <drive number>:<disk number>/<main partition number>,<extended partition number>
or
DOS/Windows: <drive number>:<device letter>
Linux: <drive number>:<block device>
asked to user
Allows defining mounting options of a partition or a device.
In first syntax, the first number is the drive number used to identify mounted partition, it must be between 0 and 2147483647. The second number is the disk number on which partition to mount is, it must be between 0 and number of disks - 1. The third number is the main partition number of partition to mount, it is between 1 and 4 for a MBR partitions table and between 1 and 4294967295 for a GUID partitions table. The last number must not be given for a main partition (if it is omitted, the colon before must be also) and is the extended partition number where the main partition is a logical partition, it must be between 1 and 255.
In second syntax, disk and partitions numbers are replaced with the drive letter/device file of the device to mount.
The drive number must be unique and a partition can only be mounted with one number. When a mount is defined, the "file" option can use this number to define a file name.
Example:
mount=0:0/1 mounts as 0: the first main partition of the first disk,
mount=10:3/2,2 mounts as 10: the second extended partition in the second main partition of the forth disk,
file=0:\DISK_C.PAR (or FILE=//O/DISK_C.PAR for Linux version) defines a file that is on the partition mounted by the first mount.
gmt <hours>h<minutes> automatic detection
This option permits setting difference between your hour and GMT hour (example: 1h00 in France in winter). It is used when writing file to NTFS partition because this one stores file modification time in GMT time. This option is not mandatory, it only avoids having some file modification time in future or past.
Automatic detection cannot be performed in DOS version, in this case 0 is used.
ask_first_media yes|no yes
When saving to a removable media, program asks for next support for each file even first one. With setting this option to "no", program will create the first file on current media without requesting anything.
max_mem_size <number> [kB|MB] available memory
This option allows reducing memory usage by program. It shall be used only when getting the "Error: could not allocate page table memory" error (mostly when exploring compressed backup). This limit is not absolute (program will use more memory than that in case of need), but allows reducing biggest buffers size. If you do not get the error, you do not need to use it, if you get the error, try with giving half the memory you have (reduce it or try to free some DOS memory if it is not enough).
empty_files yes|no no
When saving, this option allows program to empty the files it does not use in case "file" or "nb_files" (with automatic naming) are given. It does not request any confirmation before doing that and stop when all files are treated or at first error. This option allows knowing which files are used by saving and which are not.
heads_sectors default|standard|extended|parttable|<heads number>/<sectors number> asked to user unless "fix_first_sector" or "fix_disk_number" is used
When fixing physical definition of a disk on a boot sector, this option permits to choose which values to use. Three first options (standard|extended|parttable) are to use predefined values, the last option is to give your own values (the number of heads and the number of sectors per track). In case this option is not used and fix_first_sector or fix_disk_number option is used, program updates first sector or disk number value only.
In Windows and Linux versions, this option allows forcing number of heads and sectors per cylinder for a disk in case these definitions cannot be obtained with reading partitions table (that is the default behaviour). For this purpose numbers shall be given, not predefined values.
In order to have similar behaviour between DOS, Linux and Windows, setting the value to "parttable" in DOS version will lead to use values obtained from partitions table for disk with extended access.
This option allows also forcing the definition when using a raw file (default being to get them from partitions table).
cylinders default|parttable|[+]<cylinders number> retrieved from physical definition
This option is only to get similar definition between DOS, Windows and Linux versions. It is mostly needed in DOS version because the BIOS could simulate hidden cylinders that were needed with first disks for them to park the heads when disk is shutted down. It allows forcing a value to number of cylinders to workaround this kind of behaviour. If it is set to "parttable", value is obtained from the biggest cylinder value read in partitions table. If it is set to a number, value is set to given value. If the number is preceded with "+", the number is added to default number (thus it could be "+1" to unhide last cylinder).
This is used only for disks with extended access and raw files as number of cylinders is not important (this does not update disk size). For disk with standard access, you have to use the "test_disk_size" option instead such as program will check if it could access to the hidden cylinders instead of forcing it to a potentially wrong value.
fix_first_sector yes|no|<first sector number> asked to user unless "heads_sectors" or "fix_disk_number" is used
When fixing physical definition of a disk on a boot sector, setting this option to yes or a value permits to correct the first sector value if it is wrong. When it is set to yes, first sector value is deduced from partition's first sector else the given value is used. In case this option is not used and heads_sectors or fix_disk_number option is used, program updates heads/sectors or disk number only.
This option allows also forcing the definition when using a raw file that is considered as a device raw file.
fix_disk_number yes|no|<support number> asked to user unless "heads_sectors" or "fix_first_sector" is used
When fixing physical definition of a disk on a boot sector, setting this option to yes or a value permits to correct the support number value if it is wrong. When it is set to yes, support number value is deduced from kind of support (0 for removable, 128 for fixed) else the given value is used. In case this option is not used and fix_first_sector or heads_sectors option is used, program updates first sector or heads/sectors number only.
This option allows also forcing the definition when using a raw file that is considered as a device raw file.
stdaccess <number> detection of type of access
This option allows forcing use of standard access for disks that support both access modes (disks of less than 8 GB). The <number> allows giving disk number for which access mode shall be forced (see "disk" option). This option can be given several times with different disk numbers.
This option shall be carefully used and only in case of a disk found as using extended access but that does not support it (case of very old disks). Before using this option, it is better to check disks with partinfo.exe with and without "-s" option, then to try exploring a partition to check what program sees.
This situation is in most cases bad. It shows that disk is badly recognised and that can lead to some loss of data, overlapping partitions, ... (moreover in case of using disk with several OS). It can potentially be corrected with changing disk parameters into BIOS, but this can lead to the loss of all data of this disk (it is better after such a change to destroy all partitions and create them again to be sure they are correctly defined).
beep yes|no|<number> no
This option allows emitting two close beeps at regular time (10 or <number> seconds) during saving/restoring when it is set to "yes" or "<number>" (same as using the -beep option on command line). If your attention is requested a single beep is emitted (as when option is set to "no"). When saving/restoring ends 3 beeps (or 4 in case of problem) are emitted (warning: you still need to end program if you did not used the "quit=" option for it to flush data on disk).
log_file <file name> asked to user
Gives the name of file to use to store error messages. In case this option is not given, it is requested to user when it checks the corresponding option on backup file name request. You can read chapter 29 to get more details on this log file.
explore_script <filename> none
When exploring a partition or a backup, executes <filename> file at start of exploration as a script. All commands described into chapter 19.h are available. In case the script ends with the "exit", "quit" command or if the options file uses the "quit" option, program is ended at end of execution of script, else interactive exploration is started.

Remarks:

Examples:

With taking the partitioning presented in the example of saving a partition, and with assuming the backup of all sectors of the partition corresponding to D: drive, the obtained batch file will look like (assuming that two backup files are needed):

;-------------------------------
; Parameters for D: drive

; On the first disk
disk=0

; Main partition 1
main_part=1

; No compression
; (remark: in this case this option can be omitted)
def_level=0

; Files:
file=c:\driv_d_1.par
file=c:\driv_d_2.par

; Same size for all files
; (remark: in this case the second line can be omitted)
max_size=620
max_size=620

; All sectors are saved
filesystem=no

; End of file
;-------------------------------
If you name this file drive_d.cfg, you will have to enter "savepart -s -f drive_d.cfg" to save the partition or "savepart -r -f drive_d.cfg" to restore it. Your are not obliged to give the -s/-r flag in which case you will be asked what you want to do, and then the option file will be taken into account.

The file below will permit you to save/restore the Linux partition (all sectors of this partition):

;-----------------------------------
; Parameters for Linux partition

; On the first disk
disk=0

; Main partition number 3:
main_part=3

; Standard compression:
def_level=6

; File:
file=c:\linux.par
max_size=2047

; All sectors are saved
filesystem=no

; End of file
;-------------------------------
If you change filesystem parameter from "no" to "ext2" in above file, only occupied sectors of partition will be saved.

If you have two disks where the first one has a partition format that is not recognised by savepart, you can use the following file to force the program to only use the second hard drive:

;-------------------------------
; Partition format of the first disk not recognised
; => force using only the second one

disk=1

; End of file
;-------------------------------

To modify the registry automatically, you have to give all the options which define the element to be modified and the element where Windows is installed. As an example:

;-----------------------------------
; Modification of registry for logical partition on second disk while
; Windows is installed on the first partition of first disk.

; Parameters for Windows installation
windows_disk=0
windows_main_part=1
windows_dir=windows

; Parameters for partition definition to be modified in the registry
disk=1
main_part=2
ext_part=1
part_letter=G

; End of file
;-----------------------------------


25- Mounting a partitionscreenshot

Mounting a partition allows accessing partitions that cannot be used from OS. Instead of using a drive letter or mount point as for OS, mounted partitions get a drive number that can be used in the same way. As an example, to access DISK_C.PAR file that is on first mounted partition (that has the 0 number), you have to use "0:\DISK_C.PAR" (mount number followed with ":") for DOS and Windows versions or //0/DISK_C.PAR (two "/" followed by mount number) for Linux one.
Mounting process is similar to saving partition choice process: you have to first choose the disk where partition to mount is, then partition itself. Once this is done, and if filesystem on this partition is recognised, this partition gets a drive number that is unique. If you try to mount a partition several times, you always will get the number it was mounted under at first time.
Recognised filesystem are NTFS, FAT and ext2/3/4 filesystems. Mounting a NTFS partition allows modifying its files, but does not allow creating or erasing files. Mounting a FAT or ext2/3/4 partition allows creating files on them (not for ext2/3/4 partitions using binary tree sorted directories). Mounting a damaged partition allows accessing it in read-only mode. On ext2/3/4 partitions, symbolic links are displayed as files, but cannot be read or followed.
When you mount a partition to modify its files, you must let the program end by itself for it to be able to synchronise the filesystem with modifications you perform. For example, do not reboot immediately when saving has ended, but click on 'Ok' button, create (or not) the configuration file and wait for the program to end.

Notes:


26- Notes on what elements can be saved

This chapter describes some points specific to each type of element that can be saved. It describes in particular restrictions that are checked by program when restoring an element.

a) The complete disk: 
This is about saving/restoring the whole disk without taking into account its organisation.

When saving you should not create the backup file on one of the partition of the disk, else you are likely to have incoherence when restoring.

When restoring you should not use files that are on this disk as it is entirely rewritten and so files would be erased before they were completely read (so restoring will end with an error and files will be lost). Restoring is possible only on a disk with a compatible physical definition. For that, it must have the same access type, the same number of heads, of sector per track and have sectors that have the same size. It must equally have the same number or more cylinders (so the disk will have the same size or be bigger). If it has more cylinders, the last cylinders will be not allocated (consequently left empty) and you will have to create a new partition or increase the last one to use them when having MBR partitions table or increase the partitions table when having a GPT one (an easy way to fix the GPT partitions table is to restore the partitions table after having restored disk).

When using the "-tds" option, the disk size can be increased depending on size found through partitions table or in case of hidden cylinders. In case partitions table is of GPT type and appears smaller than disk size, disk size is lowered to match this size, such as disk appears to have same size whichever OS is used (a GUID partitions table is expected to occupy whole disk).

If disk size seems to be incorrect (for example it is displayed as 8 GB when the disk is 20 GB), you should not save this disk because the backup will not be complete (in this example, the last 12 GB will not be saved). This comes from a bad detection of the disk (for example in the way it is accessed). The use of a disk manager program may solve this problem.

b) The Master Boot Record (MBR): 
This sector is the first one on the disk. It contains: When saving it, this sector is fully saved, but when restoring only the part corresponding to the boot code is restored. The part corresponding to the partitions table is not modified else you would loose all partitions of disk.

When restoring, the only constraint on destination disk is that it must have the same sector size.

It can be useful to save the Master Boot Record to restore it on another disk or in case of a boot virus. This is the same as doing "fdisk /mbr" if you have a boot sector written by Windows 9x/Me. This also allows you to restore a boot loader in case you install an operating system that modifies the boot sector without notice.

Boot code is restored as-is, so if it contains some code specific to the disk format, this format is not updated even if this sector is restored on another disk.

You cannot save the MBR if it is not considered valid (in which case this choice will not be displayed).

c) First sectors of disk: 
These are the sectors that are before the first partition when using MBR partitions table (there is no such definition for GUID partitions table). This includes Master Boot Record, which is restored as described above (only boot code is restored).

When restoring, the destination disk must have the same sector size and have a valid partitions table. If the number of sectors before the first partition is not the same between the saved and restored disks, only the common part (the minimum number of sectors) will be restored.

You may need to save all sectors before first partition rather than just the MBR in the situation where you have a boot loader that uses these sectors to store its program. If this is restored onto a disk other than the original one or on a disk with different partitions, restored sectors will not be modified to take into account this new definition.

You will not see this option if MBR or partitions table is not valid.

d) Partitions table (MBR): 
These sectors describe the partitions table when it uses MBR formalism (4 main partitions and extended partitions). They include MBR and all sectors that describe extended partitions.

When saving, the sectors are fully saved but, when restoring, only the part corresponding to the partitions table and disk identifier are restored (so boot code is not modified). Constraints on the destination disk are the same as when saving/restoring whole disk.

When restoring partitions table, you will lose the whole contents of the disk, not because it is overwritten (only sectors of the partitions table are written), but because the way it is organised is modified. It is recommended that the backup file is not on the destination disk because there is a risk that it can be erased (it is a low risk because the file should be too big to be stored in memory and one of the sectors of the partitions table would be where the file is stored).

In case you restore the partitions table to a new disk (not the source one), it is better to avoid keeping both source and new disks in the same computer as they will have the same identifier (Windows will map drive letter to one of these disks, but perhaps not the one you want) or you have to modify the disk identifier of one of the two disks before starting Windows.

e) Partitions table (GPT): 
These sectors describe the partitions table when it uses the GPT (GUID Partitions Table) formalism (new representation that should be used with more than 2 TB disks). They include MBR (with the guard MBR partitions table) and all sectors that describe partitions and the copy of these sectors.

When saving, the sectors are fully saved and when restoring they are fully written. On contrary to MBR partitions table, restoration can be done on a disk that does not have the same physical definition (it should have the same sectors size and be at least of the same size).

When restoring partitions table, you will lose the whole contents of the disk, not because it is overwritten (only sectors of the partitions table are written), but because the way it is organised is modified. It is recommended that the backup file is not on the destination disk because there is a risk that it can be erased (it is a low risk because the file should be too big to be stored in memory and one of the sectors of the partitions table would be where the file is stored).

In case you restore the partitions table to a new disk (not the source one), it is better to avoid keeping both source and new disks in the same computer as they will have the same identifier (and their partitions also), so that could break EFI disk recognition or you have to modify the disk and partitions identifiers of one of the two disks.

f) Partitions (all sectors): 
In this case all sectors of a partition are saved without taking into account if they are occupied or not.

When saving be aware to not create backup file on saved partition (for same reasons as when saving whole disk). This is equally true when saving only occupied sectors except when choosing to save a partition on itself.

When restoring you should not use backup files that are on the restored partition (for same reasons as when restoring whole disk). This is equally true when restoring only occupied sectors. Restoring will be available only on a partition that is on a disk that has the same constraints as when restoring whole disk. Moreover partition must be on the same place on disk (it must begin and end at the same place as the saved one). Finally, partition type has to be compatible with type of saved partition. For this, here is the array giving compatibility between partition types:

Type
Number
Designation
FAT 12
0x01 DOS FAT-12
0x11 DOS FAT-12 hidden
0xc1 DR-DOS FAT-12
FAT 16
0x04 DOS FAT-16 < 32Mo
0x06 DOS FAT-16 >= 32Mo
0x14 FAT-16 < 32Mo hidden
0x16 DOS FAT-16 hidden
0xc4 DR-DOS FAT-16
0xc6 DR-DOS,NT
VFAT 16
0x0e Win95 VFAT-16
0x1e Win95 VFAT-16 hidden
FAT 32
0x0b Win95 FAT-32 (b)
0x0c Win95 FAT-32 (c)
0x1b Win95 FAT-32 hidden(b)
0x1c Win95 FAT-32 hidden(c)
NTFS
0x07 QNX,OS/2,NT,Unix
0x17 OS/2,NT hidden
ext2
0x83 Linux ext2fs/xiafs
So if you save a partition of type Win95 FAT32 (b), you can restore it on a Win95 FAT32 (c) partition (theoretically, difference between the 2 is hard disk access (CHS or extended), but Windows seems not to check partition type and check access type when booting). Please note that partition type is not modified in the partitions table (so if you restore a Win95 FAT32 (b) partition on a Win95 FAT32 (c) partition, this last one will still be a Win95 FAT32 (c) partition in the partitions table).

Saving all sectors of a partition can be useful in the case of a partition for which saving only occupied sectors is not available or in the case where the filesystem is too much damaged for saving only occupied sectors to work or if you do not have enough memory.

g) Partitions (only occupied sectors): 
This part describes how saving only occupied sectors works for partitions that are known by this program. The following will describe some specific things for each partition type (FAT, ext2fs, NTFS).

When saving/restoring occupied sectors of a partition, it is necessary to know how data are stored on it to know if a sector is occupied or not. For this reason, this option is not available for all filesystem, but only for those where I found documentation and that I have, to perform tests. For those filesystems, some checks are done to verify that it will be correctly recognised (if it is not, the window asking you if you want to save only occupied sectors will not be displayed).

Saving/restoring of occupied sectors allows saving space (backup file is smaller), to save time (less data are read) and to do restore on a partition with a different size or that is on a hard disk different from those where was source partition or at a different place. Further constraints are that disk must have the same sector size as the original one and partition types must be compatible. The partition also needs to respect some minimal and maximal sizes (they are described below for each filesystem type). Remarks on where created/read files are located are the same as for a partition where all sectors are saved.

Saving/restoring of occupied sectors keeps data sectors structure as it was defined when saving. If the partition is restored on a partition with a size different from original one, filesystem sectors can be modified to take into account this size change.

Example:
With a FAT partition, suppose there was the following structure (each letter is a sector with its content, number of sectors given is not representative of a true FAT structure):

  RRRRRRFFFF    R: reserved sectors (boot sector and others)
  FFFFDDDD..    F: FAT sectors (sectors that allow to know if clusters,
  DDDDDDDD..       that are groups of sectors, are occupied)
  ........DD    D: data sectors
  DDDDDDDDDD    .: empty sectors
  DD....DDDD

This partition is 60 sectors long. If you want to restore it on a partition that has 120 sectors, you will get following result:

  RRRRRRFFFF
  FFFFFFFFFF
  FFDDDD..DD
  DDDDDD....
  ......DDDD
  DDDDDDDDDD
  ....DDDD..
  ..........
  ..........
  ..........
  ..........
  ..........

The number of reserved sectors has not been modified, the number of FAT sectors has grown because there was more accessible data sectors. The number of data sectors has grown, but their organisation has not been modified (only empty sectors have been added at end).
In this example, it is not possible to restore this partition on a smaller partition because the last sector of partition is occupied. To avoid this problem you have to use a defragmenter before saving in order to get following structure:

  RRRRRRFFFF
  FFFFDDDDDD
  DDDDDDDDDD
  DDDDDDDDDD
  DDDD......
  ..........

In this case, the partition can be restored on a partition with 44 sectors (certainly less, as number of data sectors is reduced and so number of FAT sector will be reduced, and a partition with 42 sectors can certainly be used).

To know minimum and maximum partition size you can use when restoring a partition where only occupied sectors were saved, you can:

h) FAT (12, 16 and 32) partitions (DOS/Windows): 
All FAT12 and FAT16 partitions are recognised. FAT32 partitions are recognised only for version 0 of this filesystem (I did not know other version). FAT partitions group data sectors into groups called clusters. When restoring this type of partition, cluster size is not modified and FAT type is not modified.
Because of FAT structure, partitions of this type have to respect some size constraints that are summarised into following table:
Clusters size
512 B
1 kB
2 kB
4 kB
8 kB
16 kB
32 kB
Partition size
Min
Max
Min
Max
Min
Max
Min
Max
Min
Max
Min
Max
Min
Max
FAT12
2 kB 2 MB 4 kB 4 MB 8 kB 8 MB 16 kB 16 MB 32 kB 32 MB 64 kB 64 MB 128 kB 128 MB
FAT16
2 MB 32 MB 4 MB 64 MB 8 MB 128 MB 16 MB 256 MB 32 MB 512 MB 64 MB 1 GB 128 MB 2 GB
FAT32
32 MB 128 MB 64 MB 256 MB 128 MB 512 MB 256 MB 1 TB 512 MB 2 TB 1 TB 4 TB 2 TB 8 TB
So with this table, you see it is not possible to define a FAT16 partition with less than 16 MB and more than 256 MB if its cluster size is 4 kB. When restoring, only partitions that respect these constraints are listed as compatible partitions.

Remarks:

i) Ext2fs/ext3fs/ext4fs partitions (Linux): 
Ext2fs/ext3fs/ext4fs partitions that are recognised are 0 and 1 version.
Similar to FAT filesystem, ext2 filesystem groups data sectors into groups called blocks. As for FAT, block size cannot be modified when restoring a partition. Depending on this blocks size, you will have some size constraints.
These size constraints are for a different reason than for FAT partition. They define only a maximum partition size switch that size of the saved partition (there was no minimum size).
Block size
1 kB
2 kB
4 kB
Maximum partition size
256 MB 2 GB 16 GB
512 MB 4 GB 32 GB
1 GB 8 GB 64 GB
2 GB 16 GB 128 GB
4 GB 32 GB 256 GB
8 GB 64 GB 512 GB
16 GB 128 GB 1 TB
32 GB 256 GB 2 TB
64 GB 512 GB 4 TB
Note: depending on optional filesystem feature, this maximum size can be greater than the one given here.

For example, if you have a 3 GB partition with 2 kB blocks, you would not be permitted to restore it on a partition that has more than 4 GB (but you can restore it on a partition having a size between 0 and 4 GB, lower limit will be determined by the number of the last used block).

Remarks:

j) NTFS partitions:
NTFS partitions are recognised for versions 1.1, 1.2, 2, 3.0 and 3.1 (this number is not NT version but filesystem version (1.1, 1.2, 2 <=> NT, 3.0 <=> Windows 2000, 3.1 <=> Windows XP)). As Microsoft did never release a NTFS specification, this filesystem is not fully known and there still were some unknown parts. Nevertheless, parts concerning sector use is known and so can be used. But there was some feature of NTFS that I did not cover (it is the case of partitions that have heavily fragmented filesystem).
Unlike FAT and ext2 partitions, there was no size constraint: only size limit is linked to last allocated sector for lower limit and for upper limit to limit of filesystem or too much fragmentation. So it is not possible to give a size constraint as in others cases.

Remarks:

k) Boot sector/superblock:
This option appears only for partitions, floppy disks and devices for which filesystem is recognised. It allows saving first sector for the FAT and NTFS filesystems and the first 2048 bytes for the ext2, ext3 and ext4 filesystems (this is 4 sectors in most cases). In ext2/ext3/ext4 case, it means there is more sectors than superblock that are saved as there is also sectors before it.
When restoring, only partitions having the same physical definition are given (boot sector having information on its localisation). It shall be noticed that the boot sector/superblock copy (if it exists) is not updated on restoration.

l) Floppy disks:
360 kB, 720 kB, 1.2 MB, 1.44 MB and 2.88 MB floppy disks can be saved. But only floppy disks that are correctly formatted and have 512 bytes sectors can be saved.
Floppy disk size cannot be known (knowing its type 5"1/4 or 3"1/2 is possible, but for a given type, size cannot be known). So the program searches the last sector of the disk to get its size. If this last sector is damaged, the program will be wrong and the whole floppy disk will not be saved/ restored. In this case it is better to save using DOS devices. To find out which size the program has found, you can use the window asking you if you want to save all sectors or occupied ones only (if it is displayed) or remaining size when window asking you backup filename is displayed.
If you save all sectors, the same remarks as for saving a whole partition would apply, if you save only occupied sectors, refer to previous chapters referring to the filesystem.
If you restore a floppy disk for which you have saved only occupied sectors, onto a floppy disk with a different size, it will work. But this floppy disk will no longer have a standard format so it can cause mistakes with some programs.
After you have restored a floppy disk, you have to eject it then reinsert it so DOS can take changes into account. Otherwise, you can get incoherence on the disk.

m) DOS/Windows/Linux devices:
This method allows you to save all devices that OS accesses using sector notation and that have a filesystem known by OS (only FAT for DOS and FAT/NTFS for Windows NT/2000/...). For example, it is not the case for CD or network mapped drive, but it is the case for large removable disks like Zip. In Linux version, it relies on /etc/fstab file content to get a list of devices to use (with using only block devices declared in this file).
This obviously allows accessing partitions of hard disks or floppy disks, but for both cases it is better to use direct access as described in previous chapters. The only case where this is not true is in the case where the floppy disk size is incorrectly recognised.
Device to save/restore must be correctly formatted for it to be correctly recognised.
Same remarks as for saving floppy disks would apply in this case.
n) Raw files:
A raw file is a standard file that contains byte by byte image of a support (as obtained through "dd" program). Constraint of this file is that it shall have a size multiple of 512 bytes.
Program considers two kinds of raw file: A raw file is considered as a disk raw file when its size is not one of a floppy and its boot sector contains the MBR mark without being a valid NTFS or FAT boot sector. In all other cases, it is considered as a device raw file.
A raw file has no associated physical definition (there is no header to describe it), so program tries to deduce it from its content (from boot sector if it is a FAT or NTFS support), else it choose a default one. That means that a raw file will certainly not be considered as equivalent to the support it was generated from if this physical definition cannot be deduced. You can use the "heads_sectors" and "fix_first_sector" options in options file to force this physical definition.
A raw file is considered as a support, not as a backup file. That means that if you want to restore it directly on a support or if you want to create one from a support without using a backup file, you will have to choose option to "Copy an element". If you choose to "Save an element", you will create a Partition-Saving backup file from this raw file. If you choose to "Restore an element" and choose a raw file as destination, you will get a byte by byte copy of the original support (so as big as it was).


27- Differences between DOS and Windows versions

Because of differences between DOS and Windows, the two Partition-Saving versions are not exactly the same. Major differences are given here with taking DOS version as reference.

a) All versions of Windows:
Windows does not allow protecting a drive that is in use to avoid that several programs access it simultaneously. So these drives cannot be saved or restored from Windows. The most notable case is the system partition or partition with the swap file. If you want to save these partitions with the Windows version, you have to do it either from a second Windows installation, or from a WinPE or BartPE CD, or from Windows Vista/Seven recovery console.
If drive letter assignment on each partition seems wrong, do not use the program because it means it cannot disallow other programs to access the partition when saving/restoring (so data will be corrupted).
The whole disk, the partitions table and main partitions of extended type (the main ones, not logical inside them) can be saved/restored only from Windows XP version (previous versions cannot force OS to read partitions table again once this one has been modified).
Following options and corresponding ones into options file have described behaviour: Files created from Windows version can be used with DOS version (and vice-versa less in cases described into this chapter). But program can consider restoration destination is different from what was saved because physical definitions can be different (this can be a problem when saving all sectors as it needs to have the same physical definition). It shall be noticed also that in case of saving a NTFS device from Windows, this one can be restored in DOS, but device will become unavailable from DOS. Moreover restoring a NTFS device on a FAT device (or vice-versa) does there is an incoherence between partition type set into partitions table and filesystem (it is better either to avoid this type of handling or to fix the partition type into partitions table with program like XFDISK).

Note:
In case mouse seems to not work, it is because console is configured to use quick edit mode. You have to click on the window icon on top left, choose "Properties", "Edit options" tab and uncheck "Quick edit mode" (note: as it is translation from French version, menu and options name are certainly not exactly these ones but something similar).

b) Windows before Windows 95:
I do not think the Windows version can be executed on these Windows versions. But if it works, it is better you do not use it and you use the DOS version in DOS mode.
c) Windows 95/98/Me:
These versions of Windows do not allow direct access to disk. So you can only save floppy disk or devices. So it is better to use the DOS version in DOS mode.
d) Windows NT/2000/XP/Vista/...:
These versions of Windows allow accessing NTFS drives, so it is not needed to create backup files on NTFS partition before as it is the case for DOS version. But, in case you save a NTFS partition on itself, you will still need to create these files because they will be used with the mount mechanism instead of with Windows.
Partitions on Windows dynamic disks can be saved/restored with using Windows device access.
In these versions, you can need to have administrative rights to be able to perform backup.
e) Windows 64 bits:
The 32 or 64 bits version of Partition-Saving can be used on 64 bits Windows. In case you use the Windows DVD or rescue disk, you will have to use the 64 bits version of the program as 32 bits compatibility layer is not present on these disks.


28- Differences between DOS and Linux versions

Because of differences between DOS and Linux, the two Partition-Saving versions are not exactly the same. Major differences are given here with taking DOS version as reference.

a) All versions of Linux:
Linux does not allow protecting a drive that is in use to avoid that several programs access it simultaneously. So these drives cannot be saved or restored from Linux. The most notable case is the system partition. If you want to save this partition with the Linux version, you have to do it either from a second Linux installation, or from a live CD, or recovery console that is available on most installation CD.
Partitions on Linux dynamic disks can be saved/restored with using Linux device access.
You need to have root privileges to be able to have direct access to devices, so you have to launch program either with using root account or with using the "sudo" command. To check or explore backup files, this is not needed (any user can use these options).
Disk detection is done by searching some specific files into the "/dev" directory with using a predefined order. Because of this, disk numbering can be different from the one used into DOS (disk number 0 in DOS can have another number than 0 in Linux). Disk physical definition (number of heads, sectors per cylinders, ...) relies on partitions table definition as BIOS definitions are not available. If partitions table does not exist or is not valid, values given through "heads_sectors=" option of options file are used, else it is values returned by kernel or some default ones if these ones are invalid.

Device naming is different from DOS/Windows one: it is based on name of device file (as /dev/hda1). Program uses the "/etc/fstab" file to get a list of devices where to search. So in case a device does not appear into list you can add an entry into this file to force its detection (note that device file shall be a block device file).
As for device name, mount point name is not the same: it does not use a "<mount number>:" notation but "//<mount number>" one to know a mount shall be used instead of some local file.
Following options and corresponding ones into options file have described behaviour:

Files created from Linux version can be used with DOS version (and vice-versa less in cases described into this chapter). But program can consider restoration destination is different from what was saved because physical definitions can be different (this can be a problem when saving all sectors as it needs to have the same physical definition). It shall be noticed also that in case of saving a not FAT device from Linux, this one can be restored in DOS, but device will become unavailable from DOS. Moreover restoring a not FAT device on a FAT device (or vice-versa) does there is an incoherence between partition type set into partitions table and filesystem (it is better either to avoid this type of handling or to fix the partition type into partitions table with program like fdisk).
On contrary to backup files, options file created from Linux cannot be used from DOS (and vice-versa) because of file and devices naming differences. If you modify it to always use some file from current directory, you still shall take attention on disk numbering that can be different.
b) Secured versions of Linux:
On some very conservative Linux versions (known as SELinux), program can fail to launch because it is compressed. In this case you have to go to the UPX website (http://upx.sourceforge.net) to use this program to inflate binary (upx -d spartlnx.run -ospartlnx_unc.run) then launch obtained file.
c) Linux 64 bits:
The 32 or 64 bits version of Partition-Saving can be used on 64 bits Linux if both 32 and 64 bits libraries are installed. In case only 64 bits libraries are installed, you will have to use the 64 bits version of the program.


29- Log file

This file is created in case you request it either through dedicated option in options file or through checking corresponding option when the backup file is requested. This file will store all error messages displayed by program during its execution (there is no additional message less starting and ending messages).
The file begins with a "Start of execution on <date> at <time>." and ends with an "End of execution on <date> at <time>." if there was no error, "End of execution with error on <date> at <time>." if there was an error that prevents complete execution, "End of execution with warning on <date> at <time>." if there were errors that do not prevent complete execution (as bad sectors) or "Execution canceled by user on <date> at <time>." if user canceled execution. In case you do not get the end message, it means program ends abruptly, so with some error that could have been not logged (as if there is not enough memory).
There is no real need to use this log file in most cases. You should be aware that in case you have a damaged disk, it will store a lot of messages and so become very big (so it is better to create it on a drive where there is a lot of available space).


30- What is not supported

The following situations are not supported for this program:


31- What cannot be tested

The following situations cannot be tested:

If someone uses this program with one of above situations, I will be pleased to know the results and any problems encountered. For people wishing to make these tests, I want to say:


32- Acknowledgements


Hoping this program will be useful,

D. Guibouret <>

Back to homepage

All trademarks and registered trademarks are property of their respective holders.