The official CD Boot/2 help page

The CD Boot/2 help page

CD Boot/2's AVIO version

Running CDBOOT.EXE allows you to configure and install CD Boot/2 from any OS/2 window or fullscreen, even from the OS/2 fullscreen you can obtain by booting OS/2 into a OS/2 fullscreen session via ALT+F1 (however, in that case the settings in CB2.INI will not be used, because access to INI files is only possible if PM is up and running).

Running CDBOOT.EXE usually looks like (where P: is a virtual diskette drive, that is a kind of RAM-Drive that is much faster to access than a real floppy disk):

CB20011I: Initializing CD Boot/2 environment ... CB20012I: Loading CD Boot/2 messagefile ... CD Boot/2 V2.00 (C) Roman Stangl (Roman_Stangl@at.ibm.com) 05, 2002 http://geocities.datacellar.net/SiliconValley/Pines/7885/ CB20013I: CD Boot/2 runs under the PM evironment ... CB20021I: Loading CD Boot/2 code DLL ... CB20098I: Initializing CD Boot/2 ... CB20080I: The drive(s) A, B, M, P seem to support removeable media on which the CD Boot/2 Boot Loader can be installed onto. CB20081Q: On which drive to you want to install CD Boot/2? P CB20082I: CD Boot/2 allows to define a period from 1 to 60 seconds in which pressing the keys 1 or 2 allows you to boot from another media than the default selection. CB20083Q: How many seconds should CD Boot/2 wait? 10 CB20084I: Reading the bootsector from the removeable media P:. CB20085I: Reading the CD2BOOT code from file H:\PROGRAMMING\CDBOOT2\SOURCE\CD2BOOT. CB20086W: The bootsector of the removeable media H:\PROGRAMMING\CDBOOT2\SOURCE\CD2BOOT was already modified by running CD Boot/2! CD Boot/2 will act accordingly. CB20089I: Writing the CD2BOOT code into file P:\CD2BOOT. CB20090I: Modifying the bootsector of the removeable media to load CD2BOOT instead of OS2BOOT. CB20091I: Writing the modified bootsector onto the removeable media P:. CB20099I: Waiting for CD Boot/2 to terminate ...

In above example, CD Boot/2 prompts you to enter the removeable media (at question CB20081Q) where CD Boot/2 should install its enhanced Boot Loader CD2BOOT onto and the Timeout Period (at message CB20083Q) after which boot continues from the default selection (customizeable via the commandline parameters /Harddisk, /Removeable and /BM).

Another example, running the commandline CDBOOT /Drive P /Timeout 10 might result in the following log:

CB20011I: Initializing CD Boot/2 environment ... CB20012I: Loading CD Boot/2 messagefile ... CD Boot/2 V2.00 (C) Roman Stangl (Roman_Stangl@at.ibm.com) 05, 2002 http://geocities.datacellar.net/SiliconValley/Pines/7885/ CB20013I: CD Boot/2 runs under the PM evironment ... CB20021I: Loading CD Boot/2 code DLL... CB20060I: Initializing CD Boot/2 ... CB20056I: Commandline parameters "/DRIVE p /TIMEOUT 10 /MSG? message /PASSWORD password" are valid and will be used. CB20084I: Reading the bootsector from the removeable media Q:. CB20085I: Reading the CD2BOOT code from file H:\CDBOOT2\SOURCE\CD2BOOT. CB20086W: The bootsector from the removeable media H:\CDBOOT2\SOURCE\CD2BOOT was already modified by running CD Boot/2! CD Boot/2 will act accordingly. CB20087I: Writing the CD2BOOT code into file Q:\CD2BOOT. CB20088I: Modifying the OS/2 bootsector to load CD2BOOT instead of OS2BOOT. CB20089I: Writing the modified bootsector onto the removeable media Q:. CB20061I: Waiting for CD Boot/2 to terminate ...

In this example, CD Boot/2 runs without any further manual intervention from the user. This can be useful if you want to run CD Boot/2 unattendedly.

If you want to run CD Boot/2 interactively, I suggest to use the PM version CDBOOTPM.EXE as it looks much better and allows user friendly fine tuning of all options.

CD Boot/2's PM version

