Boot Able

Hayo Baan
version 3.0a 23/02/2004

Contents

1. Introduction
2. Highlights
3. Installation
3.1 BootAble files
3.2 Other files and applications
4. Syntax
5. Creating a bootable CD
5.1 Using cdrecord+mkisofs instead of RSJ
6. Creating a maintenance partition
7. Debugging
7.1 Test runs
7.2 Errors generated by the script
7.3 Check config.sys file
8. Contact information
9. Thanks
Version History

1. Introduction

Boot Able is a script to create a maintenance partition or a bootable CD. This partition/CD supports enough facilities to fully manage and recover your system.

Personally I use it for the CD-RWs I burn my system backups to. Recovering/reinstalling my system just takes booting-off this CD, optionally managing and formatting volumes and unzipping the backup-zip files that are also on the CD!

2. Highlights

A few highlights of the script:

The default settings assume an IDE only setup, instuctions for adding SCSI support are included in the defaults configuration file. If you need extra space on the boot image (for instance if you added SCSI support), instructions for making more room to the CD are included as well. Full USB support is also enabled by default and defaults to one UHCI adapter. Of course this can be fully configured. By default the script uses the DANI drivers for accessing IDE and ATAPI devices as these are the most stable. Again this can be configured.

When creating a bootable CD, the script assumes you use RSJ for burning CDs and that you have already attached the CD-R(W). A virtual 2.88MB floppy should also be available. Instructions for using this script with cdrecord and mkisosofs are included.

3. Installation

Installation is simple, just copy the files to the correct locations:

3.1. BootAble files

File Description Location*
bootAble.4os2 Configuration file for adding the 4OS/2 command shell environment SEARCHPATH
bootAble.acrobat Configuration file for adding Acrobat Reader SEARCHPATH
bootAble.cfg Defaults for configuration options/variables SEARCHPATH
bootAble.cmd The script to create a bootAble CD or maintenance partition PATH
bootAble.emxrt Configuration file for adding the EMX runtime (contributed by Christoph Brendes) SEARCHPATH

Configuration file for adding some extra utilities SEARCHPATH
bootAble.html These instructions -
bootAble.ico
Icon file
-
bootAble.maintenance Sample configuration file for creating a maintenance partition SEARCHPATH
bootAble.myCfg Sample configuration file can be used as starting point for creating your own specific settings SEARCHPATH
bootAble.norman Configuration file for adding Norman Anti Virus support (contributed by Doug Bissett) SEARCHPATH
bootAble.normanRC
Additional User ini template for Norman Anti Virus support
SEARCHPATH
bootAble.pmdll Configuration file for adding PMdll, a tool to report DLL dependencies of executables SEARCHPATH
bootAble.pmview Configuration file for adding PMView SEARCHPATH
bootAble.pmviewRC Additional User ini template for PMView
SEARCHPATH
bootAble.Src System ini template (WPS) SEARCHPATH
bootAble.testCD Sample configuration file for testing the burning of a CD SEARCHPATH
bootAble.ttf Configuration file for adding TrueType and UniFont support (preliminary support)
SEARCHPATH
bootAble.Urc User ini template (WPS) SEARCHPATH
bootAble.usbres
Configuration file for adding the USB resource tool
SEARCHPATH
bootAble.wps Sample configuration file for creating a WPS bootAble CD/maintenance partition SEARCHPATH
bootAble.xwp
Configuration file for adding XWorkplace support
SEARCHPATH
bootAble.wxpRC Additional User ini template for XWorkplace support SEARCHPATH
bootAble.xwp_<LANG>
Sample configuration files for XWorkplace NLS versions, currently German (DE) and Spanish (ES, partially) are provided
SEARCHPATH
* Instead of copying the bootAble files to locations on the PATH/SEARHPATH, a specific directory where all files reside will of course also work (just make sure the command is invoked from that directory).
Note: The default value of SEARCHPATH is the value of os2\boot on the boot drive, LIBPATH, PATH, DPATH, HELP, and BOOKSHELF.

3.2. Other files and applications

