Solaris Live Upgrade 2.0 Guide

Upgrading With Solaris Live Upgrade

This chapter explains how to use Solaris Live Upgrade to upgrade and activate an inactive boot environment. It also explains how to recover from an activation failure. This chapter contains the following sections:

You can use Solaris Live Upgrade with menus or by using the command line interface (CLI). Procedures are documented for both interfaces. These procedures do not exhaust the possibilities for using Solaris Live Upgrade. For more information regarding commands, see Chapter 6, Solaris Live Upgrade Reference for commands and the appropriate man pages, which more fully document the CLI.

Task Map: Upgrading a Boot Environment

Table 4–1 Task Map: Upgrading With Solaris Live Upgrade

Task  

Description 

For Instructions, Go To 

Either upgrade a boot environment or install a Web Start Flash archive 

 

  • Upgrade the inactive boot environment with an operating environment image

  • Install a Web Start Flash archive on an inactive boot environment

Activate an inactive boot environment 

Makes changes effective and switches the inactive boot environment to active 

Activating a Boot Environment

(optional) Switch back in case of a failure when activating 

Reactivates to the original boot environment if a failure occurs 

Failure Recovery: Falling Back to the Original Boot Environment (Command-Line Interface)

Upgrading a Boot Environment

Use the Upgrade menu or luupgrade command to upgrade a boot environment. This section provides the procedure for upgrading an inactive boot environment from files that are located on the following:

When you upgrade a boot environment with the latest operating environment, you do not affect the active boot environment. The new files merge with the inactive boot environment critical file systems, but shareable file systems are not changed.

Rather than upgrading, if you have created a Web Start Flash archive, you could install the archive onto an inactive boot environment. See Installing Web Start Flash Archives on a Boot Environment.

To Upgrade an Operating System Image on a Boot Environment (Character Interface)

For the following procedure, you must use a combined installation image or one CD. If the installation requires more than one CD, you must use the command line interface procedure for upgrading. See To Upgrade an Operating System Image From Multiple CDs (Command-Line Interface).

  1. From the Solaris Live Upgrade main menu, select Upgrade.

    The Upgrade menu screen is displayed.

  2. Type the new boot environment's name.

  3. Type the path to where the Solaris installation image is located.

    Installation Media Type 

    Description 

    Network file system 

    Specify the path to the network file system where the installation image is located.  

    Local file 

    Specify the path to the local file system where the installation image is located. 

    Local tape 

    Specify the local tape device and the position on the tape where the installation image is located. 

    Local device or CD 

    Specify the local device and the path to the installation image. 

    • If you have one CD, type the path to that CD as in this example:


      Package Media: /cdrom/solaris8/s0
      
    • If you have a combined image on the network, type the path to the network file system as in this example:


      Package Media: /net/installmachine/export/solaris8/os_image
      
  4. To upgrade, press F3.

    When the upgrade is completed, the main menu is displayed.

To Upgrade an Operating System Image on a Boot Environment (Command-Line Interface)

For the following procedure, you must use a combined installation image or just one CD. If the installation requires more than one CD, you must use the command line interface procedure for upgrading. See To Upgrade an Operating System Image From Multiple CDs (Command-Line Interface).

  1. Log in as superuser.

  2. Indicate the boot environment to upgrade and the path to the installation software by typing:


    # luupgrade -u -n BE_name -s os_image_path 
    

    -u

    Indicates the upgrade OS function 

    -n BE_name

    Specifies the name of the boot environment that is to be upgraded 

    -s os_image_path

    Specifies the path name of a directory that contains an operating system image 


    Example 4–1 Upgrading an Operating System Image on a Boot Environment (Command-Line Interface)

    In this example, the second_disk boot environment is upgraded by using a path from the network to a combined installation image.


    # luupgrade -u -n second_disk \
    -s /net/installmachine/export/solarisX/OS_image 
    

To Upgrade an Operating System Image From Multiple CDs (Command-Line Interface)

