Introduction to Oracle® Solaris Zones

Exit Print View

Updated: December 2014
 
 

Non-Global Zone State Model

A non-global zone can be in one of the following seven states:

Configured

The zone's configuration is complete and committed to stable storage. However, those elements of the zone's application environment that must be specified after initial boot are not yet present.

Incomplete

During an install or uninstall operation, zoneadm sets the state of the target zone to incomplete. Upon successful completion of the operation, the state is set to the correct state.

A damaged installed zone can be marked incomplete by using the mark subcommand of zoneadm. Zones in the incomplete state are shown in the output of zoneadm list –iv.

Unavailable

Indicates that the zone has been installed, but cannot be verified, made ready, booted, attached, or moved. A zone enters the unavailable state at the following times:

  • When the zone's storage is unavailable and svc:/system/zones:default begins, such as during system boot

  • When the zone's storage is unavailable

  • When archive-based installations fail after successful archive extraction

  • When the zone's software is incompatible with the global zone's software, such as after an improper –F (force) attach

Installed

The zone's configuration is instantiated on the system. The zoneadm command is used to verify that the configuration can be successfully used on the designated Oracle Solaris system. Packages are installed under the zone's root path. In this state, the zone has no associated virtual platform.

Ready

The virtual platform for the zone is established. The kernel creates the zsched process, network interfaces are set up and made available to the zone, file systems are mounted, and devices are configured. A unique zone ID is assigned by the system. At this stage, no processes associated with the zone have been started.

Running

User processes associated with the zone application environment are running. The zone enters the running state as soon as the first user process associated with the application environment (init) is created.

Shutting down and Down

These states are transitional states that are visible while the zone is being halted. However, a zone that is unable to shut down for any reason will stop in one of these states.

Chapter 3, Installing, Booting, Shutting Down, Halting, Uninstalling, and Cloning Non-Global Zones, in Creating and Using Oracle Solaris Zones and the zoneadm (1M) man page describe how to use the zoneadm command to initiate transitions between these states.

In addition, Oracle Solaris Kernel Zones have three auxiliary states, which are used to notify the host with additional information about the current zone state.

Suspended

Primary state is halted, with an auxiliary state of suspended.

Debugging

The zone is running, but the zone cannot respond to external events, such as networking. zlogin checks for this state and waits until the state is cleared before starting a zlogin session.

Panicked

The zone has panicked, but the zone cannot respond to external events until it is rebooted.

For additional information, see Creating and Using Oracle Solaris Kernel Zones and the solaris-kz (5) man page.

Table 1-2  Commands That Affect Zone State
Current Zone State
Applicable Commands
Configured
zonecfg –z zonename verify
zonecfg –z zonename commit
zonecfg –z zonename delete
zoneadm –z zonename attach
zoneadm –z zonename verify
zoneadm –z zonename install
zoneadm –z zonename clone
zoneadm –z zonename mark incomplete
zoneadm –z zonename mark unavailable
You can use the zonecfg command to rename a zone in the configured state. Note that you can use the zoneadm command to rename an Oracle Solaris Zone or Oracle Solaris 10 Zone in either the configured or installed state.
Incomplete
zoneadm –z zonename uninstall
Unavailable
zoneadm –z zonename uninstall uninstalls the zone from the specified system.
zoneadm –z zonename attach
zonecfg –z zonename can be used to change zonepath and any other property or resource that cannot be changed when in the installed state.
Installed
zoneadm –z zonename ready (optional)
zoneadm –z zonename boot
zoneadm –z zonename uninstall uninstalls the configuration of the specified zone from the system.
zoneadm –z zonename move path
zoneadm –z zonename detach
zonecfg –z zonename can be used to add or remove an attr, bootargs, capped-memory, dataset, capped-cpu, dedicated-cpu, device, fs, ip-type, limitpriv, net, rctl, or scheduling-class property. You can also rename a zone.
You can use the zoneadm command to rename an Oracle Solaris Zone or Oracle Solaris 10 Zone in the configured or installed state.
zoneadm –z zonename mark incomplete
zoneadm –z zonename mark unavailable
Ready
zoneadm –z zonename boot
zoneadm halt and system reboot return a zone in the ready state to the installed state.
zonecfg –z zonename can be used to add or remove attr, bootargs, capped-memory, dataset, capped-cpu, dedicated-cpu, device, fs, ip-type, limitpriv, net, rctl, or scheduling-class property.
Running
zlogin options zonename
zoneadm –z zonename reboot
zoneadm –zzonename halt returns a ready zone to the installed state.
zoneadm halt and system reboot return a zone in the running state to the installed state.
zoneadm –z shutdown cleanly shuts down the zone.
zonecfg –z zonename can be used to add or remove an attr, bootargs, capped-memory, dataset, capped-cpu, dedicated-cpu, device, fs, ip-type, limitpriv, anet, net, rctl, or scheduling-class property. The zonepath resource cannot be changed.

Note -  Parameters changed through zonecfg do not affect a running zone. The zone must be rebooted for the changes to take effect.