Overview of Oracle Solaris 10 Boot Environments

Boot environments in Oracle Solaris 10 are managed through the Live Upgrade feature. A boot environment is created by using a script that contains the lucreate command and options.

The Live Upgrade feature is available on the following operating systems:

  • Oracle Solaris 10 OS for x86 platform versions through Oracle Solaris 10 5/09: Update alternate boot environments for physical systems.

  • Oracle Solaris 10 OS for SPARC through Oracle Solaris 10 5/09: Update alternate boot environments for physical and virtual machines, including Oracle Solaris Zones and Oracle VM Server for SPARC (formerly known as Logical Domains).

Note:

Do not use Oracle Solaris Live Upgrade on your Enterprise Controller or Proxy Controllers. It does not synchronize all of the files that are required for these Oracle Enterprise Manager Ops Center components.

To create and update alternate boot environments, install the latest Oracle Solaris Live Upgrade packages and patches. This ensures that you have all the latest bug fixes and features. In addition, verify that the disk space and format are sufficient for an alternate boot environment.

Live Upgrade packages and patches are available for each Oracle Solaris software release beginning with Oracle Solaris 10 OS. Use the packages and patches that are appropriate for your software instance.

If you installed Oracle Solaris 10 using any of the following software groups, have the required packages:

  • Entire Oracle Solaris Software Group Plus OEM Support

  • Entire Oracle Solaris Software Group

  • Developer Oracle Solaris Software Group

  • End User Oracle Solaris Software Group

When you install one of these Software Groups, verify that you have all of the required packages:

  • Core System Support Software Group

  • Reduced Network Support Software Group

For detailed requirements to install and use the Live Upgrade feature, see Oracle Solaris 10 Installation Guide: Solaris Live Upgrade and Upgrade Planning at http://docs.oracle.com/cd/E18752_01/html/821-1910/preconfig-17.html. For information on other releases, see Operating Systems Documentation at http://docs.oracle.com/en/operating-systems/. Review and verify that all the packages and patches that are relevant to your system are installed and that the disk is formatted properly before creating a new boot environment.

For Oracle Solaris 10 alternate boot environments, file systems are categorized into the following types:

  • Critical File Systems: Non-sharable file systems that are required by the Oracle Solaris OS, such as root (/), /usr, /var, and /opt. These file systems are separate mount points in the vfstab of the active and inactive boot environments and are always copied from the source to the inactive boot environment.

  • Sharable File Systems: User-defined files, such as /export, that contain the same mount point in the vfstab in both the active and inactive boot environments. Updating shared files in the active boot environment also updates data in the inactive boot environment. When you create a boot environment, sharable file systems are shared by default. If you specify a destination slice, also known as a partition, the file systems are copied.

  • Swap: Depends on the type of file system:

    • For UFS file systems, swap is a special sharable volume. Like a sharable file system, all swap slices are shared by default. If you specify a destination directory for swap, the swap slice is copied.

    • For ZFS file systems, swap and dump volumes are shared within the pool.

When creating a new boot environment in Oracle Solaris 10, the entire contents of a slice is copied to the designated new boot environment slice. You might want some large file systems on that slice to be shared between boot environments rather than copied to conserve space and copying time. File systems that are critical to the OS such as root (/) and /var must be copied. File systems such as /home are not critical file systems and could be shared between boot environments. Sharable file systems must be user-defined file systems and on separate swap slices on both the active and new boot environments. You can reconfigure the disk several ways, depending your needs.

You can reslice, or partition, the disk before creating the new boot environment and put the sharable file system on its own slice. For example, if the root (/) file systems, /var, and /home are on the same slice, reconfigure the disk and put /home on its own slice. When you create any new boot environments, /home is shared with the new boot environment by default. To share a directory, the directory must be split off to its own slice.

Requirements for Oracle Solaris 10 Live Upgrade and Oracle Solaris Zones

Lists the requirements for Oracle Solaris 10 live upgrade and Oracle Solaris zones.

The following requirements are needed to use the Live Upgrade feature with zones:

  • Agent managed operating system

  • At least Oracle Solaris 10 5/09 (update 7) operating system

  • Storage library used to house the zones cannot be part of the root pool; you must create a separate pool on a shared file system

  • You cannot use the -p option to create alternate boot environments

The -p option, which copies between two root pools on ZFS configuration, is not supported with the lucreate command.

Note:

