Sun Update Connection - Enterprise 1.0 User's Guide

Restoring Managed Hosts

ProcedureTo Roll Back an Inventory

After you run a job and decide that the changes are not what you need, you can roll back the component inventory of a managed host to a previously saved inventory. Inventories are saved automatically before job changes, and you can save an inventory on demand (see Saving Inventories).

  1. Make sure the Inventory panel is open in the main window by choosing Inventory from the View menu.

  2. Do one of the following:

    • From the tool bar, click the Compare Inventories button.

    • Right-click in the Hosts list and choose Compare Inventories.

    • From the Hosts menu, choose Compare Inventories.

    The Inventory Comparison window opens.

  3. Click the Host Select button to the right of the Target host field.

    The Host Selection window opens.

  4. Select the host you want to restore and then click OK.

    The Host Selection window closes. The selected host name appears in the Target host field.

  5. From the Inventory drop-down list, select Current Inventory.

  6. Click the Host Select button to the right of the Source field.

    The Host Selection window opens.

  7. Select the same managed host you want to restore and then click OK.

    The Host Selection window closes. The selected host name appears in the Source field.

  8. From the Inventory drop-down list, select the optimal stored inventory of the host or of a group to which the host belongs.

  9. Filter the inventories for the type that you want to restore, or select all the inventory options.


    Note –

    If the hosts are Solaris machines, you can rollback only Software or only Patches at one time.


  10. Click Compare.

    Check the results of the inventory comparison. If the differences between the inventories can be converted to component management tasks, the Make Target like Source button is enabled.

  11. Click Make Target like Source.

    The Run Job window opens.

  12. In the Run Job window, select Deploy and then click OK.

    The restore job begins.

    If you are a user with restricted permissions to run only simulation jobs, you do not have this option.)


Example 8–4 Restoring a Host with the CLI

The CLI command submit compare job can clone the inventory (or part of it) from one host or saved inventory to another host. It can also restore a host to a previously saved inventory. This example shows a restore inventory job. See Submit Compare Job (-scj) Command.


#! /bin/bash

echo -n “Enter your user name:” 
read user 
echo -n “Enter your password:” 
read password 

echo “What distribution are you working on?” 
uce_cli -ld -u “$user” -p “$password” 
echo -n “Copy the distribution name you want:” 
read distroGroup 
echo “The list of hosts in this distribution is:” 
uce_cli -lgh -g “$distroGroup hosts” -u “$user” -p “$password” 
echo -n “Copy the name of the host to restore:” 
read host 

echo “The list of saved inventories is:” 
uce_cli -lss -g “$distroGroup hosts” -u “$user” -p “$password” 
echo -n “Copy the name of the inventory to which $host is be restored:” 
read sourceInven 

uce_cli -scj -h “$host” -s “$sourceInven” -t “$host” -j “Restore $host” -C “Always ask me” \
-dp -u “$user” -p “$password”