Bootable DVD creation

Bootable DVD Environment Setup
==============================

1) Create a temp directory to mount the iso image

mkdir /soldvd

2) To mount the iso image, enter:

lofiadm -a `pwd`/sol-10-u8-ga-sparc-dvd.iso /dev/lofi/1

mount -F hsfs -o ro /dev/lofi/1 /soldvd

3) Create a data directory to extract the iso image

mkdir -p /soldvd10/SPARC/dvd

4) To extract the image contents to the data directory, enter:

cd /soldvd

find . -depth -print | cpio -pdm /soldvd10/SPARC/dvd

5) Unmount and remove your lofi device as it's no longer needed

cd /

umount /soldvd

lofiadm -d /dev/lofi/1

rm -rf /soldvd

6) To use root_archive to extract your miniroot, perform the steps below

mkdir -p /soldvd10/SPARC/mr

/boot/solaris/bin/root_archive unpackmedia /soldvd10/SPARC/dvd /soldvd10/SPARC/mr

-----------------------------------------------------------------------
Note: If you see the following warning, do as specified in the fix

umount: /tmp/mnt23685 busy
rmdir: directory "/tmp/mnt23685": Directory is a mount point or in use
lofiadm: could not unmap file /soldvd10/SPARC/dvd/boot/sparc.miniroot: Device bu
rmdir: directory "/tmp/mnt23685": Directory is a mount point or in use

FIX : (a) lofiadm

Block Device File
/dev/lofi/1 /soldvd10/SPARC/dvd/boot/sparc.miniroot

(b) umount -f /tmp/mnt23685

(c) lofiadm -d /dev/lofi/1
-----------------------------------------------------------------------

7) To tell jumpstart that the necessary files are available on the DVD, do

touch /soldvd10/SPARC/mr/.tmp_proto/.preinstall


8) Next, you'll need to put your profile, rules files, begin and finish scripts in the
following directory

cd /soldvd10/SPARC/dvd/Solaris_10/Misc/.install_config

9) To create T5120Sol10.profile, enter:

#########################################

vi T5120Sol10.profile

install_type flash_install
archive_location local_file /cdrom/Solaris_10/Product/sol10lca.flar
partitioning explicit

filesys rootdisk.s0 53374 /
filesys rootdisk.s1 4104 swap
filesys rootdisk.s3 82143 /opt

#########################################

vi T2000Sol10.profile

install_type flash_install
archive_location local_file /cdrom/Solaris_10/Product/sol10lca.flar
partitioning explicit

filesys rootdisk.s0 32880 /
filesys rootdisk.s1 4097 swap
filesys rootdisk.s4 32880 /opt

#########################################

vi default.profile

install_type flash_install
archive_location local_file /cdrom/Solaris_10/Product/sol10lca.flar
partitioning explicit

##########################################

vi rules

model SUNW,Sun-Fire-T200 - T2000Sol10.profile -
model SUNW,SPARC-Enterprise-T5120 - T5120Sol10.profile -
any - - default.profile -

##########################################


10) To run check on your rules file to create the rules.ok, enter:

/soldvd10/SPARC/dvd/Solaris_10/Misc/jumpstart_sample/check

Validating rules...
Validating profile T2000Sol10.profile...
Validating profile T5120Sol10.profile...
Validating profile default.profile...
The custom JumpStart configuration is ok.

---------------------------------------------------------------------------------
Note: Repeate from Step 11 from second time onwords, once the environment setup
is completed for Bootable DVD creation
---------------------------------------------------------------------------------

11) To free up a sufficient amount of space to include the flash archive, enter

rm -rf /soldvd10/SPARC/dvd/Solaris_10/Product/*

12) To copy the create flar image to the DVD jump start location, enter:

cp sol10lca.flar /soldvd10/SPARC/dvd/Solaris_10/Product

---------------------------------------------------------------------------------
Note: Do Step 6 and 7 before continuing with Step 13 from second time onwords,
once the environment setup is completed for Bootable DVD creation

(ie.) Step 11, 12, 6, 7, 13, 14, ....
---------------------------------------------------------------------------------

13) To to reinstall the miniroot back on to the DVD image, enter:

/boot/solaris/bin/root_archive packmedia /soldvd10/SPARC/dvd /soldvd10/SPARC/mr

---------------------------------------------------------------------------------
Note: Once you run packmedia against your miniroot directory (/soldvd10/SPARC/mr),
do not reuse it. This is because packmedia makes modifications to it that
can only be undone by unpackmedia against the miniroot image file, which is
now in /soldvd10/SPARC/dvd. The prudent thing to do at this point is to
remove it: /soldvd10/SPARC/mr
---------------------------------------------------------------------------------

14) To clear the mini root, enter:

rm -rf /soldvd10/SPARC/mr/*

15) At this point, we have the directory structure needed to create our ISO image file.
Use mkisofs to create the image for burning. For SPARC, the following can be used:

cd /soldvd10

/usr/bin/mkisofs -N -D -R -d -l -J -G /soldvd10/SPARC/dvd/boot/hsfs.bootblock -B ... -graft-points -relaxed-filenames -V "Solaris510_SPARC_LCA10" -o /soldvd10/SPARC/sol10lca.iso /soldvd10/SPARC/dvd


Total translation table size: 0
Total rockridge attributes bytes: 90994
Total directory bytes: 311296
Path table size(bytes): 1848
Total extents including sparc boot = 687360
Max brk space used cc000
687510 extents written (1342 MB)


For x86, the following command can be used to create the ISO image:

# /usr/bin/mkisofs -N -D -R -U -l -J -b boot/grub/stage2_eltorito -no-emul-boot -boot-load-size 4 -boot-info-table -c .catalog -V "Solaris510_x86_LCA10" -o /soldvd10/X86/sol10lca_x86.iso /soldvd10/X86/dvd


16) Follow these steps to write on to the CD drive. Enter:

Note: Following packages are required for cd writer

pkginfo SUNWmkcd SUNWcdrw


1) Put the empty CD on the CD Drive

2) To identify the CD node, enter:

cdrw -l

Looking for CD devices...
Node Connected Device Device type
----------------------+--------------------------------+-----------------
cdrom0 | HL-DT-ST DVDRAM GSA-E10L LE06 | CD Reader/Writer


3) To check whether the cd media is blank, enter:

cdrw -M

Device : HL-DT-ST DVDRAM GSA-E10L
Firmware : Rev. LE06 ()
Media is blank


Note: If the CD re-writable media has some data then you may erase the media as follows

cdrw -b all


4) To write the image on to the DVD, enter:

cdrw -d cdrom0 -i /soldvd10/sol10lca.image

Note: cdrom0 = Node value from cdrw -l command