Creating a Jumpstart server from Solaris 9 ISO's.

(C) Copyright Scott Howard, 2003
scott@doc.net.au

In order to setup a Jumpstart server using the Solaris 9 CD's you need to have access to both slice 0 and slice 1 on the CDs. If you're using a physical CD then thats not a problem - vold will automatically mount both of the required slices for you, or if you're not using vold you can mount them manually yourself.

However, if you're trying to use an ISO image, mounted using the "lofi" driver, then you've got a problem as lofi is not VTOC aware, which in short means that it has no way of knowing that slice 1 even exists, let alone being able to access it.

In order to fix this you need to split the contents of slice 1 into it's own image file that you can then point lofiadm at. The procedure for doing this is described below...

I'm presuming you've already download the ISO images for Solaris 9, which means you should already have two files which look something like the following :

# ls -l sol-9*
-rw-r--r--   1 root     root     576364544 Jan  1 11:16 sol-9-u1-sparc-v1.iso
-rw-r--r--   1 root     root     291962880 Jan  1 21:42 sol-9-u1-sparc-v2.iso
(The exact names and sizes will vary, depending on where you got the files from, and what version of Solaris 9 they are).

The only one we are interested in is the first image - "CD 1 of 2".

Firstly we need to get a copy of the VTOC (Virtual Table of Contents) from the ISO image. We do this with :

# dd if=sol-9-u1-sparc-v1.iso of=vtoc bs=512 count=1
1+0 records in
1+0 records out
Now that we've got the VTOC we need to find out where Slice 1 start in the image, and how long it is. The starting cylinder for slice 1 is located at offset 452 (decimal) into the VTOC, whilst the length in blocks is at offset 456, with both being 4 bytes long. Thus we can find them out using :

# od -D -j 452 -N 8 < vtoc
0000000 0000000888 0000546560
0000010
So slice 1 starts on cylinder 888, and is 546,560 blocks long. Solaris CD's always have a fixed 640 blocks per cylinder, which means that we can calculate the starting block of slice 1 with :

# echo 888*640 | bc
568320
So slice one starts at block 568320, and is 546560 blocks long.

We can then take a copy of this slice into a separate file with :

# dd if=sol-9-u1-sparc-v1.iso of=sol-9-u1-sparc-v1-s1 bs=512 skip=568320 count=546560
546560+0 records in
546560+0 records out
Once we've got this, we just need to mount both slice 0 (ie, the original ISO) and slice 1. The setup_install_server script expects to find these two mounted beside each other, with slice 1 in a directory called "s1" (as vold does it), although you can mount them wherever you want and just use the "-t" option to setup_install_server.

# mkdir /cd
# mkdir /cd/s0
# mkdir /cd/s1
# lofiadm -a /path/to/sol-9-u1-sparc-v1.iso
/dev/lofi/1
# lofiadm -a /path/to/sol-9-u1-sparc-v1-s1.iso
/dev/lofi/2
When mounting slice 1 we need to remember that it is a UFS partition, not HSFS like you'd normally expect on a CD-ROM.

# mount -F hsfs -o ro /dev/lofi/1 /cd/s0
# mount -F ufs -o ro /dev/lofi/2 /cd/s1
# cd /cd/s0/Solaris_9/Tools/
# ./setup_install_server  dest_dir
If you get an error "ERROR: Copy of CD image failed", then check your messages file for an entry like "NOTICE: hsfs: hsnode table full, 356 nodes allocated" then you need to apply patch 109764-03 or later.