File/Application/Option
Description
Req'd?
Location
Download
OS/2 Warp or eCS
The base OS and files.
YES
Installed* IBM/eComStation
CD Recorder Software Either cdrecord+mkisofs or RSJ can be used. 1
Installed** Hobbes/RSJ
Veit Kannegiesers no floppy emulation boot
You'll need to have the base memdisk files. In case you enable unicode or hpfs386 support, you'll furthermore need Veit Kannegieser's loaddll and untar.
Note: This version of bootAble has been tested with the 14/2/2004 release of the memdisk tool, currently to be found in the test directory on Veit Kannegieser's homepage (arj archives) or on my website (zip files).
1a
SEARCHPATH**
Veit Kannegieser/
zip-files
tar.exe
When using the no floppy emulation boot with unicode or hpfs386 support, the tar command is required.
1a
SEARCHPATH**
Hobbes
Virtual floppy Either vfdisk or super virtual disk can be used. A virtual floppy disk of 2.88MB should be inserted. 1b Installed Hobbes/BMT-Micro
daniboot.flt Required file for enabling CD-Boot. 1b
SEARCHPATH Hobbes
savedskf.exe Command to create a floppy-disk image file. 1b PATH Hobbes
FAT32
Fat32 files system driver developed by Henk Kelder. 2a
SEARCHPATH Hobbes
danis506.add
Enhanced IDE driver developed by Daniela Engert. 2a
SEARCHPATH Hobbes
daniatap.flt or daniatapi.flt
Enhanced ATAPI driver developed by Daniela Engert. 2a
SEARCHPATH Hobbes
HPFS386
HPFS386 file system driver (Warp server). 2b
SEARCHPATH IBM
jjscdrom.dmd
Enhanced CDROM driver developed by Takayuki 'January June' Suwa. 2b
SEARCHPATH Hobbes
danin512.flt or n512dasd.flt
Non-512 bytes/sector removable media support driver. Either Daniela Engert's or Alexander Terekhov's driver can be used. When both drivers are present, Daniela's is used. 2b
SEARCHPATH Hobbes
NTFS NTFS file system driver (eCS 1.1)
2b
SEARCHPATH eComStation
ibmrscsi.flt
Removable SCSI devices geometry filter driver. 2b
SEARCHPATH eComStation
LXLITE Compresses files (.exe, .dll, .fon, etc.) before writing, thus saving extra space. 2b SEARCHPATH** Hobbes
Roman Stangl's CDBoot menu Adds a boot menu to a bootable CD.
Note: When using RSJ, make sure to specify explicitly where the cdboot command can be found with the CDBOOTMENUFILE option!
2b SEARCHPATH** Hobbes
ramdisk.exe and ramdisk.ifs Ramdisk support (Required for a WPS enabled CD when not using the MEMDISK option). 2b SEARCHPATH Hobbes
bos2rexx.exe Required file when adding REXX support to a command-line boot. This file can be found in the bootOS2 package. 2b SEARCHPATH Hobbes