There are mainly two ways to run CDBOOTPM.EXE:

  1. If you supply the commandline parameters /Drive d and /Timeout tt which are minimally required to run CD Boot/2 without any user intervention, just the Logo window is displayed where the progress is displayed.
  2. If you don't supply commandline parameters, CD Boot/2 will display the Logo window and finally on top of that the Configuration Dialog window.

Now let's take a look into the details. The first window is the Logo (or About) window, which shows the application your are running and the status messages (to display status and error messages).

While running the PM version of CD Boot/2, the Logo window contains a single multiline statustext that shows the last message CD Boot/2 considered important for you to know. When CD Boot/2 has finished execution, a Close pushbutton will be displayed, and the single multiline statustext changes to a multiline entryfield where you can scroll through all messages that were displayed while you had be running CD Boot/2.

More important is the CD Boot/2 Configuration Dialog window, which is the center where you control how CD Boot/2 will behave once installed onto a removeable media.

The dialog consists of the following main areas:

Above settings would display the following screen when booting from the removeable media and an active OS/2 Bootmanager was found on the first harddisk:

CD2BOOT - CD Boot/2 V2.00 Copyright (C) Roman Stangl (Roman_Stangl@at.ibm.com) 05, 2002 http://geocities.datacellar.net/SiliconValley/Pines/7885/ Welcome to the bootable installation CD-ROM for EasyRestore Copyright (C) Interactive Magic, 2002 Active OS/2 Bootmanager Partition found in partition table. Continuing booting from first harddisk ...

Above screen can also be optained when running CD Boot/2 with the option /Cid Sample.cid. This option requests CD Boot/2 to read options from a file named Sample.cid (which is shipped with CD Boot/2 as a sample) in addition (and with higher precedence) to the options specfied on the commandline. It may look like:

# # To request CD Boot/2 to read the options (commandline parameters) # from this file, just run: CDBoot/CDBootPM /Cid Sample.cid # /MSG1 "Welcome to the bootable installation CD-ROM for EasyRestore" /MSG3 Copyright (C) Interactive Magic, 2002 ; Additional parameters /Harddisk /Clear /BM /Password Aurora

As outlined before, CD Boot/2 will only work correctly when CD2BOOT has been written onto the removeable media without fragmentation. Fragmentation on a FAT drive occurs if the clusters (a cluster is the smallest unit FAT uses to access a file, a cluster is minimally 512 bytes - the sector size - and maximally 32kB) of a file reside not adjacent on a media. Due to space constraints of the boot sector - which as it name applies must fit completely into a 512 byte sized sector - it will only load the first cluster of a file it the file is fragmented, instead of the other clusters random data is loaded from the media.

You can certainly imagine that CD2BOOT will process incorrectly, fail or even hang when it hasn't been loaded correctly. To circumvent that (as it isn't easily visible to a user if a file is fragmented unless one is using filesystem tools), CD2BOOT checks itself for having been loaded correctly by the removeable media boot sector. Technically CDBOOT.EXE and CDBOOTPM.EXE will write a checksum into CD2BOOT after it has been customized, and CD2BOOT will recalculate that checksum upon invocation. If the recalculation of that checksum fails, CD2BOOT will halt the system with the following message:

CD2BOOT is fragmented - System stopped! Press ALT+CTRL+DEL to reboot!

To recover simply remove the removeable media and restart your PC. To get a working CD Boot/2 system you would have to defragment the removeable media you applied CD Boot/2 on.
I personally use the DEFRAG.EXE from my PC DOS 2000 partition (though it only works consistently when doing a full optimization) to defragment the VFDISK I run CD Boot/2 against before creating an image out of it.

CD Boot/2 errors

Beside the following error messages, a bootable OS/2 CD-ROM modified by CD Boot/2 might not work if the file CD2BOOT is not continuous, that is when it is fragmented. As the removeable media is formatted with a FAT filesystem you can use any FAT defragmenter to clean up that situtation. However, I've never experienced such a problem, so I think it is more a theoretical one.

The following error messages might be displayed during execution of the CD Boot/2 executables CDBOOT and CDBOOTPM:

Message
Explanation
CB20050I
CD20051I
CD Boot/2 could not understand the commandline you supplied and shows the supported options. Please spedify a valid commandline.
CB20052E CD Boot/2 detected that you specified the commandline option /DRIVE d, however the option is either incomplete (e.g. d is missing) or invalid (e.g. d is not a drive letter in the (case insensitive) range A to Z). Please correct that option.
CB20053E CD Boot/2 detected that you specified the commandline option /TIMEOUT tt, however the option is either incomplete (e.g. tt is missing) or invalid (e.g. tt is not numeric or not in the range of 1 to 60). Please correct that option.
CB20054E CD Boot/2 requires that you use the commandline options /DRIVE d and /TIMEOUT tt simultaneously, because only when both are supplied CD Boot/2 is able to run unattendedly. Please be sure you specify both options or none of them at all.
CB20055E CD Boot/2 requires that you do not use the commandline options /HARDDISK and /REMOVEABLE simultaneously, because only one can be specified. Please be sure you specify only one options or none of them at all.
CB20056I CD Boot/2 could successfully parse the commandline options /DRIVE d, /TIMEOUT tt, /MSG? message, /HARDDISK, /REMOVEABLE, /BM and /PASSWORD password you specified. Note, that does not mean that you specified all of the mentioned parameters, just that the ones you specified have been accepted. They will be used to run CD Boot/2 unattendedly
CB20057E CD Boot/2 detected that you specified one or more of the commandline options /MSG1 message, /MSG2 message and/or /MSG3 message, however at least one of those options has an excessive length (e.g. message is longer than the allowed number of 79 characters). Please correct that option.
CB20058E CD Boot/2 detected that you specified the commandline option /PASSWORD password, however the option either has an excessive length (e.g. password is longer than the allowed number of 7 characters) or contains invalid characters (e.g. one or more characters of password do not fall into the characterset 0...9, A...Z and a...z). Please correct that option.
CB20059E CD Boot/2 could get all information it needs to run unattendedly from the options you supplied.
CB20070E CD Boot/2 needs to display a PM window, however an anchor block could not be created. Please report this problem
CB20071E CD Boot/2 needs to display a PM window, however a message queue could not be created. Please report this problem
CB20072E CD Boot/2 needs to display a PM window, however the CD Boot/2 dialog window could not be created. Please report this problem
CB20073E CD Boot/2 failed to open the removeable drive (you specified for CD Boot/2 to modify), be sure that a medium is inserted into the drive.
CB20074E CD Boot/2 failed to lock the removeable drive (you specified for CD Boot/2 to modify), be sure that this drive is not in use by another program like e.g. FDISK or LVM. If the problem still persists after a report, please report this problem
CB20075E CD Boot/2 failed to read or write the boot sector of the removeable drive (you specified for CD Boot/2 to modify), be sure that the medium is accessible (e.g. by running VMDISK against it). If the problem still persists after a report, please report this problem
CB20076E CD Boot/2 failed to close the removeable drive (you specified for CD Boot/2 to modify), be sure that a medium is inserted into the drive.
CB20077E CD Boot/2 failed either to read the file CD2BOOT from the directory CD Boot/2 was installed into, or failed to write the file CD2BOOT onto the removeable drive (you specified for CD Boot/2 to modify). For reading, be sure that CD Boot/2 is installed correctly, for writing, be sure that a medium is inserted into the drive.
CB20078E CD Boot/2 detected that the contents of the file CD2BOOT in the directory CD Boot/2 was installed into did not match the expectations but seem to be currupted. Please reinstall CD Boot/2 and retry,
CB20079E CD Boot/2 detected that the boot sector of the removeable drive (you specified for CD Boot/2 to modify) does not look like a boot sector of a removeable FAT media. Be sure that you have inserted a OS/2 FAT formatted media containing the files required to be bootable (e.g. by running SYSINSTX d: against that drive)

If you haven't installed CD Boot/2 correctly (which is just uncompressing the archive you downloaded), other error messages might complain about missing files. In that case I would recommend to reinstall CD Boot/2 and if the problem persists to contact me.

CD Boot/2 return codes

CD Boot/2, that is both CDBOOT.EXE and CDBOOTPM.EXE, returns the following return codes to the calling program.