If you plan to use alternate boot environments with zones, you must designate sufficient zone storage space. When you create the zones and configure the zone storage, specify twice the size of the zone file system for the root file system of the zone. For example if your zone root file system was configured as 8 GB, the storage used to back up the zone must be at least 16 GB.

Displaying Boot Environment Details for Oracle Solaris 10

The Oracle Solaris 10 Boot Environments tab provides you with a large amount of information about the boot environments that are associated with the selected Oracle Solaris operating system.

Boot Environments tab is not available for Oracle Solaris 10 non-global zones. The following information is available:

  • Displaying Total ZPools Utilization for Oracle Solaris 10 and Earlier Boot Environments

  • Displaying Oracle Solaris 11 Boot Environments

  • Displaying File Systems for Oracle Solaris 10 and Earlier Boot Environments

Displaying Total ZPools Utilization for Oracle Solaris 10 and Earlier Boot Environments

The first section in the Boot Environments tab is Total ZPools Utilization. It is compressed by default, use the arrow to expand the table.

The amount of resources used by the zpool appears in this section, as shown in Figure 6-23.

Figure 6-23 Oracle Solaris 10 and Earlier Total ZPools Utilization

Description of Figure 6-23 follows
Description of "Figure 6-23 Oracle Solaris 10 and Earlier Total ZPools Utilization"

Displaying Boot Environments for Oracle Solaris 10 and Earlier

All boot environments that are associated with the physical or virtual operating system that is selected in the Assets tree appear in the Boot Environments table.

As shown in Figure 6-24, the active status, size, description, and when the boot environment was created or synchronized appear in this section. A green check mark icon next to the boot environment name identifies the boot environment as active. A green check mark with a green circle and white x indicates that this is the boot environment that is active upon reboot. When you see two green check marks in the Active column, the boot environment is active and is the active boot environment upon reboot.

Figure 6-24 Boot Environments for Oracle Solaris 10 and Earlier

Description of Figure 6-24 follows
Description of "Figure 6-24 Boot Environments for Oracle Solaris 10 and Earlier"

The lower section of the page the File Systems tab that provide details about the boot environment that you select in the Boot Environments table.

Displaying File Systems for Oracle Solaris 10 and Earlier Boot Environments

The File Systems tab provides file system details for the boot environment, or alternate boot environment, that you select in the Boot Environments tab.

As shown in Figure 6-25, the file system name, type, size and mount location appear in this table. You can also see if the file system is shared or not.

Figure 6-25 Oracle Solaris 10 Boot Environments File Systems

Description of Figure 6-25 follows
Description of "Figure 6-25 Oracle Solaris 10 Boot Environments File Systems"

About Boot Environment Profiles and Plans for Oracle Solaris 10 and Earlier

You can use an alternate boot environment that was created outside of Oracle Enterprise Manager Ops Center; however, the preferred method is to create a Boot Environment profile and use the associated plan to create a boot environment. In either case, the operating system must be an agent-managed asset in the Oracle Enterprise Manager Ops Center software.

Use the profile for Oracle Solaris 10 and earlier releases to perform the following tasks:

  1. Create a Boot Environments profile to specify how to create boot environments across all your managed system, using lucreate scripts

  2. Create your boot environments using the action in the action panel for your assets. This is typically a one time operation, as you'll probably reuse the alternate boot environment.

  3. Create a Boot Environments profile to always sync (and possibly) activate. Use this profile for OS update deployment plans.

  4. Create an OS update deployment plan specifying the boot environment in step 3 and any OS update profile

Depending on the Oracle Solaris version that you are using, several methods are available for creating alternate boot environments. The Oracle Enterprise Manager Ops Center software uses Boot Environments profiles to help standardize and simplify the process.

Perform the following tasks before creating a Boot Environments profile:

  1. Determining Your Boot Environment Policy

  2. Determining Your Live Upgrade Feature Requirements and Options

Determining Your Boot Environment Policy

Each Boot Environment profile can have a different boot environment policy.

The following options are available for Oracle Solaris 10:

  • Activate Boot Environment and reboot on job completion.

  • Synchronize existing Boot Environment before submitting a job.

Determining Your Live Upgrade Feature Requirements and Options

You can create an operational plan that includes your script, or you can enter the lucreate options directly in the Boot Environments profile without creating a script.

For Oracle Solaris 10 only, determine the file system and swap requirements and the lucreate command options that you want to use. If you are using ZFS, create a zpool. See the Oracle Solaris documentation for more information about the requirements and command options for the Live Upgrade feature.

Overview of Boot Environments Profiles and Plans

