Go to main content

Installing and Configuring an Oracle® Solaris Cluster 4.4 Environment

Exit Print View

Updated: September 2019
 
 

Importing Zones into Zone Clusters

This section provides procedures on how to import installed zones into an existing zone cluster or into a new zone cluster.

You can use the import-zone command to import the zones into an existing zone cluster or a new zone cluster. The import-zone command can be run in the interactive mode as well as the non-interactive mode. For more information about the import-zone command, see the clzonecluster(8CL) man page.

Requirements and Restrictions

Consider the following points when you plan the importing of installed zones into an existing zone cluster or into a new zone cluster:

  • When you import an installed zone into a new zone cluster, zone properties such as zonepath, ip-type, and brand must be defined in the zone cluster configuration before you run the import-zone command.

  • The import-zone command can be executed only in the node scope.

  • The physical host must be specified in the node scope before running the import-zone command.

  • The local:rad SMF service, svc:/system/rad:local must be online on the physical host hosting the zone to be imported.

  • The zone to be imported must be in an installed state.

  • You cannot import an Oracle Solaris Zone that has zone properties such as zonepath, ip-type, and brand that are different from the zone cluster, unless you move the zone to the zone-cluster path using the Oracle Solaris zoneadm move command. See Moving a Non-Global Zone.

  • The zone to be imported cannot be on a shared storage.

  • The zone to be imported cannot be configured as a failover highly available zone.

  • The zone to be imported cannot be part of another zone cluster configuration.

  • The Oracle Solaris Zone that is imported will be renamed to the zone cluster's name. You will be prompted to accept the renaming of the zone.

  • When you run the import-zone command in the non-interactive mode, you will need to set an additional flag in order to rename the zone. For example:

    add node
    set physical-host=phost_name
    import-zone -y zonename=zone_name
    set hostname=host
    end

How to Import an Installed Zone into an existing Zone Cluster

  1. Assume the root role on a node of the global cluster.

    You perform all steps of the procedure from a node of the global cluster.

  2. Verify that the zone that you want to import is in an installed state.

    For example:

    phy-schost# zoneadm -z zone_name list -v

    Ensure that you meet the requirements as described in Requirements and Restrictions.

  3. Run the clzonecluster configure command on a configured zone cluster to set the necessary properties.
    phy-schost# clzonecluster configure zoneclustername
  4. Enter the node scope property using the add node command.
    clzc:zoneclustername:> add node
  5. Set the physical host property in the node scope which hosts the zone to be imported using the set physical-host command.
    clzc:zoneclustername:node> set physical-host=host
  6. Run the import-zone command on the installed zone.

    Accept the prompt to rename the zone.

    clzc:zoneclustername:node> import-zone zonename=zone_name

    If you are running the import-zone command in a non-interactive mode:

    import-zone -y zonename=zone_name
  7. Set the hostname in the node scope.
    clzc:zoneclustername:node> set hostname=host
  8. (Optional) Set other node scope properties and resources, if necessary.

    For example:

    # clzc:zoneclustername:node> add privnet
    # clzc:zoneclustername:node:privnet> set physical=bge0
    # clzc:zoneclustername:node:privnet> end
  9. End the node scope and commit the zone configuration.
  10. Verify that the zone is imported into the zone cluster.
    phy-schost# clzonecluster show -v zoneclustername
Example 12  Importing an Installed Zone into an Existing Zone Cluster

This example shows how to add an installed zone, zone1, into an existing zone cluster, sczone.

phy-schost# clzc configure sczone
clzc:sczone:> add node
clzc:sczone:node> set physical-host=phost2
clzc:sczone:node> import-zone zonename=zone1
This operation will rename the zone. Do you want to continue(Y/N)?
Y
clzc:sczone:node> set hostname=thost2-0a 
clzc:sczone:node> end 
clzc:sczone:> commit
clzc:sczone:> exit
#

How to Import an Installed Zone into a New Zone Cluster

  1. Assume the root role on a node of the global cluster.

    You perform all steps of the procedure from a node of the global cluster.

  2. Verify that the zone that you want to import is in an installed state.

    For example:

    phy-schost# zoneadm -z zone_name list -v

    Ensure that you meet the requirements as described in Requirements and Restrictions.

  3. Run the clzonecluster configure command on a configured zone cluster to set the necessary properties.
    phy-schost# clzonecluster configure new-zoneclustername
  4. Create the zone cluster using the create command.
    clzc:new-zoneclustername:> create
  5. Set the zonepath, ip-type, and brand properties of the zone cluster.
    clzc:new-zoneclustername:> set zonepath=/zones/zonec
    clzc:new-zoneclustername:> set ip-type=shared
    clzc:new-zoneclustername:> set brand=solaris
  6. Enter node scope using the add node command.
    clzc:new-zoneclustername:> add node
  7. Set physical host in the node scope which hosts the zone to be imported using the set physical-host command.
    clzc:new-zoneclustername:node> set physical-host=host
  8. Run the import-zone command on the installed zone.

    Accept the prompt to rename the zone.

    clzc:new-zoneclustername:node> import-zone zonename=zone_name

    If you are running the import-zone command in a non-interactive mode:

    import-zone -y zonename=zone_name
  9. Set the hostname in the node scope.
    clzc:new-zoneclustername:node> set hostname=host
  10. (Optional) Set other node scope properties and resources, if necessary.

    For example:

    # clzc:new-zoneclustername:node> add privnet
    # clzc:new-zoneclustername:node:privnet> set physical=bge0
    # clzc:new-zoneclustername:node:privnet> end
  11. End the node scope and commit the zone configuration.
  12. Verify that the zone is imported into the zone cluster.
    phy-schost# clzonecluster show -v zoneclustername
Example 13  Importing an Installed Zone into a New Zone Cluster

This example shows how to import an installed zone, zone1, into a new zone cluster, sczone-new.

phy-schost# clzc configure sczone-new
clzc:sczone-new:> create
clzc:sczone-new:> set zonepath=/zones/zonec
clzc:sczone-new:> set ip-type=shared
clzc:sczone-new:> set brand=solaris
clzc:sczone-new:> add node
clzc:sczone-new:node> set physical-host=phost2
clzc:sczone-new:node> import-zone zonename=zone1
This operation will rename the zone. Do you want to continue(Y/N)?
Y
clzc:sczone-new:node> set hostname=thost2-0a
clzc:sczone-new:node> end
clzc:sczone-new:> commit
clzc:sczone-new:> exit
#