Return code
Explanation
0 CD Boot/2 returns 0 for a successful completion.
1 CD Boot/2 returns 1, if the specified parameter of a commandline option is syntactically invalid. Please ensure to correct the commandline.
2 CD Boot/2 returns 2, if the specified parameter of a commandline option or entered interactively was syntactically correct but semantically invalid (e.g. a drive letter of a drive that does not contain a removeable media). Please ensure that you specify a valid parameter.

Commandline options

CD Boot/2 uses library code (UStartup.?pp) that allows reuse of the code required to start up typical AVIO and PM C++ applications, resulting in shorter development cycles. Thus there are 2 types of commandline options:

  1. options that are handled by the library which means that you supply them on the commandline but usually you neither will be able to select them in the AVIO nor the PM version of CD Boot/2. These are the options /?, /Language ll and /Log [logfile],
  2. options that are handled by CD Boot/2 itself (and ignored by the library code). These options may also be written line by line into a file named cidfile and CD Boot/2 may be requested to read options from that file in advance to the commandline (thus also with higher precedence) by using the option /Cid cidfile.

For the commandline options that are handled by CD Boot/2 itself the following symbols are used for the table below:

  1. C (commandline) for options that can only specified on the commandline and can't be reconfigured by running CD Boot/2,
  2. D (default) for options that can be specified on the commandline and will override the defaults CD Boot/2 would use while not asking the user at all (usually used by the AVIO version CDBOOT.EXE, as it only prompt the user for the most important options) ,
  3. O (override) for options that can be specified on the commandline, but can be changed while running CD Boot/2 (usually used by the PM version CDBOOTPM.EXE, as that will just override the predefined values used in the Configuration Dialog initially),
  4. U (unattended) for options that will prevent CD Boot/2 to prompt the user at all, that is they will cause to run CD Boot/2 unattendedly,
dependent if you run the AVIO version CDBOOT.EXE or the PM version CDBOOTPM.EXE.

CD Boot/2 supports the following commandline options, other options specified on the commandline will be simply ignored:

Option
AVIO
PM
Feature
/?
-?
C
C
This option allows you to display the available commandline options of CD Boot/2. This option is handled by the library code.
/Language ll
-Language ll
C
C
This option allows you to specify the language CD Boot/2 uses other than the default or the one saved into CB2.INI from the last invocation of CD Boot/2. CD Boot/2 is NLS (National Language Support) enabled and ships in 2 languages, that is English (Us) and German (Gr). This option is handled by the library code. For example, if you want to display all texts in English you would launch CD Boot/2 with the command:

CDBoot /Language Us CDBootPM /Language Us As all NLS texts are contained in a file CB2xx.msg, it only makes sense to specify a ll when a CB2ll.msg exists, otherwise you will receive lots of error messages in English.

