You must be the global administrator in the global zone to perform this procedure.
This example procedure uses the blank archive image, solaris9-image.flar. This archive is in the sys-unconfig state. See Software Download to obtain this file.
For information on creating images of Solaris 9 systems, see Creating the Image for Directly Migrating Solaris 9 Systems Into Zones.
Become superuser, or assume the Primary Administrator role.
Install the configured zone s9-zone by using the zoneadm command with the install -a option and the path to the archive.
global# zoneadm -z s9-zone install -u -a /net/server/s9_image.flar |
You will see various messages as the installation completes. This can take some time.
To retain the sysidcfg identity from a system image that you created without altering the image, use the -p option after the install subcommand. To remove the system identity from a system image that you created without altering the image, use the -u option. The sys-unconfig occurs to the target zone.
(Optional) If an error message is displayed and the zone fails to install, type the following to get the zone state:
global# zoneadm list -cv |
ID NAME STATUS PATH BRAND IP 0 global running / native shared - s9-zone configured /export/home/s9-zone solaris9 shared |
If the state is listed as configured, make the corrections specified in the message and try the zoneadm install command again.
If the state is listed as incomplete, first execute this command:
global# zoneadm -z my-zone uninstall |
Then, make the corrections specified in the message and try the zoneadm install command again.
When the installation completes, use the list subcommand with the -i and -v options to list the installed zones and verify the status.
global# zoneadm list -iv |
You will see a display that is similar to the following:
ID NAME STATUS PATH BRAND IP 0 global running / native shared - s9-zone installed /export/home/s9-zone solaris9 shared |
# zoneadm -z s9-zone install -a /net/machinename/s9_image.flar Log File: /var/tmp/s9-zone.install.21207.log Source: /net/machinename/s9_image.flar Installing: This may take several minutes... Postprocessing: This may take a minute... Result: Installation completed successfully. Log File: /export/home/s9-zone/root/var/log/s9-zone.install.21207.log |
Option |
Description |
---|---|
-a |
Location of archive from which to copy system image. Full flash archive and cpio, gzip compressed cpio, bzip compressed cpio, and level 0 ufsdump are supported. Refer to the gzip man page available in the SUNWsfman package. |
-d |
Location of directory from which to copy system image. |
-p |
Preserve system identity. |
-s |
Install silently. |
-u |
sys-unconfig the zone. |
-v |
Verbose output. |
If an installation fails, review the log file. On success, the log file is in two places: /var/tmp in the global zone, and /var/log inside the zone. On failure, the log file is in /var/tmp.
If a zone installation is interrupted or fails, the zone is left in the incomplete state. Use uninstall -F to reset the zone to the configured state. See How to Uninstall a Zone in System Administration Guide: Oracle Solaris Containers-Resource Management and Oracle Solaris Zones for more information.