If the operating system image resides on two or more CDs, use this upgrade procedure.

  1. Log in as superuser.

  2. Indicate the boot environment to upgrade and the path to the installation software by typing:


    # luupgrade -u -n BE_name -s os_image_path 
    

    -u

    Indicates to install an OS image 

    -n BE_name

    Specifies the name of the boot environment that is to be upgraded 

    -s os_image_path

    Specifies the path name of a directory containing an operating system image 


    Example 4–2 Upgrading an Operating System Image From Multiple CDs (Command-Line Interface)

    In this example, the second_disk boot environment is upgraded and the installation image is on the first CD.


    # luupgrade -u -n second_disk -s /dev/cdrom/cdrom0 
    

  3. When the installer is finished with the contents of the first CD, insert the second CD.

  4. This step is identical to the previous example, but the -u option is replaced by the -i option. Also, choose to run the installer on the second CD with menus or in text mode.

    • This command run the installer on the second CD with menus.


      # luupgrade -i -n BE_name -s os_image_path 
      
    • This command runs the installer on the second CD in text mode.


      # luupgrade -i -n BE_name -s os_image_path -O -nodisplay 
      

    -i

    Looks for an installation program on the specified medium and runs that program. The installer program is specified with -s.

    -n BE_name

    Specifies the name of the boot environment that is to be upgraded 

    -s os_image_path

    Specifies the path name of a directory that contains an operating system image 

    -O -nodisplay

    (Optional)Runs the installer on the second CD in text mode 


    Example 4–3 Upgrading an Operating System Image From Multiple CDs (Command-Line Interface)

    In this example, the upgrade on second_disk boot environment is completed with the second CD and the installer on the second CD is run with menus.


    # luupgrade -i -n second_disk -s /dev/cdrom/cdrom0 
    

    If you have more CDs, repeat this step.

    The boot environment is ready to be activated. See Activating a Boot Environment .

Installing Web Start Flash Archives on a Boot Environment

This section provides the procedure for using Solaris Live Upgrade to install Web Start Flash archives that are stored on the following:

Installing a Web Start Flash archive overwrites all files on the new boot environment, except for shared files.

To use the Web Start Flash installation feature, you need to have installed the master system and created the Web Start Flash archive. For more information about Web Start Flash, see “Web Start Flash Installation Feature Topics” in Solaris 8 Advanced Installation Guide.

To Install Web Start Flash Archives on a Boot Environment (Character Interface)

  1. From the Solaris Live Upgrade main menu, select Flash.

    The Flash an Inactive Boot Environment menu is displayed.

  2. Type the name of the boot environment where you want to install the Web Start Flash archive and the location of the installation media:


    Name of Boot Environment: solaris_8
    Package media: /net/install-svr/export/s8/latest
    
  3. Press F1 to add an archive.

    An Archive Selection submenu displays an empty list, the name of a single archive, or a list of a number of archives. If more than one archive is listed, you have layered archives. For an explanation of layered archives, see “Web Start Flash Overview and Planning” in Solaris 8 Advanced Installation Guide.

    You can add and remove archives from the list. The following example shows an empty list.


    Location            - Retrieval Method
    <No Archives added> - Select ADD to add archives
    • To install the list with no changes, proceed to Step 4.

    • If the Web Start Flash archives list is empty or contains an archive that you do not want to install, proceed to Step a.

    1. You can add or remove archives.

    2. On the Select Retrieval Method menu, select the location of the Web Start Flash archive.

      Media Selected 

      Prompt 

      HTTP 

      Specify the URL and proxy information that is needed to access the Web Start Flash archive. 

      NFS 

      Specify the path to the network file system where the Web Start Flash archive is located. You can also specify the archive file name. 

      Local file 

      Specify the path to the local file system where the Web Start Flash archive is located. 

      Local tape 

      Specify the local tape device and the position on the tape where the Web Start Flash archive is located. 

      Local device 

      Specify the local device, the path to the Web Start Flash archive, and the type of file system on which the Web Start Flash archive is located.  

      A Retrieval submenu is displayed similar to the following example, which depends on the media you selected.


      NFS Location: 
    3. Type the path to the archive as in the following example.


      NFS Location: host:/path/to archive.flar
      
    4. Press F3 to add the archive to the list.

    5. When the list contains the archives you want to install, press F6 to exit.

  4. Press F3 to install the archive or layered archives.

    The Web Start Flash archive or layered archives are installed on the boot environment. All files on the boot environment are overwritten, except for shareable files.

    The boot environment is ready for activation. See Activating a Boot Environment .

To Install Web Start Flash Archives on a Boot Environment (Command-Line Interface)

  1. Log in as superuser.

  2. Type:


    # luupgrade -f -n BE_name -s os_image_path -J "profile"
    

    You must specify one of these options: -a, -j, or -J.

    -f

    Indicates to upgrade an operating system from a flash archive. 

    -n BE_name

    Specifies the name of the boot environment that is to be upgraded. 

    -s os_image_path

    Specifies the path name of a directory that contains an operating system image. This can be a directory on an installation medium, such as a CD-ROM, or can be an NFS or UFS directory. 

    -Jprofile

    Entry from a JumpStart profile that is configured for a flash installation. See pfinstall(1M) and “Custom JumpStart Installation Topics” in Solaris 8 Advanced Installation Guide for information on the JumpStart software. You must specify one of -a, -j, or -J.

    -j profile_path

    Path to a JumpStart profile that is configured for a flash installation. See pfinstall(1M) and “Custom JumpStart Installation Topics” in Solaris 8 Advanced Installation Guide for information on the JumpStart software. You must specify one of -a, -j, or -J.

    -a archive

    Path to the flash archive when the archive is available on the local file system. You must specify one of -a, -j, or -J.


    Example 4–4 Installing Web Start Flash Archives on a Boot Environment (Command-Line Interface)

    In this example, a flash archive is installed on the second_disk boot environment. The -J option is used to retrieve the archives. All files are overwritten on second_disk except shareable files.


    # luupgrade -f -n second_disk \
    -s /net/installmachine/export/solarisX/OS_image \
    -J "archive_location http://example.com/myflash.flar" 
    

