The official CD Boot/2 home page
The CD Boot/2 home page
What is CD Boot/2
Welcome to the home of CD Boot/2, a utility to modify the boot sector
of a removeable FAT media so that either:
- the boot process continues to boot from the first harddisk instead of the
removeable media
or
- the boot process continues to boot from the removeable media if you press
the spacebar within a configurable period of time
That makes most sense when you want to prepare a singe bootable OS/2 installation CD-ROM
instead of the 2 CDs (one bootable CD-ROM that during the boot process has to be
replaced by a non bootable CD-ROM containing the OS/2 installation code) what IBM ships
with recent OS/2 versions (Aurora, Aurora and Merlin Convenience Pack).
Beginning with version 1.40 it should be possible to apply the same procedure on
FAT-based removeable media that were not written by OS/2 but e.g.
DOS.
I strongly recommend to read the documentation as there is no guarantee that it
will work, though according to my test it likely will (at least when 512-Byte
bootsectors are used).
With such a CD-ROM you only have to ensure that during the initial boot process you press
the spacebar to continue booting from the CD-ROM, for all subsequent reboots that are
required during OS/2 installation you can just keep the CD-ROM inserted in the drive.
A bootable OS/2 CD-ROM modified/created with CD Boot/2 will automatically continue booting
from the first harddisk (which is what the BIOS would do if no bootable CD-ROM had been
inserted into the CD-ROM drive), you no longer would have to care to remove and
reinsert the CD-ROM timely during the phases of the installation process.
Immediately after the boot process from the CD-ROM has begun, the following menu
might be displayed:
CD2BOOT - CD Boot/2 V2.00
Copyright (C) Roman Stangl (Roman_Stangl@at.ibm.com) 05, 2002
http://geocities.datacellar.net/SiliconValley/Pines/7885/
Please press the key for the media (> is default) you want to boot from:
>1 ... From the first harddisk
2 ... From the removeable media
Please select within 10 seconds, or boot continues from the default media!
That means that if you press the 2-Key within the next (in this example configured
to) 10 seconds (of course the countdown to 0 runs in real-time), the boot process
continues to boot from the removeable media (probably a CD-ROM), or if you let
that period expire or press the 1-Key, CD Boot/2 will continue to boot
from the first harddisk.
To boot from the selected media (first harddisk in above example) you can also use
the Enter-Key or to boot from the not selected media (removeable media
in this case) you can also use the Spacebar-Key, alternatively.
So to install OS/2 from a bootable OS/2 CD-ROM prepared with CD Boot/2 you would just
press the spacebar when the CD-ROM is booted to begin the OS/2 installation (possibly also for
the second reboot too if you haven't run LVM before), you then just keep the CD-ROM
inserted in the drive and let the period expire so that the first harddisk is booted.
However CD Boot/2 is very customizable, so for example you might be welcome'd
by a menu looking like:
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 (R) Version 1.10!
For new installations, press the 2-Key and enter your license password.
Copyright (C) Interactive Magic, 2002
Please press the key for the media (> is default) you want to boot from:
>1 ... From the first harddisk
2 ... From the removeable media
Please enter Password to boot removeable media:War_
Above screen was captured after the Spacebar was used to request CD Boot/2
to continue booting from the removeable media (one could have used
the 2-Key instead), and as the customized instructions (they are
just a sample, you can of course insert you own instead) show booting
from the removeable media requires to enter a password which has been
entered almost completely (just the last letter p is still missing at
the cursor postion).
Note! If you want to use CD Boot/2 in a CID (Configuration, Installation,
Distribution) environment where you want to run applications unattended, I recommend
using the AVIO version CDBOOT.EXE instead of the PM version
CDBOOTPM.EXE, because the first will not wait for any user input, whereas
the second version will display message boxes waiting for the user to click them
away in case of errors during execution.
It will also wait for the user to close the application.
However, both versions will set the return code appropriately.
This page concentrace on creating bootable OS/2 CD-ROMs, as this page is complex
enough the details of using CD Boot/2 have been
excluded here.
That page also allows you to download CD Boot/2 including its sources!
In order to get an idea what CD Boot/2 does under the covers you first need to know
how OS/2 boots from a removeable FAT media, a diskette drive being the most prominent
example.
The following things happen (using the same approach as in 1981 when IBM initially
released the first IBM PC):
- After you have powered on your PC or you have reset it via ALT+CTRL+DEL, BIOS
(Basic Input Output System) gains control running in Real-Mode (so everything
at this time happens within the first 640kB or memory) of Intel and
compatible processors.
- BIOS loads the absolutely first sector from the removeable media at the memory
location 0000:7C00 and checks if that sector is a valid boot sector (a valid boot sector, as a valid
partition table, ends with 0x55AA in the last 2 bytes).
- If a valid boot sector was found, BIOS transfers control to it by jumping to
0000:7C00.
A vaild boot may be created by DOS, OS/2, LINUX, WIN NT, W2K, ... but we concentrace
on OS/2 here.
- A OS/2 boot sector on a removeable media sets and checks a few things
and tries to load the FAT (File Allocation Table) into memory at 1000:0000.
Then the FAT is checked for the entry of the file "OS2BOOT " (and
that file is different between FAT and HPFS drives, but HPFS can't be
booted from removeable media anyway, so we can safely ignore that).
- If "OS2BOOT " can be found in the FAT, the boot sector code loads
the file "OS2BOOT " (the spaces are correct, as FAT has a 8+3 naming
convention and shorter names are stored with padding blanks in a FAT)
into memory at 0800:0000 and transfers control to it by jumping to 0800:0000.
The stack typically points to 0000:7B00 then.
If anything fails, then the famous OS/2 !! SYS02025 and OS/2 !! SYS02027
messages (which under DOS used to be Non-System disk or disk error. Replace and
press any key when ready) are displayed.
OS2BOOT must not be fragmented! CD2BOOT will display
CD2BOOT is fragmented - System stopped! Press ALT+CTRL+DEL to
reboot! when it detects being not written (by CDBOOT/CDBOOTPM) or loaded
(by BIOS) correctly.
In doubt I recommend you to run a defragmentation program.
The requirement that the boot sector can not load a fragmented file is an inherent
limitation, because the boot loader must fit into the 512 bytes of the boot sector
and there is not enough space to handle fragmentation.
- OS2BOOT (which on FAT is just a loader whereas on HPFS it is a
Micro HPFS-Filesystem driver and loader) then continues the boot process by
loading OS2LDR, the OS/2 loader which then loades OS2KRNL, the
OS/2 Kernel.
After you have run CD Boot/2 against a bootable removeable FAT media, the boot process
is enhanced with a few steps which of course do not cause any harm to any other
media.
The following things happen:
- Again, the starting point is in the BIOS running in Real-Mode.
- Again, the absolutely first sector from the removeable media is loaded
at the memory location 0000:7C00 and verified.
- Again, control is transferred to 0000:7C00 by BIOS.
- Again, the FAT is located and loaded into memory at 1000:0000.
Now however, instead of searching the FAT for the entry of the file
"OS2BOOT ", the boot sector code searches for entry of the file
"CD2BOOT ", which is a small file that CD Boot/2 has added to the
removeable media.
- If "CD2BOOT " can be found in the FAT, the boot sector code loads
"OS2BOOT " into memory at 0800:0000 and transfers control to it by jumping
to 0800:0000.
If anything fails, then the famous OS/2 !! SYS02025 and OS/2 !! SYS02027
messages are displayed.
- CD2BOOT which is the additional step added to the boot process by CD Boot/2
then displays its messages and waits the configured period of time for the user to
press the spacebar.
- Depending on the user selection, CD2BOOT does either:
- move the original OS/2 boot sector (the one that looks for "OS2BOOT ",
and which CD Boot/2 has copied into the file CD2BOOT)
to the memory location 0000:7C00 and transfers control to it by jumping to
0000:7C00.
Again, CD2BOOT must not be fragmented!
As CD2BOOT is larger than OS2BOOT it is more likely that it will be
fragmented, to be on the safe side just run a defragmentation program after CD Boot/2
has been run!
The media will not boot if CD2BOOT is fragmented!
CD2BOOT will display CD2BOOT is fragmented - System stopped!
Press ALT+CTRL+DEL to reboot! when it detects being not written
(by CDBOOT/CDBOOTPM) or loaded (by BIOS) correctly.
The original OS/2 boot sector code then continues to boot from the removeable media
as outlined above (by loading OS2BOOT and transfering control to it, which then
loads OS2LDR and finally OS2KRNL.
or
- load the partition table of the first harddisk at memory location 0000:7C00 and
transfers control to it by jumping to 0000:7C00.
Note, if no removeable media had been inserted into the drive, BIOS would have started
to load the partition table of the first harddisk.
Thus, with CD Boot/2 the effect as if having no bootable removeable media inserted can
be achieved while still having inserted a bootable removeable media!
So, CD Boot/2 does nothing more than adding a small step that allows the user to
select how the early steps in the boot process (before the OS itself gains control)
performed.
First, how do you run CD Boot/2 against a FAT-based removeable media (e.g.
written by DOS):
- You can run CD Boot/2 against a removeable media that has been FAT-formatted
by an operating system other than OS/2 as you would if the media had been
formatted by OS/2.
- However, you can run CD Boot/2 only once against that media, that is, if
you need to rerun CD Boot/2 against it, you have to format it with
the operating system before.
Otherwise you won't destroy that media, but it will not boot (due to the
limitations on how the boot process is modified to be partly based on OS/2).
- If you have run CD Boot/2 against that FAT-base removeable media,
you will receive the famous OS/2 !! SYS01475 and OS/2 !! SYS02027
messages instead of the usual e.g. DOS messages you might know:
Non-System disk or disk error and Replace and press any key when ready.
Second, what does CD Boot/2 differently for a FAT-base removeable media like
e.g. written by DOS compared to an OS/2 formatted media:
- If CD Boot/2 detects that the removeable media is FAT-based, but not formatted
with OS/2, it will replace the bootsector by a modified OS/2 bootsector.
It will also patch the original bootsector found on the removeable media into
CD2BOOT, and will write that file onto the removeable media.
And that logic causes the limitation that you can run CD Boot/2 only once against
a non-OS/2 formatted removeable media.
If you would run it a second time, CD2BOOT will be patched by the
modified OS/2 bootsector that CD2BOOT has installed in the previous
run as the bootsector, instead of the orginial non-OS/2 (e.g. DOS) bootsector.
- When that modified OS/2 bootsector gains control, it will load the
CD2BOOT modified in above step from the removeable media and passes
control to it.
- The code within CD2BOOT will then display the same boot menu as
you already know from OS/2, giving you the choice to continue booting from
the removeable media (if you press the Spacebar before the timeout period
expires) or continues booting from the first harddisk.
- If you chose to continue booting from the removeable media, the code
within CD2BOOT will load the original non-OS/2 FAT-based bootsector
and passes control to it.
It is then up to that bootsector code what will happen further, e.g. for
DOS it will start booting DOS.
And third, some suggestions on where you might want to run CD Boot/2
against a non-OS/2 formatted FAT-based removeable media:
- You want to create a bootable DOS CD-ROM which you use to install DOS or
to backup/restore partitions with tools like Partition Magic or Norton Ghost
from a bootable DOS CD-ROM.
- You may want to create a bootable WINxx CD-ROM (it is quite possible
to create a bootable CD-ROM where you use the bootable WINxx installation
diskette as the bootimage for a CD-ROM, and to avoid swapping the CD-ROM
during each reboot in the installation process, you might want to
modify that diskette (hopefully a copy of it!) with CD Boot/2 previously).
- You want to make a bootable CD-ROM booting from an updated Linux boot
diskette (AFAIK RedHat bootable diskettes are FAT-based, so modifying them
with CD Boot/2 should work).
CD Boot/2 will tell you if it detects a non-OS/2 written bootsector.
If it then detects that this bootsector is FAT-based (e.g. written by DOS
or Linux in VFAT format) it will issue an informational message that
it this will likely work.
However, if it then detect that the bootsector is not FAT-base, it will
issue a warning message that this will likely not work, but still does
continue to modify it.
Preparing a diskette to create bootable OS/2 CD-ROMs
A bootable CD-ROM, and for OS/2 this is no exception, the El Torito specification is
used.
As you can easily find more details on the Internet, here just the principle in short.
During creation of a bootable CD-ROM, you have to specify the image of a diskette
which the BIOS (and thus is only available as long a BIOS services are used)
of a PC capable of booting from CD-ROMs then uses as a logical replacement
of the physical diskette drive A: (in other words, all BIOS accesses to the diskette
drive A: are rerouted into that diskette image).
Thus, if that image is a bootable diskette, the CD-ROM BIOS replaces the diskette
drive A: with the contents of that image as long BIOS is used in the boot process
(e.g. if you create a bootable DOS CD-ROM, you will access that diskette image when
doing a DIR A: as DOS is just a small add-on to BIOS, if you create a bootable
OS/2 CD-ROM you need a special driver so that that diskette image is still used when
BIOS services are no longer available, and the OS/2 drivers CD_BOOT.FLT
supplied by IBM or DANIBOOT.FLT supplied by Daniela Engert are
such a driver)..
In other words, to create a bootable CD-ROM you have not much more to do than to
create a bootable diskette, create an image out of it and specify that image during
CD-ROM creation.
Usually, that image can be easily achived by imaging a 1.44MB diskette, however
as the files required to boot OS/2 do not fit on a single 1.44MB diskette you
have to use a 2.88MB diskette to boot OS/2 instead.
Creating a bootable DOS CD-ROM, a 1.44MB diskette is quite enough, and that is also
a good starting point if you haven't created a bootable CD-ROM (on a CD-R or
CD-RW media) anyway.
Luckily, even as 2.88MB diskette drives didn't became standard, you can use
a virtual drive under OS/2 instead, like e.g. from the IBM EWS Package
VFDisk.
To create a logical 2.88MB diskette drive, you would have to add
DEVICE=d:\OS2\BOOT\VFDISK.SYS 4 into your CONFIG.SYS.
You can use the IBM EWS
SAVEDSKF
and/or LOADDSKF
to fill that virtual diskette
drive from an image or to create an image out of the virtual diskette drive.
Under OS/2 you have another way to test if your virtual diskette is really
bootable by creating an Image File of a DOS Startup Diskette with
VMDISK, which is part of OS/2 to boot special DOS versions (of course
a bootable OS/2 diskette image will finally fail somewhere while loading OS2LDR
or OS2KRNL as OS/2 isn't really a DOS, but all steps of the boot
process, including the modifications done by CD Boot/2, mentioned above can
be tested that way!).
Just use the command VMDISK x: d:\CD2Boot.Img to build an Image File
of a DOS Startup Diskette out of the virtual 2.88MB diskette drive x:
and then start it with DOS from Drive A: which you can find in OS/2's
Command Prompts folder.
Alternatively you may test is in a virtual machine such as
VirtualPC or under Linux or Windows with
VMWare (though it does not support a OS/2 guest,
so booting a bootable OS/2 media will finally fail. They once had a beta
supporting a guest OS/2 operating system, but that never went into a product,
probably due to some pressure from MS as VMWare seems to have close relations
to them.
You can still use it to test the first steps of e.g. a bootable OS/2 CD-ROM,
and while you can download the program from VMWare
itself, you can find the necessary cracks
(for their non OS/2 support revenge is sweet, that's why I mention the
crack though generally I suggest you buy the programs you find useful and are
using more frequently than just for test purposes, especially to support the
remaining OS/2 vendors!).
Using CD Boot/2 to create/modify a bootable OS/2 diskette for a bootable
OS/2 CD-ROM
As said above, a bootable OS/2 diskette requires the use of a 2.88MB diskette,
which may be a virtual drive in case you lack of a physical 2.88MB diskette
drive (which would be very slow anyway compared to a RAM disk).
In principle, there are 2 ways how you can get to a bootable 2.88MB OS/2
diskette (the original one in the configuration IBM ships with bootable
OS/2 CD-ROMs):
- If you own Aurora or the Aurora/Merlin Convenience Pack (ACP/MCP) then you
have received (beside others) 2 CD-ROMs to install OS/2 from, a bootable OS/2
CD-ROM which after loading the OS/2 Kernel and drivers prompts you to replace it by a
non bootable OS/2 CD-ROM containing the OS/2 installation code.
On those CDs you can find the image of the 2.88MB diskette that is used to
boot from CD-ROM.
Usually you can find it in the directory \BOOTIMGS, so to extract
the image onto a (physical or virtual) bootable 2.88MB diskette, you could run
LOADDSKF Disk_0_1.Img x: /y where x: is the (physical or
virtual) diskette drive.
or
- You can create that bootable 2.88MB diskette x: yourself too.
You would have to:
- ensure that you can write onto that 2.88MB medium, e.g. by running
FORMAT x: against it
- ensure that it is a booteable OS/2 media by running the command
\OS2\INSTALL\BOOTDISK\SYSINSTX x: against it
- Copy the contents of the OS/2 Installation diskette onto that media
by running XCOPY A:\* x:\ /h/o/t/s/e/r/v (you can ignoring the warnings
about some files that can't be copied, because they are part of the EA (Extended
Attributes) support on FAT filesystems)
- Copy the contents of the OS/2 Warp Diskette 1 diskette onto that media
using the same instructions as in the last step
- rename OS2KRNLI (with that name the OS/2 Kernel prompts you
to insert diskette 1 which doesn't really make sense for
bootable CD-ROMs) to OS2KRNL
- copy the driver CD_BOOT.FLT (can by found either in the diskette images
that are used for the bootable OS/2 CD-ROMs IBM shipped or in the
CDBOOT
package) onto that diskette and modify its parameter /D:n, where n
corresponds to the number of 1.44MB medias required to boot (a 2.88MB
media counts as 2 1.44MB medias).
Alternatively you may use Daniela Engert's DANIBOOT.FLT driver, which you
should easily find on Hobbes.
- modify the CONFIG.SYS so that it works for a bootable OS/2 CD-ROM:
Bootable Diskette image |
Bootable CD-ROM |
buffers=32
iopl=yes
memman=swap,delayswap
protshell=sysinst1.exe
set os2_shell=cmd.exe
diskcache=D2,LW
protectonly=yes
libpath=.;\;\os2\dll;\os2\install;
ifs=jfs.ifs
ifs=hpfs.ifs /c:64
pauseonerror=no
codepage=850
devinfo=kbd,us,keyboard.dcp
devinfo=scr,ega,vtbl850.dcp
device=\dos.sys
device=\mouse.sys
set path=\;\os2;\os2\system;\os2\install
set dpath=\;\os2;\os2\system;\os2\install
set keys=on
basedev=ibmkbd.sys
basedev=i2oxport.sys
basedev=i2ososm.add
basedev=ibm1flpy.add
basedev=ibm1s506.add
basedev=ibm2flpy.add
basedev=ibm2scsi.add
basedev=dac960.add
basedev=ipsraid.add
basedev=ibmint13.i13
basedev=os2dasd.dmd
basedev=os2lvm.dmd
device=\testcfg.sys
basedev=aha152x.add
basedev=aha154x.add
basedev=aha164x.add
basedev=aha174x.add
basedev=aic7770.add
basedev=aic7870.add
basedev=aic78u2.add
basedev=dpt20xx.add
basedev=flashpt.add
basedev=ql10os2.add
basedev=ql40os2.add
basedev=ql510.add
basedev=ibmatapi.flt
basedev=ibmidecd.flt
basedev=xdfloppy.flt
set os2_shell=cdinst.exe
set saveconnect=1
set cdrominst=1
ifs=cdfs.ifs /q
device=\os2cdrom.dmd
device=\refpart.sys
set os2_shell=cdboot.exe
set oemprogram=\ibminst\npconfig.exe
set exitwhendone=1
|
buffers=32
iopl=yes
memman=swap,delayswap
protshell=sysinst1.exe
set os2_shell=cmd.exe
diskcache=D2,LW
protectonly=yes
libpath=.;\;\os2\dll;\os2\install;
ifs=jfs.ifs
ifs=hpfs.ifs /c:64
pauseonerror=no
codepage=850
devinfo=kbd,us,keyboard.dcp
devinfo=scr,ega,vtbl850.dcp
device=\dos.sys
device=\mouse.sys
set path=\;\os2;\os2\system;\os2\install
set dpath=\;\os2;\os2\system;\os2\install
set keys=on
basedev=ibmkbd.sys
basedev=i2oxport.sys
basedev=i2ososm.add
basedev=ibm1flpy.add /A:0 /FORCE:1 /U:0 /F:2.88MB
basedev=ibm1s506.add
basedev=ibm2flpy.add
basedev=ibm2scsi.add
basedev=dac960.add
basedev=ipsraid.add
basedev=ibmint13.i13
basedev=os2dasd.dmd
basedev=os2lvm.dmd
device=\testcfg.sys
basedev=aha152x.add
basedev=aha154x.add
basedev=aha164x.add
basedev=aha174x.add
basedev=aic7770.add
basedev=aic7870.add
basedev=aic78u2.add
basedev=dpt20xx.add
basedev=flashpt.add
basedev=ql10os2.add
basedev=ql40os2.add
basedev=ql510.add
basedev=ibmatapi.flt
basedev=ibmidecd.flt
basedev=cd_boot.flt /D:3
set os2_shell=cdinst.exe
set saveconnect=1
set cdrominst=1
ifs=cdfs.ifs /q
device=\os2cdrom.dmd
device=\refpart.sys
set os2_shell=cdboot.exe
set oemprogram=\ibminst\npconfig.exe
set exitwhendone=1
set bootedfromcd=yes
|
(There are only minimal differences at the IBM1FLPY.ADD driver, the replacement of
BASEDEV=XDFLOPPY.FLT with BASEDEV=CD_BOOT.FLT /D:3 and the addition
of SET BOOTEDFROMCD=YES, just be sure that you keep the correct sequence of the
drivers!).
and
- Be sure that the media is not fragmented!
If you doubt run a defragmentation program, preferably an OS/2 one that can
handle extended attributes (though I doubt that a bootable OS/2 diskette needs
extended attributes, so even a DOS defragmentation program should be sufficient)!
Now you have a bootable 2.88MB OS/2 diskette which now needs to be modified to change
the boot sequence from How OS/2 boots to
How OS/2 boots after CD Boot/2 has been run.
To run CD Boot/2 you either run CDBOOT, which is a AVIO (Advanced Video I/O) application
that can be run in an OS/2 windowed or fullscreen session, or run CDBOOTPM, which
is a PM executable.
There is no difference between both other than the user interface.
Also, both are able to find their code and data files so you don't have to
run them from the directory they were installed into!
For example, running CDBOOT interactively might result in the following log (Q:
is a virtual 2.88MB diskette drive where the bootable diskette image DISK_0_1.IMG
from MCP has been LOADDSKF'd onto):
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 ...
CB20080I: The drive(s) A, B, P, Q 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? Q
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 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 ...
You may notice that CD Boot/2 tells that CD Boot/2 has already been run once.
That happens when you run CD Boot/2 multiple times against the same media in a (physical
or logical) diskette drive, CD Boot/2 will take care of that situation so you
can ignore that warning.
In above example, CD Boot/2 was requested to install on drive Q:
and CD Boot/2 will configure the period where the user can decide to
continue booting from the removeable media or from the first harddisk
with 10 seconds.
Finally, an example for running CD Boot/2 against a bootable DOS installation
diskette (e.g. which can be used for a bootable DOS or WIN9x installation
CD-ROM):
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 ...
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? A
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 A:.
CB20085I: Reading the CD2BOOT code from file H:\PROGRAMMING\CDBOOT2\CD2BOOT.
CB20087I: The bootsector of the removeable media looks like a FAT based
non-OS/2 bootsector (e.g. from DOS). Likely it is compatible with CD Boot/2.
CB20089I: Writing the CD2BOOT code into file A:\CD2BOOT.
CB20090I: Modifying the bootsector of the removeable media to load CD2BOOT
instead of OS2BOOT.
CB20091I: Writing the modified bootsector onto the removeable media A:.
CB20061I: Waiting for CD Boot/2 to terminate ...
You can see above that CD Boot/2 detected that the diskette looks like a
FAT based diskette without an OS/2 bootsector.
Of course, you can do the same with the GUI version of CD Boot/2 CDBOOTPM!
Some words about the CD_BOOT.FLT and DANIBOOT.FLT filter drivers
The driver CD_BOOT.FLT is somewhat problematic to use, as I'm not sure
if it can be freely distributed as some packages do (that's why I do not include
it in the CD Boot/2 package), and it's not really documented.
You could of course use DANIBOOT.FLT instead, another great driver from
Daniela Engert.
It not only implements what the IBM driver does, but has even added flexibility
and certainly chances getting support from her are much better then from IBM.
Some things you may consider are from my experience:
- CD_BOOT.FLT is a driver that allows OS/2 to refer to the CD-ROM drive,
from BIOS has started booting from, to the same drive letter A: in
Protected-Mode as BIOS does in Real-Mode.
You may have already heard that OS/2 partly boots in Real-Mode (e.g. some types
of drivers are loaded in Real-Mode) and switches to Protected-Mode at a later
stage in the boot process and still uses the drivers loaded in Real-Mode.
It's not too difficult to imagine that if BIOS under Real-Mode simulates drive
A: from the bootable image on the CD-ROM that OS/2 under Protected-Mode
still must rely on that being valid.
CD_BOOT.FLT is a filter driver that continues to represent drive A:
from the bootable image on the CD-ROM in Protected Mode (you then can
refer to the physical diskette drive A: by using B: instead),
while the normal CD-ROM driver still assigns the CD-ROM drive a normal
drive letter (that of course can
be influenced by the SET RESERVEDRIVELETTER=d: statement).
- Once CD_BOOT.FLT has been loaded 2 things hold true:
- Drive A: refers to the bootable image on the CD-ROM
- As OS/2 CD-ROM support must have been already loaded, you can refer the the
drive letter of the CD-ROM drive (e.g. for loading other drivers from CD-ROM).
For example, to load OS/2 CD-ROM support you need to specify CDFS.IFS
before CD_BOOT.FLT, however if you specify to load the HPFS and
JFS filesystem drivers after OS/2's CD-ROM Support and after
CD_BOOT.FLT, you can load both drivers from the CD-ROM (thus getting rid
of some space from the boot disks).
- If you need to boot OS/2 from more than one disk image (e.g. like MCP/ACP
does by having a 2.88MB disk_0_1.img and a 1.44MB disk_2.img),
those images need to be adjacent on the CD-ROM, the name of the images
however does not matter.
If the disks are listed in the same order as needed in the boot process
OS/2 will boot instead of displaying messages of not being able to operate
your harddisk or finding COUNTRY.SYS.
CD_BOOT.FLT will only find the next disk image if it immediately
follows the previous disk image, no file is allowed in between.
- If you want to have multiple bootable images on the CD-ROM, then I strongly
recommend of putting images that belong together into different subdirectories,
e.g. make a subdirectories like \BOOT1, BOOT2,...
- On the commandline of CD_BOOT.FLT you have to tell it how many disk
images it should expect, and that seems to be counted in 1.44MB sizes.
For example the MCP/ACP bootable CD-ROM contains a 2.88MB image containing the
contents of the installation diskettes 0 and 1, and a 1.44 MB image of diskette
2, in sum you need 3 1.44MB, thus you need to specify /D:3.
For example, if all you need is a single 2.88MB diskette image (as all other
things will be loaded from the CD-ROM's driver letter after OS/2's CD-ROM
support has been loaded from that 2.88MB image), then you need to specify
/D:2.
If you specify /D:n incorrectly, symptoms are that OS/2 tells you not
being able to operator your harddisk or not finding COUNTRY.SYS and the boot halts.
So, here are some examples of the output of isoinfo -i cdromimage.iso -l
(the sequence number just denotes the order the data is listed and
thus the order the data will be burn onto the CD-ROM, not
necessarily that the ordinal number of the files on the CD-ROM) and the consequences:
- The first and second OS/2 diskette images are in the correct order, OS/2 thus
can boot:
- DISK_0_1.IMG
- DISK_2.IMG
- The second image precedes the first one, OS/2 will not be able to boot:
- DISK_2.IMG
- DISK_0_1.IMG
- Another image (e.g. bootable DOS image) is between the first and second
image, OS/2 won't find OS/2 code on it:
- DISK_0_1.IMG
- DLS.IMG
- DISK_2.IMG
- Similar to above, if a file is between the first and second image, OS/2
won't be able to boot too:
- DISK_0_1.IMG
- DISK_1.DOC
- DISK_2.IMG
What CD Boot/2 does
CD Boot/2 (with the executables CDBOOT and CDBOOTPM) performs the
following things after it has started up:
- CD Boot/2 prompts the user (when running interactively, otherwise the drive specified on the
commandline is taken instead) which removeable media should be modified by CD Boot/2
and recommends the drives CD Boot/2 thinks are removeable.
Allowed are A to Z.
- CD Boot/2 prompts the user (when running interactively, otherwise the timeout specified on
the commandline is taken instead) how many seconds the period for the user to decide if
boot should continue booting from the removeable media or from the first harddisk should last.
Allowed are 1 to 60 seconds.
- CD Boot/2 then reads the boot sector from the removeable media into memory.
- CD Boot/2 then reads the file CD2BOOT from the directory CD Boot/2
was installed into and replaces a buffer with the boot sector read in the previous
step.
- CD Boot/2 writes the modified CD2BOOT file onto the removeable
media the user specified.
- CD Boot/2 then replaces the original boot sector on the removeable media
by a modified one that tries to load CD2BOOT instead of OS2BOOT.
Creating bootable OS/2 CD-ROMs
Now that you have created a bootable 2.88MB media and run CD Boot/2 against it
to add the boot menu, you need to burn a bootable OS/2 CD-ROM.
While you could use most WIN based CD-ROM authoring programs as they usually
support creation of bootable CD-ROMs I hope you don't need to switch to the
evil empire as you can also use excellent OS/2 Freeware for the same purpose!
- I would recommend you check that you have the latest port of
CDRecord/2, the excellent
port of CDRecord to OS/2 done by Chris Wohlgemuth (which by the way also explains
how to build bootable OS/2 CD-ROMs in general not concentrating on bootable
OS/2 installation CD-ROMs as I do here).
That package contains both MKISOFS to create ISO CD-ROM images and
CDRECORD to actually burn an ISO image onto (SCSI based) CD-ROM recorders
(for ATAPI based recorders, please read the CDRecord/2 instructions for more
details, basically you have to use Daniela Engert's DANIS506.ADD and
DANIATAPI.FLT)).
- As the OS/2 installation CD-ROM (and likely many other CD-ROMs too) is not
conforming to the ISO-9660 CD-ROM standard regarding the characters used for
filenames and the directory depth, I would recommend to use another version of
MKISOFS
that supports the HPFS filename convention on CD-ROMs too.
- You have to create an image from the bootable 2.88MB media, e.g. by running
SAVEDSKF x: d:\cdboot.img /D/A (the options ensure that the image is a 1:1
image of the media being 2949120 bytes in size).
If you want to use VMDISK you would then have to remove the first 8 bytes
from the resulting image file.
- Prepare the OS/2 installation files you want to have on the bootable OS/2
installation CD-ROM.
You can use the non-bootable OS/2 installation diskette, for e.g. MCP the root directory
looks like:
The volume label in drive d is WARP_4_CP.
The Volume Serial Number is A519:2392.
Directory of R:\
16.11.00 10.25 0 .
16.11.00 10.25 0 ..
16.11.00 7.15 11 0 OS2SE20.SRC
16.11.00 9.07 0 bitmaps
16.11.00 8.10 0 books
16.11.00 9.30 0 bootimgs
5.09.00 12.10 1937 0 cdinst.bat
5.09.00 12.10 1903 0 cdinst.cmd
15.11.00 19.45 38912 0 chkinst.exe
16.11.00 7.47 0 cid
16.11.00 7.14 0 diskimgs
6.09.00 12.43 9459 0 dmf_ps2.cmd
16.11.00 8.05 0 ibminst
16.11.00 8.05 0 info
3.04.00 15.42 956 0 install.cmd
16.11.00 9.07 0 options
16.11.00 9.19 0 os2image
10.11.00 14.39 4802 0 readme.add
10.11.00 14.39 112965 0 readme.txt
16.11.00 8.05 0 report
15.11.00 19.48 476592 0 rspinst.exe
15.11.00 19.48 81271 0 sample.rsp
15.11.00 22.01 130672 0 vcu.exe
15.11.00 19.45 1760 0 vcu.msg
24 file(s) 861240 bytes used
0 bytes free
Next you have to add the image of the bootable OS/2 2.88MB media, I would recommend
for a bootable OS/2 installation CD-ROM to just replace the original one, as that most likely works
(for bootable DOS CD-ROMs it does not matter, as the bootable DOS diskette is everything
you need to run, while a bootable OS/2 does not fit on a single 2.88MB media an thus the
OS/2 kernel has to rely on a known layout).
To avoid copying the complete CD-ROM onto a writeable media you might want to use the IBM
EWS TVFS
(Toronto Virtual File System) which
allows you to define symbolic links like in UNIX (I personally could not live without
that utility)!
Next you prepare the directory structure of your bootable OS/2 installation CD-ROM.
I used TVFS and the following batchfile to setup a bootable Aurora Convenience
Pack (ACP) installation CD-ROM:
tvmount x:
tvlink -r x:\OS2SE20.SRC i:\OS2SE20.SRC
tvlink -r x:\bitmaps i:\bitmaps
tvlink -r x:\books i:\books
md x:\bootimgs
tvlink -r x:\cdinst.bat i:\cdinst.bat
tvlink -r x:\cdinst.cmd i:\cdinst.cmd
tvlink -r x:\chkinst.exe i:\chkinst.exe
tvlink -r x:\cid i:\cid
tvlink -r x:\diskimgs i:\diskimgs
tvlink -r x:\dmf_ps2.cmd i:\dmf_ps2.cmd
tvlink -r x:\ibminst i:\ibminst
tvlink -r x:\info i:\info
tvlink -r x:\install.cmd i:\install.cmd
tvlink -r x:\options i:\options
tvlink -r x:\os2image i:\os2image
tvlink -r x:\readme.add i:\readme.add
tvlink -r x:\readme.txt i:\readme.txt
tvlink -r x:\report i:\report
tvlink -r x:\rspinst.exe i:\rspinst.exe
tvlink -r x:\sample.rsp i:\sample.rsp
tvlink -r x:\vcu.exe i:\vcu.exe
tvlink -r x:\vcu.msg i:\vcu.msg
tvlink -r x:\bootimgs\disk_0_1.img F:\CDBOOT.IMG
tvlink -r x:\bootimgs\disk_2.img i:\bootimgs\disk_2.img
tvlink -r x:\bootimgs\CONFIG.SYS i:\bootimgs\CONFIG.SYS
When using a 800MB CD-R media, you may also add the following two lines to include
Java 1.1.8 and the Warp Toolkit from the bootable CD-ROM on your bootable OS/2
installation CD-ROM (assume that that CD-ROM is inserted into drive j:):
tvlink -r x:\java118 j:\java118
tvlink -r x:\toolkit j:\toolkit
Drive x: is the virtual drive obtained with TVFS, i: is the drive
the original non-bootable ACP installation CD-ROM was inserted, and
F:\CDBOOT.IMG contained the image taken with SAVEDSKF from the virtual
2.88MB drive supported from VFDISK onto which I uncompressed the original
i:\bootimgs\disk_0_1.img and modified it with CD Boot/2.
You can see from above example that I replaced the original bootable 2.88MB disk
image by the one modified with CD Boot/2.
In case you wonder why I have done that, well the OS/2 kernel seems to contain
some logic to be able to find disk_2.img on the CD-ROM after having been
booted from the bootable disk_0_1.img image on the CD-ROM.
If you boot from that CD-ROM and use F3 to exit to an OS/2 fullscreen, you'll
notice that a DIR A: will show the contents of disk_2.img (not disk_0_1.img),
and e.g. DIR D: will show the CD-ROM contents.
Thus I think bootable OS/2 CD-ROMs require some support in the kernel to work,
and I doubt that is available for versions earlier than Warp3.
Now it's time to create the bootable OS/2 installation CD-ROM image using
the HPFS filename convention supporting version of MKISOFS by running e.g.
mkisofs -D -national -hpfsnames -o o:\acp.raw -b bootimgs/disk_0_1.img -c BOOT.CAT -v -v -allow-lowercase -no-iso-translate -V WSEB_CP x:/
which results in (you might need to check the options to ensure you really
add the files to the image identical to the source,
but above ones are a good starting point, e.g. creation of a complete bootable
OS/2 installation CD-ROM from both Convenience CDs on a single 800 MB CD-ROM failed
unless I additionally used the -dao parameter too):
Using ".mkisofsrc"
Warning: creating filesystem that does not conform to ISO-9660.
mkisofs 1.14a04 (i386-pc-os2_emx)
Scanning x:/
...
Cache hit for /..
...
38 1477 x:/bootimgs/disk_0_1.img
...
Size of boot image is 5760 sectors -> Emulating a 2.88 meg floppy
Total extents scheduled to be written = nnnn
Total translation table size: nnnn
Total rockridge attributes bytes: 0
Total directory bytes: nnnn
Path table size(bytes): nn
Max brk space used nnnnn
nnnnnn extents written (nnn Mb)
The ISO CD-ROM image o:\acp.raw will be build from the files at the path
x:/ that also contains the image of the bootable OS/2 2.88MB media prepared
with CD Boot/2.
One word about case sensitivity.
MKISOFS is, well let's say peculiar, regarding how you specify the bootable image
and if you don't use the correct case you easily get the (not really helpful) error message
mkisofs: Uh oh, I cant find the boot image 'bootimgs/DISK_0_1.IMG' !.
The best way to find the correct case of the bootable image is to look how MKISOFS
displayed the filename (that's why I recommend to use the verbose options -v -v),
in above example it displayed x:/bootimgs/disk_0_1.img so you have to currectly specify
-b bootimgs/disk_0_1.img and not -b bootimgs/Disk_0_1.Img or any other combination.
Unfortunately the case that MKISOFS displays with the verbose options does not
necessarily reflect what you see when using the command DIR against the bootable
image.
It depends on the filesystem (and here you can have a FAT, a HPFS, a TVFS, a Network,
a NFS, a EXT2, a FTPIFS, a ... drive), and while OS/2 is not case sensitive but just
case preserving (that means that OS/2 references always the same file ABC regardless if you
spell it ABC, abc, Abc, aBC, ...) MKISOFS does see the thinks differently, most
likely as a result from its UNIX roots (where the filesystems are case sensitive!).
Now burn that ISO CD-ROM image onto a CD-R or CD-RW using e.g. CDRECORD or
the good old Unite CD-Maker.
I don't go into the details here, as buring a ISO CD-ROM image usually is straight
forward for all burning software, for CDRECORD you may start with the command
mkisofs -v dev=0,4,0 speed=8 o:\acp.raw.
One comment about burning CD-Rs or CD-RWs larger than 650 MB (74 minutes).
At least on the CD-writer I used (Plextor 121032S) 700 MB and 800 MB CDs failed
to be burned correctly, even when using the test mode using the -dummy
parameter, unless I also supplied the -dao parameter.
In other words the command that worked for me to burn a bootable OS/2 installation
CD-ROM that contained the both base CDs IBM shipps onto a 800 MB CD-R was
cdrecord -v -dev=1,4,0 speed=8 fs=32000000 -dao o:\acp.raw.
I recommend to burn every CD in test mode or onto a CD-RW to avoid wasting CD-Rs
if possible, and with burning speeds of 4x or more it only takes a few minutes
extra.
If you really want to be sure everything worked correctly I would recommend to compare
the original CD-ROM with the newly created one.
XComp/2 and
IsoComp/2,
(2 other utilities done by me ;-) were exactly written to make such compares easily.
From my personal experience, it is not too unlikely that for 5 to 10 CD-Rs or CD-RWs
you burn 1 might have problems either just in some CD-ROM drives or in any.
You may look onto the
XComp/2 or
IsoComp/2
pages to find some items describing why that may happen.
So, be on the safe side and do the comparism!
And finally, insert your new bootable OS/2 CD-ROM into a CD-ROM drive, if not
already done so change your BIOS settings to allow booting from CD-ROMs and restart
your PC.
Hopefully you'll see CD Boot/2's menu immediately after BIOS started booting from the
CD-ROM.
I could successfully install Aurora Convenience Pack from the bootable OS/2 installation
CD-ROM I created according to the steps above!
P.S. I'm a native German speaker, so please excuse my intermittent misuse of the English
language in my programs and documentations.
(C) Roman Stangl (Roman_Stangl@at.ibm.com), 29.01.2001
Last update: 22.05.2002