The profile identifies and defines how the boot environment is created and activated, including defining the target type, the options used to create the boot environment, and the activation parameters.

The following is a high-level overview of how to create an alternate boot environment for Oracle Solaris 10 and earlier releases.

  1. Create a Boot Environments profile.

    Review the Oracle Solaris 10 Live Upgrade documentation for more details on the requirements:

    • Define your file system and swap requirements.

    • Determine the lucreate command options. You can enter the options in the Boot Environments profile, or you can create an operational profile that contains a script with the lucreate command and options. If you are specifying a variable boot environment name in the script passed to the operational profile, make sure the variable is called BEName. When you use BEName as the variable name, the operational plan passes on the BE name entered during plan execution to the lucreate script.

    • Determine your boot environment policies.

  2. Create a deployment plan.

    The Boot Environment deployment plan defines the failure policy and is associated with a single Boot Environments profile. You can add a Boot Environments profile as a task, or step, within a complex deployment plan. See Plan Management for information about complex plans.

  3. Execute the deployment plan.

    After the deployment plans are created, a user with the appropriate role and privileges can choose from a list of plans to quickly and consistently create an alternate boot environment.

  4. Create and deploy an OS Update plan to update the inactive boot environment.

For information about system administration tasks such as managing file systems, mounting, booting, and managing swap space, see the <Oracle Solaris System Administration Guide: Devices and File Systems> in the Oracle Solaris 10 Documentation Library.

Creating an Oracle Solaris 10 Boot Environment

Oracle Solaris Live Upgrade scripts are used to create an alternate boot environment. To create a replica of your boot environment, run the script in Oracle Enterprise Manager Ops Center.

The following methods are available to create the alternate boot environment:

  • Copy an existing boot environment.

  • Execute a Boot Environments deployment plan.

    The deployment plan must reference an Boot Environments profile.

  • Run an operational plan that contains the lucreate script.

  • Upload an Oracle Solaris Live Upgrade script as Local Content in Enterprise Manager Ops Center.

    • Run an OS update job and specify a pre-action which runs the script. You can select multiple compatible targets and create an alternate boot environment for each target using the same script at the same time.

    • Create an OS profile, and then run an OS Update job. The profile enables you to define the components and the actions to be performed every time you use the profile to create an alternate boot environment.

  • Run an Oracle Solaris Live Upgrade script from the command-line interface. With this method, you must login to each agent and then run the script to create the boot environment.

When you create the alternate boot environment with an OS Update job, you can choose to run the job immediately, or you can schedule the job to run during your maintenance window. In all methods, the new boot environment is automatically discovered and a new Boot Environments tab appears in the center pane for OS management.

This task describes how to run a New OS Update job to create the alternate boot environment. Although it is a New OS Update job, the sole purpose of the job is to create an alternate boot environment. The job uses the Live Upgrade script that you uploaded to Local Content to create a duplicate of your boot environment.

Defining Deployment Options for Oracle Solaris 10

To create boot environments for Oracle Solaris 10, you can define the options in an Boot Environments profile or you can add a script to an operational profile. The software enables you to store the scripts and parameters and provides a couple of methods of deploying the scripts.

  • As a profile

  • As part of a plan

  • As part of an update job

The scripts use the lucreate command to create an alternate boot environment. For a complete list of options, see the Oracle Solaris 10 OS Live Upgrade lucreate (1M) documentation. The following are some commonly used options:

  • -m option to create a boot environment and split a directory off to its own slice.

    To share a directory, the directory must be split off to its own slice. The directory is then a file system that can be shared with another boot environment. You can use the lucreate command with the -m option to create a boot environment and split a directory off to its own slice. But, the new file system cannot yet be shared with the original boot environment. You must run the lucreate command with the -m option again to create another boot environment. The two new boot environments can then share the directory.

  • -s option to force a synchronization.

  • -p specifies the ZFS pool in which a new boot environment resides.

    The -p is not required when the source and target boot environments are within the same pool. The -p option does not support the splitting and merging of file systems in a target boot environment, instead use the -m option.

Existing boot environments appear in the hierarchy in the Boot Environments tab for a global zone. You can create the boot environment with Oracle Enterprise Manager Ops Center or outside of the software.

Creating an Oracle Solaris 10 Boot Environment From a Deployment Plan

You can only create a boot environment from a global zone in Oracle Solaris 10. The boot environments on Oracle Solaris non-global zones are tightly coupled with the corresponding boot environment on the global zone and cannot be managed independently.

