Andrew Rutz's blog
Using JumpStart to directly install from a CD/DVD
The following tutorial will save you time when installing Solaris via a CD or DVD. The default method is to do an Interactive Install, where one has to answer queries that the installer poses. This becomes tedious and error-prone if one has to install a large number of either machines or software versions. The solution is to use JumpStart.
However, I could not find any documentation describing how to use JumpStart when installing directly from a CD or DVD. In comparison, there are several places where "installing from a CD/DVD" is described, but they do not describe the desired solution (eg, they describe how to setup an install server using the CD/DVDs so that "network installs" can then be performed via the install server.
Note that there are two wonderful descriptions of how to create bootable CDs and DVDs ("Building a Bootable JumpStart Installation CD-ROM" and "Building a Bootable DVD to Deploy a Solaris Flash Archive" at this link) but they cater to the most general case: they provide an algorithm to modify a copy of the bootable image (and then write it to a CD/DVD).
However, for the cases where the bootable image does not need to be modified, the following
describes how to use JumpStart so that its normal files (sysidcfg, profile,
begin scripts, and finish scripts) can be referenced when directly booting from
a CD/DVD. This capability allows one to do an unattended install.
Setting up the install server - Yes, I know I said one will be directly
installing from the CD/DVD, but one has to get the JumpStart files from somewhere!
=:-). The install server is actually an rpc.bootparamd(1M)-server,
as we simply need a system other than the install client (eg, "target") that
will provide the JumpStart configuration information via /etc/bootparams. This
server must be on the same subnet as the target.
The trick is to hand-craft an /etc/bootparams entry for the target. The
entry must use only the sysid_config and install_config keywords.
The former identifies the directory where the sysidcfg file is located. The
latter identifies where the other JumpStart files reside (eg, rules.ok,
begin scripts, etc.).
You can use the following Korn Shell script to generate an /etc/bootparams
entry for a target named foo and a server named my_server.
foo's JumpStart files reside at /export/jump/foo on
my_server:
function bootpadd {
f=/etc/bootparams
cat >> $f <<EOF
$1 sysid_config=${2}:$(pwd) install_config=${2}:$(pwd)
EOF
}
# bootpadd foo my_server
# grep foo /etc/bootparams
foo sysid_config=my_server:/export/jump/foo install_config=my_server:/export/jump/foo
All of the target's JumpStart files can be put in one directory on the server. You will
need a sysidcfg file, a rules file, and any file referenced by
the rules file. For example, for a target with the name my_target, one could have the following rules file. Accordingly,
a directory on the server would have these files:
# cd .../jumpstart/my_target # cat rules any - - prof finish_script # ls -l total 3952 -rwxr-xr-x 1 root other 2920 Sep 17 2003 finish_script -rwxr-xr-x 1 root other 250 May 9 2005 prof -rwxr-xr-x 1 root other 27 Sep 17 2003 rules -rwxr-xr-x 1 root other 53 Nov 18 11:55 rules.ok -rwxr-xr-x 1 root other 243 Nov 18 14:25 sysidcfg
Note that the rules.ok file is created by running check(1M)
on the files in the above directory. check(1M) is located on the server
in the filesystem containing the install images for the Solaris version you are installing
(from CD/DVD):
# .../Solaris_10/Misc/jumpstart_sample/check Validating rules... Validating profile prof... The custom JumpStart configuration is ok.
Note that there is nothing in the contents of the above files that changes due to
directly installing via CD/DVD. Eg, as expected, these files simply have to pass the
verifications done by check(1M). Also, note that the profile file
(prof in our example) will be used when doing the JumpStart. Eg, there is
a profile file on the CD/DVD, but it is not used if the install_config
keyword is used in the /etc/bootparams file. Also, if that keyword is not
present, an Interactive Install will be performed.
Booting from the CD/DVD - All that is needed to use the above configuration is to
reach the SPARC OBP command line and enter this boot command:
# sync; sync # eeprom | grep auto-boot auto-boot?=false # shutdown -i0 -y -g0 ... ok boot cdrom - install ...
Adding the "- install" suffix causes JumpStart to be used. JumpStart will
query our server for the target's /etc/bootparams entry. When you are
done installing, you can use this Korn Shell function to remove our target's
/etc/bootparams entry (as rm_install_client(1M) will not know
about it, because we never ran add_install_client(1M)):
function bootprm {
eval sed '/^${v}/d' /etc/bootparams
}
For example, this will remove my_target's entry:
# bootprm my_target
Posted at 06:52PM Nov 18, 2005 by Andrew Rutz in Solaris | Comments[0]