Introduction
Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machine is slow.
Recently, I used the Live Upgrade tools in the Solaris OS to successfully apply the latest patch cluster to a machine running the Solaris 9 OS, without bringing the machine into single-user mode.
Preparation
Before you can do live patching, you need an extra boot disk. I used an 18 Gbyte disk for this test. Also, the following necessary packages and patch revisions need to be installed on the system:
a) Required packages for the Solaris 9 release:
SUNWadmap
SUNWlur
SUNWluu
b) Patches needed for the Solaris 9 OS of SPARC Platforms.
Procedure
The machine I'm using has a 72 Gbyte internal disk with the Solaris 9 OS installed on it.
The current partition table on the 72 Gbyte disk is:
I created /, /usr, /var, and /opt for the purpose of applying patches. However, if you want to boot up from the new disk only, every file system on the current boot disk has to move across, like swap in this case.
2) The creation of a new boot environment (s9new) is successful. Mount all file systems in the boot environment for applying patches:
# lumount s9new
The /, /usr, /var, and /opt directories will be mounted to the alternate mount points. You can confirm this from the output of the df -k command as follows:
3) Now you are ready to apply the Solaris patch cluster that you have prepared. In this case, the patches are in the /var/tmp/patches directory.
# cd /var/tmp/patches
# ./install_cluster -R /.alt.s9new
Below is the output from the command:
Patch cluster install script for Solaris 9 Recommended Patch Cluster
*WARNING* SYSTEMS WITH LIMITED DISK SPACE SHOULD *NOT* INSTALL PATCHES:
With or without using the save option, the patch installation process
will still require some amount of disk space for installation and
administrative tasks in the /, /usr, /var, or /opt partitions where
patches are typically installed. The exact amount of space will
depend on the machine's architecture, software packages already
installed, and the difference in the patched objects size. To be
safe, it is not recommended that a patch cluster be installed on a
system with less than 4 MBytes of available space in each of these
partitions. Running out of disk space during installation may result
in only partially loaded patches. Check and be sure adequate disk space
is available before continuing.
Are you ready to continue with install? [y/n]: y <---- answer yes
here if you
are ready
Use -R to specify an alternative root path (/.alt.s9new in this case), once it is done. You can find the installation messages in the following log file:
4) Now you have two boot environments (BEs), and you can check the status by the following command:
# lustatus
Below is the output from the command:
Boot Environment Is Active Active Can Copy
Name Complete Now On Reboot Delete Status
-------------------------- -------- ------ --------- ------ ----------
s9old yes yes yes no -
s9new yes no no yes -
5) Before you can switch to the new BE, you should dismount it.
# luumount s9new
6) Activate the new BE.
# luactivate -n s9new
7) Now if you check the BE status again, you can notice the difference in the Active On Reboot column:
# lustatus
Below is the output from the command:
Boot Environment Is Active Active Can Copy
Name Complete Now On Reboot Delete Status
-------------------------- -------- ------ --------- ------ ----------
s9old yes yes no no -
s9new yes no yes no -
8) Issue a reboot command and watch it boot from the alternate boot environment you created. To confirm this you could use the df -k command and make sure you are booted to the alternate boot environment with the latest patch installed.
Comments (0)