Activating a Boot Environment

Activating a boot environment makes it bootable on the next reboot of the system. You can also switch back quickly to the original boot environment if a failure occurs on booting the newly active boot environment. See SPARC: To Fall Back to the Original Boot Environment.

To successfully activate a boot environment, that boot environment must meet the following conditions:


Note –

If you want to reconfigure swap, make this change prior to booting the inactive boot environment. By default, all boot environments share the same swap devices. To reconfigure swap, see “Creating a New Boot Environment,” Step 9 or To Create a Boot Environment and Reconfigure Swap (Command-Line Interface).


x86: (Optional) Update Boot Diskette Before Activating

If you're not using the Solaris 8 Device Configuration Assistant Intel Platform Edition diskette to boot the system, you can skip this procedure. If you use the Device Configuration Assistant to boot, you need to update the boot diskette. This procedure matches a boot diskette to your release by overwriting the existing diskette or writing to a new one.

  1. Insert the diskette. This is either the existing diskette that is overwirtten or a new diskette.

  2. Update the boot diskette with the latest image for this release.

  3. Eject the boot diskette.

  4. Type:


    volcheck
    
  5. Copy the new boot environment's boot/solaris/bootenv.rc file to the diskette.


    cp /a/boot/solaris/bootenv.rc /floppy/floppy0/solaris/bootenv.rc
    
  6. Check the input-device and output-device on the diskette to make sure they are correct. If not then update them.

    You are ready to activate the new boot environment.

To Activate a Boot Environment (Character Interface)

  1. From the Solaris Live Upgrade main menu, select Activate.

  2. Type the name of the boot environment to make active:


    Name of Boot Environment: solaris_8
    Do you want to force a Live Upgrade sync operations: no
  3. You can either continue or synchronize files.

    • Press Return to continue.

      No file synchronization is done.

    • If it has been some time since you created the inactive boot environment, you might want to synchronize files. To synchronize files, type:


      Do you want to force a Live Upgrade sync operations: yes
      
  4. Press F3 to begin the activation process.

  5. Press Return to continue.

    The new boot environment is activated at the next reboot.

  6. To activate the inactive boot environment, reboot:


    # init 6
    

To Activate a Boot Environment (Command-Line Interface)

  1. Log in as superuser.

  2. (Optional) To check on which boot environment is activated on the next reboot, type:


    # /usr/sbin/luactivate 
    
  3. To activate the boot environment, type:


    # /usr/sbin/luactivate  BE_name
    

    BE_name

    Specifies the name of the boot environment that is to be activated. 


    Example 4–5 Activating a Boot Environment (Command-Line Interface)

    In this example, the second_disk boot environment is activated at the next reboot.


    # /usr/sbin/luactivate second_disk
    

  4. Reboot.


    # init 6
    

To Activate a Boot Environment and Synchronize Files (Command-Line Interface)

The first time you boot from a newly created boot environment, Live Upgrade software synchronizes this boot environment with the boot environment that was last active. (This is not necessarily the boot environment that was the source for the newly created boot environment.) It does not perform this synchronization after this initial boot, unless you use the -s option. Use this option with great caution, because you might not be aware or in control of changes that might have occurred in the last active boot environment.

  1. Log in as superuser.

  2. (Optional) To check on which boot environment is activated on the next reboot, type:


    # /usr/sbin/luactivate 
    
  3. To activate the boot environment, type:


    # /usr/sbin/luactivate  -s BE_name
    

    BE_name

    Specifies the name of the boot environment that is to be activated. 

    -s

    Forced synchronization.  


    Example 4–6 Activating a Boot Environment (Command-Line Interface)

    In this example, the second_disk boot environment is activated at the next reboot and the files are synchronized.


    # /usr/sbin/luactivate -s second_disk
    

  4. Reboot.


    # init 6
    

Failure Recovery: Falling Back to the Original Boot Environment (Command-Line Interface)

If a failure is detected after upgrading or if the application is not compatible with an upgraded component, fall back to the original boot environment by using one of the following procedures, depending on your platform. For SPARC based systems, the first procedure runs luactivate to switch back to the original boot environment. If the first procedure fails, use the second procedure to boot from a CD-ROM or a net image. For IA based systems, choose the procedure that is based on where the root (/) file systems are mounted, on the same or different physical disks.

