Home
Developer Resources
QNX RTOS v4
QNX RTOS v4 Knowledge Base

QNX RTOS v4 Knowledge Base

Foundry27
Foundry27
QNX RTOS v4 project
Resources

QNX RTOS v4 Knowledge Base

Title How to create a licensed QNX4 boot floppy.
Ref. No. QNX.000005718
Category(ies) Installation, Configuration
Issue How do we create a licensed QNX4 boot floppy?
Solution Get a fresh 720K or higher floppy.  At least 720k will be required for this.
We will assume: - you are superuser (root)
                - the floppy is a 720K in drive A (/dev/fd0)
                - the node we wish to make a boot floppy for is node 10

Make sure that Fsys is running, Fsys.floppy is running, and the floppy is mounted as a QNX filesystem.

Fsys &
Fsys.floppy &
mount /dev/fd0 /fd0    #for first floppy

Format the floppy.
fdformat -s720 /dev/fd0

Dinit the floppy.
dinit /dev/fd0

Now let's look at the boot image.
You should have a file called 'floppy' in /boot/build. Edit this file.
The default one looks something like:

sys/Proc
$ 9500 Proc -p 30 -f 8 16 240 -n 10 -s 10 -t 6

sys/Slib
$ 1 Slib

/bin/Fsys
$ 2000 fsys -f 10 -i 20 -l 0 -c 40 -r 24

/bin/Fsys.floppy
$ 1000 Fsys.floppy

/bin/mount
$ 1000 mount /dev/fd0 / -r

/bin/sinit
$ 1000 sinit  TERM=qnx

You can customize any way you want with some special exceptions. I changed this file and saved the following data as 'floppyb':

sys/Proc
$ 38000 Proc -l 10

sys/Slib
$ 1 Slib

/bin/Fsys
$ 16000 Fsys -r 300

/bin/Fsys.floppy
$ 1000 Fsys.floppy

/bin/mount
$ 1000 mount /dev/fd0 /

/bin/sinit
$ 1000 sinit  TERM=qnx

Notice the following:
- I added a -l 10 option to Proc.
  A BOOT FLOPPY IS SPECIFIC TO THE NODE IT IS BOOTING!! i.e. This floppy will only boot node 10 into the network.
- I removed the -r option on the mount (this makes the filesystem R/W not just READ-ONLY)
- I changed other options to more closely follow the 'hard' build file.
- I added a 300K ramdisk in case I need it later.

Make an image based on this build file (floppyb)
cd /boot
make b=floppyb

You will now have a file called floppyb in /boot/images.
Copy this to the floppy
cp -v /boot/images/floppyb /fd0/.boot

Now let's add licensing to the floppy. Run the following command to copy your license information to the floppy (the harddisk where you boot will not be affected). In this example, I will assume the node where the license files are is prefixed as '/'. It could be anywhere, even across the net ...

e.g.
//35/etc/licenses

mkdir -p /fd0/etc/licenses
license /etc/licenses /fd0/etc/licenses

Check for the license files on the floppy, they should be there.
ls -lF /fd0/etc/licenses

Now, copy all the programs required to boot from the floppy. Here is a list of what you will need at a minimum:

/fd0:
.altboot
.bitmap
.boot
.inodes
bin/
etc/

/fd0/bin:
Dev*
Dev.con*
login*
mount*
netmap*
prefix*
ksh*
tinit*

/fd0/etc/config:
sysinit

/fd0/etc/licenses:
Your license files that were copied over previously.
You will need a sysinit.node# file on the floppy in /etc/config.

Here is an example:

TZ=utc00
rtc -l hw
Dev &               
Dev.con -n 4 &
reopen
emu87 &
tinit -t /dev/con1 -T /dev/con[2-4] &