You can use either of the following deployment plans to create an Oracle Solaris 10 boot environment:

  • Boot Environment: A simple deployment plan that only creates an alternate boot environment. Use the default alternate boot environment profile and then override the applicable parameters to create a boot environment.

  • Software Deployment / Update: A multi-step plan where one of the steps creates a boot environment. See the Oracle Enterprise Manager Ops Center Updating Your Oracle Solaris 10 Operating System for an example of how to use this plan.

Creating a Boot Environment Using Alternate Boot Environment Profile

Perform the following steps to create a boot environment using the Alternate Boot Environment profile and Boot Environment deployment plan:

  1. Click an Oracle Solaris 10 OS global zone in the Assets tree to view the Boot Environment in the center pane.

  2. Click the Boot Environment tab.

    Existing boot environments for the OS appear in the center pane.

  3. To create a copy, or clone, of the existing active boot environment, click the Create icon.

  4. Enter a unique name for the boot environment and provide a description. The text describes what the boot environment and from what source it was created. Edit the applicable parameters in the Alternate Boot Environment profile, then click Confirm.

  5. When the job finishes, refresh the Boot Environment table to see the new boot environment.

Creating an Oracle Solaris 10 Boot Environment from an Operational Plan

An operational profile contains a single script and can define variables. The associated plan launches the profile. An operational plan is associated with a specific version of an operational profile. By default, creating a profile also creates an operational plan.

You can create the boot environments using this script from a few different contexts:

  • Simple BE Operational profile

  • Boot Environments profile using BE Operational profile from the plan context

  • Create Boot Environment from the asset context

You can save a shell script on the Enterprise Controller and download it into the plan, or you can enter the script in a field when you create the plan. Both types of shell scripts are executed by the user. They differ in the location, either on the Enterprise Controller or on the remote Agent Controller, and the user credentials needed to execute the profile.

  1. Click Plan Management in the Navigation pane, then click Operational Profiles. The Operational Profiles appear in the center pane.
  2. Click Create Operational Profile. The Create Profile - Operation page appears.
  3. Enter a name for the new plan and a description of its purpose or role.
  4. Select an asset type from the Subtype list.
  5. Click Next.
  6. Select the Operation Type from the drop-down menu, either EC Shell or Remote Shell.
    • If you select EC Shell, browse to the location of the script in the Script File field, then click Load Script.

    • If you select Remote Shell, enter your script in the Script field.

  7. Enter a numeric value in the Timeout field, then select Minutes or Seconds. The default timeout is 60 minutes.
  8. (Optional) Click View System Variables to view the default variables.
  9. Click Next.
  10. (Optional) Specify Additional Variables. You can specify any variable you want. For example, add Alarm_ID$ to add the incident identifier number for easier incident management.

Creating an Update Profile for Oracle Solaris 10 Boot Environment

You can use an Update profile to create and update a boot environment.

Perform the following steps to create an update profile for Oracle Solaris 10 boot environment:

  1. Expand Plan Management, then click Update Profiles in the Navigation pane.
  2. Click New Profile in the Actions pane.
  3. Enter a name and description for the profile.
  4. Select Script from the Type drop-down menu.
  5. Select an OS channel from the Distribution drop-down menu.
  6. Select Local from the Category drop-down menu.
  7. Choose the options that you want from the View and the Version drop-down menus.
  8. Highlight Local RPMs in the Available Packages / Patches table, select the Apply to all applicable distributions check box.
  9. Click Profile Contents and select an item, then click Create OS Update Profile.

Creating an Oracle Solaris 10 Boot Environment From an Update Profile

You can use an Update profile to create and update a boot environment.

  1. Click an Oracle Solaris 10 OS global zone in the Assets tree to view the Boot Environment in the center pane.
  2. Click the Boot Environment tab.

    Existing boot environments for the OS appear in the center pane.

  3. To create a copy, or clone, of the existing active boot environment, click the Create icon.

    The plan for execution that uses the default Boot Environments profile for Oracle Solaris 10 appears.

  4. Enter a unique name for the boot environment and provide a description. The text describes what the boot environment and from what source it was created. Edit the applicable parameters in the Alternate Boot Environment profile, then click Confirm.
  5. When the job finishes, refresh the Boot Environment table to see the new boot environment.

Creating an Oracle Solaris 10 Boot Environment With an OS Update Job

Oracle Solaris Live Upgrade contains a suite of script commands. To create an alternate boot environment with Enterprise Manager Ops Center, use the lucreate command to write one or more Oracle Solaris Live Upgrade scripts, add the scripts to the Local Content library in Enterprise Manager Ops Center, then run an OS Update job and select the ABE options.