SPARC: To Fall Back to the Original Boot Environment

If you experience a failure while booting the new boot environment, use this procedure to fall back to the original boot environment.

  1. Log in as superuser.

  2. Type:


    # /sbin/luactivate
    
  3. At the prompt, type:


    Do you want to fallback to activate boot environment <disk name> 
    (yes or no)? yes
    

    A message displays that the fallback activation is successful.

SPARC: To Fall Back to the Original Boot Environment by Using a CD or Net Image

If you were unsuccessful at using luactivate in the previous procedure, use this procedure to boot from a CD or a net image. You need to mount the root (/) slice from the last active boot environment. Then run the luactivate command, which makes the switch. When you reboot, the last active boot environment is up and running again.

  1. At the OK prompt, boot the machine to single-user state from the installation CD, the network, or a local disk:


    OK boot cdrom -s 
    

    or


    OK boot net -s
    

    or


    OK boot disk -s
    

    disk

    The name of the disk and the slice where a copy of the operating system resides, for example disk1:A.

  2. If necessary, check the integrity of the file system for the fallback boot environment root (/).


    # fsck mount point
    

    mount_point

    A root file system that is known and reliable

  3. Mount the active boot environment root slice to some directory (such as /mnt/sbin):


    # mount logical_device_name /mnt/sbin
    

    logical_device_name

    Any device, including a Veritas VxVM volume or Solstice DiskSuite metadevice 

  4. From the active boot environment root slice, type:


    # /mnt/sbin/luactivate
    

    luactivate activates the previous working boot environment and indicates the result.

  5. Unmount /mnt/sbin


    # umount logical_device_name /mnt/sbin
    

    logical_device_name

    Any device, including a Veritas VxVM volume or Solstice DiskSuite metadevice 

  6. Reboot.


    # init 6
    

    The previous working boot environment becomes the active boot environment.

x86: To Fall Back With Boot Environments on Different Disks

If you experience a failure while booting the new boot environment and the root (/) file systems for the boot environments are on different physical disks, use the following procedure to fall back to the original boot environment.

  1. Reboot the machine and enter the appropriate BIOS menus.

    • If your boot devices are SCSI, refer to documentation on your SCSI controller on how to enter the SCSI BIOS.

    • If the boot devices are maintained by the system BIOS, refer to system BIOS documentation on how to enter the system BIOS.

  2. Follow the appropriate BIOS documentation to change the boot device back to the original boot environment's boot device.

  3. Save the BIOS changes.

  4. Exit BIOS to begin the boot process.

  5. At the OK prompt, boot the machine to single-user state.


    OK b -s
    
  6. Type:


    # /sbin/luactivate
    
  7. Reboot.


    # init 6
    

x86: To Fall Back With Boot Environments on the Same Disk

If you experience a failure while booting and the root (/) file systems are on the same physical disk, use the following procedure to fall back to the original boot environment. You need to mount the root (/) slice from the last active boot environment. Then run the luactivate command, which makes the switch. When you reboot, the last active boot environment is up and running again.

  1. Decide how to boot the system:

    • Access the Solaris Device Configuration Assistant from the Solaris 8 Installation CD, Solaris 8 Software 1 of 2 CD, or from a net image of the CD. Your system's BIOS must support booting from a CD.

    • Insert the Solaris 8 Device Configuration Assistant Intel Platform Edition diskette. The boot diskette software can be downloaded and copied to a diskette from the Solaris Developer Connection at: soldc.sun.com/support/dirvers/dca_diskettes.

    • Access the Solaris Device Configuration Assistant from the network using Pre-boot eXecution Environment (PXE). PXE enables you to boot a system directly from the network without using the boot diskette. The system must support PXE. Enable the system to use PXE by using the systems's BIOS setup tool or the network adapter's configuration setup Tool.

    Follow the directions on screen until the Current Boot Parameters menu is displayed.

  2. At the OK prompt, boot the machine to single-user state.


    OK b -s
    
  3. If necessary, check the integrity of the file system for the fallback boot environment root (/).


    # fsck mount point
    

    mount_point

    A root file system that is known and reliable

  4. Mount the active boot environment root slice to some directory (such as /mnt/sbin):


    # mount logical_device_name /mnt/sbin
    

    logical_device_name

    Any device, including a Veritas VxVM volume or Solstice DiskSuite metadevice 

  5. From the active boot environment root slice, type:


    # /mnt/sbin/luactivate
    

    luactivate activates the previous working boot environment and indicates the result.

  6. Unmount /mnt/sbin.


    # umount logical_device_name /mnt/sbin
    

    logical_device_name

    Any device, including a Veritas VxVM volume or Solstice DiskSuite metadevice 

  7. Reboot.


    # init 6
    

    The previous working boot environment becomes the active boot environment.