How to Back Up OS2.INI

The OS2.INI file is kept open by the WPS at all times, so normal backup techniques cannot be used - the back up programs concerned will be denied access to the file as it is already open. One solution that we have found useful is to copy this file during the operating system boot before the Workplace Shell has started.

It is not sufficient to make only one copy; if you do that, and corrupt OS2.INI, the next time you boot the system your corrupted file will overwrite the backed up copy. It may even be that you do not know you have a problem until after the re-boot, by which time you will already have lost your backed up copy.

The solution to this is to make a series of generation backups of OS2.INI, by using XCOPY from within CONFIG.SYS and some COPYs from within STARTUP.CMD. Since these backup files are not used by the system they may be backed up to tape or another disk just like any other data files. Although the critical WPS data is held in OS2.INI, it is worth backing up OS2SYS.INI in the same way.

This is illustrated in Figure "Starting XCOPY From the First Line in CONFIG.SYS to Back Up the INI Files" and Figure "Building Back Up History of the INI Files from STARTUP.CMD".

This scheme keeps five versions of the INI files on disk, .OLD being the oldest. If something happens to an INI file you still have a chance of reverting to a previous version. The space occupied by the backups depends on the size of your INI files and the number of cascaded copies you make; from 500 KB to several MB of disk space can be used up. You must make your own judgement as to the number of generations to keep, based on the size of the files concerned and the available disk space.


[Back: Critical System Files]
[Next: Restoring a Backup Version of OS2.INI]