Creating a Solaris 8 Flash Archive Boot Disk

This tutorial describes creating a Solaris 8 flash archive boot disk with Schily’s mkisofs.


#! /bin/csh
# script asumptions:
# the /opt/make_os directory is present.
# the flash archive s8.archive is in the /opt/make_os directory
# the file profind is located in /opt/make_os
# the mkisofs is located in /opt/schily/bin
# the Solaris 8 Software 1 of 2 disk

cd /opt/make_os
# make the solaris_8 directory to assemble the image in
mkdir solaris_8
# pull off the s0 directory from the cd
cd /cdrom/cdrom0/
find s0 -print | cpio -pudm /opt/make_os/solaris_8
cd /opt/make_os/solaris_8
# dump the rest of the info from the cd
/etc/init.d/volmgt stop
sleep 10
foreach i (1 2 3 4 5)
dd if=/dev/dsk/c0t2d0s$i of=s8u5.s$i bs=512
end
/etc/init.d/volmgt start
sleep 10
# remove the packages from the Product directory
cd /opt/make_os/solaris_8/s0/Solaris_8/Product
rm -rf *
# copy the s8.archive file into the Product directory
cp /opt/make_os/s8.archive /opt/make_os/solaris_8/s0/Solaris_8/Product
# remove the configuration files from the .install_config directory
cd /opt/make_os/solaris_8/s0/.install_config
rm *

# create the s8.profile in the .install_config directory

echo “install_type flash_install” > s8.profile
echo “archive_location local_file /cdrom/Solaris_8/Product/s8.archive” >> s8.profile
echo “partitioning explicit” >> s8.profile
echo ” ” >> s8.profile
echo “filesys rootdisk.s0 free /” >> s8.profile
echo “filesys rootdisk.s1 1:1450 swap” >> s8.profile
echo “filesys rootdisk.s7 1451:4 unnamed” >> s8.profile

chmod 644 s8.profile

# run check on the rules file to create the rules.ok file
# copy the rules.ok to the .install_config directory

# rules file looks like
echo “any – – s8.profile -” > rules
chmod 644 rules

/cdrom/cdrom0/s0/Solaris_8/Misc/jumpstart_sample/check
rm rules
#cd /opt/make_os/solaris_8/s0/Solaris_8/Tools/Boot/usr/sbin/install.d
# edit the profind file and modify cdrom() to look like

#cdrom()
#{
# Factory JumpStart is only allowed with factory
# stub images, indicated by the file /tmp/.preinstall
#
# if [ -f /tmp/.preinstall ]; then
# mount -o ro -F lofs ${CD_CONFIG_DIR} ${SI_CONFIG_DIR} >/dev/null 2>&1

# if [ $? -eq 0 ]; then
# verify_config “defaults” “CDROM”
# fi
# fi

# gettext ” <<< using CDROM install_config >>>”; echo #new
# rmdir ${SI_CONFIG_DIR} #new
# ln -s /cdrom/.install_config ${SI_CONFIG_DIR} #new
#}

# copy the profind file from the /opt/make_os directory
cp -p /opt/make_os/profind /opt/make_os/solaris_8/s0/Solaris_8/Tools/Boot/usr/sbin/install.d

# now edit the sysidcfg on slice 1

lofiadm -a /opt/make_os/solaris_8/s8u5.s1
mount /dev/lofi/1 /mnt
rm /mnt/etc/sysidcfg
cd /mnt/etc
# create a new sysidcfg

echo “system_locale=en_US” > sysidcfg
echo “timezone=US/Pacific” >> sysidcfg
echo “network_interface=primary {hostname=YOUR HOSTNAME” >> sysidcfg
echo ” ip_address=YOUR HOST’S IP” >> sysidcfg
echo ” netmask=255.255.255.0″ >> sysidcfg
echo ” protocol_ipv6=no}” >> sysidcfg
echo “terminal=vt100” >> sysidcfg
echo “security_policy=NONE” >> sysidcfg
echo “root_password=PASSWORD FROM SHADOW FILE” >> sysidcfg
echo “name_service=NONE” >> sysidcfg
echo “timeserver=localhost” >> sysidcfg

chmod 777 sysidcfg

#
cd /opt/make_os/solaris_8
umount /mnt
lofiadm -d /dev/lofi/1

# create the image using Schily’s mkisofs
/opt/schily/bin/mkisofs -R -D -d -L -l -sparc-boot s8u5.s1,s8u5.s2,s8u5.s3,s8u5.s4,s8u5.s5 -o s8u5.image ./s0

# burn the cd
#cdrw -C -d cdrom0 -i /opt/make_os/solaris_8/s8u5.image

The Conversation

Follow the reactions below and share your own thoughts.