SIO2K Patch
Patch file for the problem where on reboot you get a trap in the UART or SIO driver when using the SIO2K driver.  This patch simply prevents the trapping function to be called at reboot.  This patch is provided with eCS 1.1.  The author, Veit Kannegieser (thank you), has however made it available for everyone interested.  A zip-file can be downloaded from my website (you only need the unbhsio.sys file from the archive).
2b
SEARCHPATH eComStation/zip-file
keyboard.dcp/viotbl.dcp Smaller keyboard.dcp and viotbl.dcp files to save extra space on the boot image, can be found on disk 2 of the WARP 4 installation disks.  If you want to use these, simply copy them to a directory on the SEARCHPATH before the original (you'll need to renam vtbl850.dcp to viotbl.dcp as well). NO SEARCHPATH IBM
* In addition to the standard location, necessary files are also searched for on the SEARCHPATH.
** The exact location is specified with a configuration variable.
1 Required when creating a bootAble CD
1a Required when creating a bootAble CD with the no floppy emulation
1b Required when creating a bootAble CD with the standard floppy disk emulation method (default)
2a Required when related option is enabled (default)
2b Required when related option is enabled (disabled by default)

4. Syntax

The command syntax is as follows:

bootAble [/v <verbose>] [<configuration file>...]

The optional arguments are the verbosity level and one or more configuration files to use. If no path for these files is specified, the DPATH is searched. Use these configuration files to override the defaults as specified in the file bootAble.cfg(which is to be found on the DPATH). Note:You only need to specify configuration options/variables which override the defaults!

5. Creating a bootable CD

Here are a few easy steps for creating a bootable CD:

  1. Download and install all required files;
  2. Read through the configuration file bootAble.cfg. All default settings for the script are done via this file. The options are all commented. Work through them top to bottom, most likely you will only need/want to change a few of the 'basic' ones. You'll probably not going to neet to bother with the 'advanced' ones (unless you know what you are doing...);
    Please note: When configuring bootAble you can/should leave the generic defaults file bootAble.cfg alone and create your own configuration file(s). A configuration file only needs to contain lines for configuration options/variables overriding the defaults! See for example the supplied configurations files bootAble.wps, bootAble.maintenance, etc.
  3. Create a bootAble.myCfg where you change the default options to match your needs (an example .myCfg as well as other example configuration files are included):
    1. You probably need to change directories/drives to match your setup;
    2. You probably want to specify BOOTMESSAGES='YES', VERBOSE=1+2+64, and PAUSEBEFOREBOOTIMAGE='YES' (already done in the sampe bootAble.myCfg);
    3. You probably also want to specify ADDITIONALCFG='' as the default will cause the screen to go to 80x50 mode, causing you to loose all boot progress messages (already done in the sample bootAble.myCfg)
    4. Check and or change the USB adapter type;
    5. If you have SCSI, set the SCSI option and specify the device driver for your card(s). You may need to set the TWODISKBOOT option or turn-off some other options if the driver(s) is/are a realy big;
  4. This should cover most cases, time to create the first boot image (instructions are for using RSJ, see below for necessary adoptations for using cdrecord/mkisofs):
    1. Insert an empty CD-R(W) in your burner. I would realy suggest to use CD-RW media; you are probably going to run this script a lot of times to get things the way you want. I know CD-Rs are dirt cheap, but please give the environment a break and what would you do with tons of coasters? (Yeah, you can microwave them for great effects but that becomes boring after a while...);
    2. Attach the CD-R(W) (cdattach w:). If it's a CD-RW you can erase it as well (cdwfmt w: /erase);
    3. Run the script with your configuration file (bootAble bootAble.myCfg);
    4. Put additional files on the CD if you like;
    5. Burn the CD (cdattach w: -s);
  5. Test it.

That's all! Now you probably want to play a bit with the numerous other options :-)

5.1 Using cdrecord+mkisofs instead of RSJ

When using cdrecord and mkisofs, change the configuration variable CDWRITER to the path you are going to build the CD in and set the option CDRECORD to "YES". The script is now ready to be used for cdrecord/mkisofs. Just one more thing needs to be done after running the script; instead of creating a normal ISO image for burning by cdrecord, you need to specify the correct image file to be used for booting (-b option to mkisofs). For normal floppy emulation booting, this is the OSBOOT.IMG in the root of the CD, for MEMDISK bootAble CDs, this is the CDLOADER.BIN in the BOOTIMGS directory (don't forget the -no-emul-boot option!).   Remember that mkisofs is case sensitive so use the correct case when specifying filenames.

6. Creating a maintenance partition

When creating a maintenance partition, follow the instructions found in the section describing the creation of a bootable CD (skip the specific steps involving CD creation; 4a, 4b, and 4c). When adapting the configuration file, additionally specify CREATEBOOTCD='NO' and point WRITERDRIVE to the maintenance partition (see bootAble.maintenance for an example); and run the script with these additional settings (e.g., bootAble bootAble.myCfg bootAble.maintenance).

Please note that the partition will be formatted by default (this can be prevented by specifying FORMATMAINTENANCE='NO')!

7. Debugging

7.1 Test runs

As creating a bootAble CD (or maintenance partition) usually involves some trial and error, it is best you try things out before ruining your next CD-R with a useless installation.  Of course, using a CD-RW already stops this waste, but I suggest to even go further and first make a few test runs on your harddisk.  To do this, simply include (a modified version of) bootAble.testCD on the command-line.  E.g., bootAble /v 67 bootAble.wps bootAble.myCfg bootAble.testCD.

7.2 Errors generated by the script

Allthough I have tried to make the script run perfectly in all situations, it is likely your first try of the script will fail with some error.  To help find the cause, the script knows various debug levels (VERBOSE setting or /v command-line option).  The following debug levels are currently supported:
bitvalue generated output
1 Progress messages
2 Files copied & Files parsed
4 Config file parsing
64 Error output of external commands
128 All external command output
The debug level is specified as a bitmask, this means you have to add the various bitvalues to get the script to output a combination of debug information.  A few examples:
For your first runs I suggest to set your debug level to 67 as this usually gives a good indication of the cause in case of error.

The bootAble script uses the REXX interpreter to process the  various lines in the configuration files. This means that whenever there is a (syntax) error in a configuration file, bootAble will fail with a REXX error.  Locating the source of this error, however, is not always a straigth forward matter as relevant information is usually missing.  To help debug these errors, specify debug level 4; this shows you all processed configuration file lines and this should give you the exact location of the error. As this generates lots of output, I suggest you do not specify this by default.
Note: the VERBOSE setting in a configuration file only becomes active after the corresponding configuration file has been read.  Especially if you are having configuration file problems, it may be advisable to specify the verbosity level with the /v command-line option (e.g., bootAble /V 71 bootAble.wps bootAble.myCfg bootAble.testCD).

7.3 Check config.sys file

If all goes well and the script finished without any error messages, check the created config.sys file.  The config,sys can be found on the boot image, which is created on yor virtual drive.  If, however, you are using the TWODISKBOOT option, the virtual drive will contain a the second boot image and does not contain your config.sys anymore.  To still check the created file you can do two things: either use the COPYCONFIGSYS to place a copy of config.sys in the root of the CD (or in the directory where the CD is created), or use PAUSEBEFOREBOOTIMAGE to interrupt the creation process and make a manual copy of the file.
If you are not happy with the resulting config.sys, add/remove options in your bootAble.myCfg.
Once you have verified the correctness of the config.sys you are ready to create a real bootAble CDs (or maintenance partition) and test its working.

8. Contact information

Hayo Baan: mailto:hrbaan@xs4all.nl,http://www.xs4all.nl/~hrbaan
IBM: http://www.ibm.com
eComStation: http://www.ecomstation.com
RSJ: http://www.rsj.de
Hobbes: http://hobbes.nmsu.edu
BMT-Micro: http://www.bmtmicro.com

9. Thanks

Thanks go to Allan Dermody for providing CD_BOOT.FLT and the first insight into creating bootable CDs;
Thanks also go to Alfredo Fernández Díaz for providing lots of feedback and for writing an excelent article on how to create a bootable CD in OS2Voice, July 2000;
Thanks go to Veit Kannegieser for all his work, especially the no floppy boot support;
More thanks go to Daniela Engert for writing the DANI suite of device drivers and filters;
Many thanks go to Simon Wright who helped me get my DHCP and DDNS server up and running.

Finaly big thanks also go to all you people testing and commenting the script; because of you I kept working on it ;-)


Version History

v3.0a (23/02/2004)

v3.0 (22/02/2004)

v2.19 (25/01/2004)

v2.18 (23/12/2003)

v2.17a (21/12/2003)

v2.17 (19/12/2003)

v2.16 (09/07/2003)

v2.15 (16/03/2003)

v2.14 (12/01/2003)

v2.13 (15/11/2002)

v2.12 (20/10/2002)

v2.11 (30/09/2002)

v2.10 (29/09/2002)

v2.9 (24/09/2002)

v2.8 (23/09/2002)

v2.7 (22/09/2002)

v2.6 (17/09/2002)

v2.5 (13/09/2002)

v2.4 (04/09/2002)

v2.3 (02/09/2002)

v2.2 (01/09/2002)

v2.1 (01/09/2002)

v2.0 (01/09/2002)

v1.4 (23/08/2002)

v1.3 (22/08/2002)

v1.2 (20/08/2002)

v1.1 (21/02/2002)

v1.0 (16/02/2002)