CD Boot/2 tries to use the language of the country you specified in your CONFIG.SYS, for example, I usually run the US version of OS/2 with German country settings, so CD Boot/2 will use German messages initially (that is, as long as you haven't overwritten it with the /Language option and saved it into the profile CB2.INI (Note! Only when PM (Presentation Manager) is up and running, that profile will used, e.g. when booting to an OS/2 fullscreen via ALT+F1 the profile can not be accessed).

As I can only provide the two mentioned languages, it is up to volunteers to translate CD Boot/2 into additional languages, any donations for that are welcome (please contact me if you're ready to offer your help, thanks)!

/Log [logfile]
-Log [logfile]
C
C
This option allows you to specify a logfile where all messages are logged into. If you omit the optional parameter logfile, the file CB2.LOG will be written into the directory CD Boot/2 was started from, otherwise logfile should be a fullly qualified filename. This option is handled by the library code.

The logfile can be used to debug problems or to log messages when running CD Boot/2 unattendedly. If the logfile can't be written, CD Boot/2 displays an error message but continues.

/Cid cidile]
-Cid cidfile
C
C
This option allows you to specify a cidfile, where CD Boot/2 will look for parameters in addition (and with higher precedence) than those specified on the commandline. However, the parameters /?, /Language ll and /Log [logfile] will only be recognized when specified at the commandline!

The cidfile can be used to avoid typing parameters on CD Boot/2's commandline for repetitive invokations of CD Boot/2. Or you can use it to store different configurations into different cidfiles.

CD Boot/2 processes the contents of a cidfile by looking for options, that is a line starting with the / or - character followed by a keyword and optional data. It will save and append each option found to the previous on, and after reading the cidfile completely it will also append the options specified directly on the commandline. Therefor, when looking for options then, the options in the cidfile will take precedence over the options specified on the commandline and the first match of an option will win!

A cidfile should conform the syntax:

  • the options are written line by line, that is, a single line should only contain a single option
  • an option contains a keyword, that is a supported keyword starting with the / or - character, followed by optional data
  • a line not starting with the keyword of a known option is treated as comment and will be ignored
  • You need to enclose the optional data between " in case the data contains the / or - characters, otherwise it is optional
  • the size of the file is restricted to less than 8kB
e.g. it may look like:

# # To request CD Boot/2 to read the options (commandline parameters) # from this file, just run: CDBoot/CDBootPM /Cid Sample.cid # /MSG1 "Welcome to the bootable installation CD-ROM for EasyRestore" /MSG3 Copyright (C) Interactive Magic, 2002 ; Additional parameters /Harddisk /Clear /BM /Password Aurora
/Drive d
-Drive d

/Timeout tt
-Timeout tt
U
U
The option /Drive d allows you to specify the drive letter you want CD Boot/2 to modify the boot process. Only the letters A to Z (or a to z) are valid for d.

The option /Timeout tt allows you to specify the Timeout Period you want CD Boot/2 to use in the modified boot process. Only one or two numeric characters together being in the range of 1 to 60 are valid for tt.

These options are only valid if specified simultaneously, as both are required to run CD Boot/2 unattendedly.

/HARDDISK
-HARDDISK

/REMOVEABLE
-REMOVEABLE
D
O
These options allow you to specify from where CD Boot/2 will boot by default, that is from which media CD Boot/2 will continue boot if the Timeout Period expires. As both options are conflicting, you may only specify one of them or none at all which causes CD Boot/2 to default to option /HARDDISK.

Usually you would leave the default option /HARDDISK, that is CD Boot/2 will continue booting from the first Harddisk after the Timeout Period expires, because that allows you to leave the media inserted in the drive without any need to care about it for normal boots (e.g. useful when the CD-ROM is just used for one-time installations).

However, if you intend to use the removeable media only when you really want to boot from it (e.g. for a diagnostics CD-ROM), you may select the option /REMOVEABLE instead, so that CD Boot/2 continues to boot from the removeable media when the Timeout Period expires.

/CLEAR
-CLEAR
D
O
This option allows you to specify that CD Boot/2 will clear the screen before it displays its menu (thus removing any messages BIOS may have left) and also immediately before booting from the selected media (thus removing the messages displayed by CD Boot/2 itself).

/BM
-BM
D
O
This option allows you to specify that CD Boot/2 will decide what to boot depending if an active OS/2 Bootmanager partition is found or not.

If no active OS/2 Bootmanager partitions is found, CD Boot/2 will display the menu allowing the user to expire the timeout to boot the default media (configured with the /HARDDISK or /REMOVEABLE options) or override the default selection.

If an active OS/2 Bootmanager partition is found, CD Boot/2 will also display the menu allowing the user to select between the removeable media or first harddisk within the timeout, but defaults to boot from the Harddisk regardless of what has been configured with the /HARDDISK or /REMOVEABLE options. Of course, the user can overrule that within the timeout period.

This option is useful to allow completely unattended installations. You would use the options /REMOVEABLE and /BM to advice CD Boot/2 to default booting from an removeable OS/2 installation media as long as installation is not finished by setting the OS/2 Bootmanager partition active on the first harddisk.
Note: This method of OS/2 installation does fit best, if you have a multiphase installer (in the sense that it can handle the required reboots, e.g. after partitioning, ... automatically) on e.g. CD-ROM that installs OS/2 not using the OS/2 installer directly, but copying OS/2 e.g. out of a ZIP files or drive image (in other words, if you install by "cloning" an existing installation archived in some way).

/Cpy1 message
-Cpy1 message
/Cpy2 message
-Cpy2 message
/Cpy3 message
-Cpy3 messsage
D
O
This option allows you to optionally specify up to 3 Copyright messages that will be displayed in the boot menu of CD Boot/2 when booting from the removeable media.

Each message can be up to 79 characters in size (otherwise it will be ignored), and you can specify any combination of them, however CD Boot/2's menu will display them sequentially without representing empty messages by empty lines. You could however specify an empty line by e.g. /CPY2 " ", that is not an empty line but a line containing a single space.

Note! This option will be ignored until you also supply an undocumented addtional option which I'm prepared to tell you, if you e-mail me your need.

/CpyColor c
-CpyColor c
D
O
This option allows you to specify the color c that CD2BOOT will use to display the Copyright messages.

The color c is specified in the range from 0 to 15 and correspond to the colors 0 to 15 BIOS uses when displaying characters. Invalid numbers specified do not result in an error but that a random color will be taken instead.

/Msg1 message
-Msg1 message
/Msg2 message
-Msg2 message
/Msg3 message
-Msg3 messsage
D
O
This option allows you to optionally specify up to 3 Userdefined messages that will be displayed in the boot menu of CD Boot/2 when booting from the removeable media.

Each message can be up to 79 characters in size (otherwise you'll get an eror message), and you can specify any combination of them, however CD Boot/2's menu will display them sequentially without representing empty messages by empty lines. You could however specify an empty line by e.g. /MSG2 " ", that is not an empty line but a line containing a single space.

/MsgColor m
-MsgColor m
D
O
This option allows you to specify the color m that CD2BOOT will use to display the Userdefined messages.

The color m is specified in the range from 0 to 15 and correspond to the colors 0 to 15 BIOS uses when displaying characters. Invalid numbers specified do not result in an error but that a random color will be taken instead.

/Password password
-Password password
D
O
This option allows you to optionally specify a password that has to be entered correctly in order for CD Boot/2 to boot from the removeable media. You can select to boot from the first harddisk without having to enter that password (as you could boot from the first harddisk by removing the removeable media anyway).

The password is case sensitive and can be up to 7 characters in size, where each character must be in the range of 0...9, A...Z and a...z. Please note that the password is not completely secure, but nevertheless certainly not trivial as it will be encrypted.

With that in mind, the following commandline is an example for running CD Boot/2 unattendedly while you still can set the options according to your preferences: cdboot[pm] /removeable /password OS2 /clear /msg1 "Welcome to the bootable ..." /msg3 "Copyright (C) ..." /msg2 "For new installations ..." /MsgColor 11 /drive p /timeout 15 /log

What's new

Changes between Version 2.00 and 1.60.

Changes between Version 1.60 and 1.50.

Special thanks to Rainer Feuerstein from IBM Enterprise Warp & WorkSpace Services in Germany for his constructive critics and suggestions and really intensive testing and usage. This CD Boot/2 version wouldn't have been enhanced to its current state without his motivation!

Changes between Version 1.50 and 1.40.

Changes between Version 1.40 and 1.30.

Changes between Version 1.30 and 1.20.

Changes between Version 1.20 and 1.10.

Changes between Version 1.10 and 1.00.

Version 1.00 was the first publicly available version.

CD Boot/2 download

You are welcome to download CD Boot/2 V2.00 (inclusive its source written with MASM 6.0 and VisualAge C++) from this site.

Building CD Boot/2 from its sources

You would need:

  1. Microsoft Macro Assembler 6.0 (or compatible)
  2. IBM VisualAge C++ V3 (or compatible)
  3. IBM Warp Toolkit V4.5 (or compatible)
Then just switch into the \SOURCE directory and run NMAKE for detailed instructions. Note, in contrast to what you will be able to do during the build process, I did run a utility to strip the debug infromation from the executables, so the executables you build will be larger than the ones I have shipped!

As the archive SOURCE.ZIE containing the source is encrypted, you need to run the command PROTECT cdboot2v200 Source.zie to get SOURCE.ZIP which you can then unzip as usual. (In case you wonder, that way anyone interested in the source needs to have installed OS/2 as I make the decryption program available for OS/2 but certainly not for Windows ;-).


(C) Roman Stangl (Roman_Stangl@at.ibm.com), 11.06.2001
Last update: 22.05.2002  1