When you use Enterprise Manager Ops Center to create the alternate boot environment, the scripts must meet the following requirements:

  • The script cannot contain parameters.

  • The alternate boot environment name must be hard-coded into the script itself or otherwise be provided outside of Enterprise Manager Ops Center.

  • The alternate boot environment name defined in the script must match the alternate boot environment name that you use when you run the update job to create the alternate boot environment.

  • The script must return 0 on success and non-zero on failure.

For detailed instructions and examples for using the lucreate command to create a boot environment, see Oracle Solaris 10 9/10 Installation Guide: Solaris Live Upgrade and Upgrade Planning available at: http://www.oracle.com/technetwork/indexes/documentation/index.html

  1. Expand Libraries in the Navigation pane.
  2. Click Local Content in the Solaris/Linux OS Updates library.
  3. Click Upload Local Action in the Actions pane.
  4. Enter a name for the file.
  5. Enter a brief description of the purpose of the action.
  6. In the Action list, click the Pre-action type of action to run the script on the managed host before job tasks are carried out.
  7. Click the name of the distribution that uses the action in the Distribution list. The Parent field shows the category, based on the type of Action.
  8. Click Browse to locate and select the file.
  9. Click Upload to upload the file to the selected distribution.

Creating a Boot Environment With an OS Update Job

Procedure to create a boot environment with an OS update job.

  1. Click the OS in the Assets section of the Navigation pane.
  2. Click New Update OS Job in the Update section of the Actions pane. The New Update OS Job Wizard appears.
  3. Complete the following Job Information parameters:
    • Enter a job name.

    • Select Actual Run, which creates the alternate boot environment when you specify in Step 5.

    • Select the Sequential task execution order.

    • Select the Target Setting: Use the same Targets for all tasks in the job.

    • Select a Task Failure Policy:

      • Complete as much of the job as possible

      • Stop at failure and notify

    • Select the Boot Environment Type check box.

    • Select the Run ABE Pre-action Script check box.

  4. (Optional) To add tasks to the job, click the Add Task icon. To edit, click the Profile and Policy fields. Click Next.
  5. Enter the name of the alternate boot environment, as defined in the script. Select a script, then click Next.
  6. (Optional) Complete the Boot Environment Workflow, then click Next.
    • To synchronize the alternate boot environment with the current boot environment before mounting the alternate boot environment, select the Sync ABE check box.

    • To edit the description to describe the state of the Boot Environment, click Modify Current BE, and enter text in the Description field.

    • To edit the description to describe the state of the alternate boot environment, click Modify Alternate BE, and enter text in the Description field.

    • To switch boot environments after update, select the Activate and Reboot ABE check box.

  7. Schedule the job, then click Next.
    • Run Now: Starts the job immediately after you click Finish in the Job Summary.

    • Start Date: Select a date and time to start the job.

    • On a recurring schedule: Enables you to run the same job on a monthly or daily scheduled time.

  8. Review the Job Summary, then click Finish to run the job as scheduled in the previous step.

When the job completes, the new alternate boot environment is associated with the operating system. To verify that the alternate boot environment is created, click the operating system in the Assets pane. The Boot Environments tab appears in the center pane. Click the Boot Environments tab to display the new boot environment, as specified in the Live Upgrade script. An OS can have several associated alternate boot environments.

Note:

The Boot Environments tab only appears when at least one alternate boot environment associated with the operating system.

Synchronizing Oracle Solaris 10 Boot Environments

You can synchronize, or sync, an active Oracle Solaris 10 global zone boot environment with an inactive boot environment on the same system. Synchronizing boot environments makes the inactive boot environment the same as the currently running boot environment.

After you sync the boot environments, you can activate the inactive, or alternate, boot environment.

Activating a Boot Environment

Activating a boot environment switches a new boot environment to become the currently running boot environment when the system reboots.

  1. Click an Oracle Solaris 10 OS global zone in the Assets tree to view the Boot Environment in the center pane.
  2. Click the Boot Environment tab.

    Existing boot environments for the operating system appear in the center pane.

  3. Click Activate Boot Environment and Reboot in the Actions pane.
  4. To schedule the activation for a later date or time, select the check box. Click Next.
  5. If you selected the schedule option, complete the schedule, then click Next.
  6. Review the Summary, then click Finish.

    The new boot environment activates when you reboot the system.