zonecfg
Utility Edit Modes
Use the zonecfg
utility edit modes to make configuration changes to the zone. You can change either the persistent stored configuration or the running live configuration. The zonecfg
utility supports the following edit modes for use with Live Reconfiguration:
- Default mode
-
Create, modify, and list the persistent zone configuration stored on the stable storage. Parameters you changed in the default mode do not affect a running zone at the time you make the changes. The default mode is the primary way to maintain the zone configuration. This mode is backward compatible.
To have the changes made in default mode take effect in the running zone, you must issue one of the following
zoneadm
commands:-
Use the
zoneadm apply
command to load the updated persistent zone configuration so it is applied to the running zone. -
Use the
zoneadm reboot
command to reboot the zone and read the updated persistent zone configuration.
-
- Live mode
-
Retrieve, inspect and edit the running live zone configuration. The live mode is available for a running zone only. Parameters you change in live mode take effect immediately after you use the
commit
subcommand to enable them in the live zone configuration.Changes made in live mode are temporary. The changes remain active until the next zone reboot. For more information, see Temporary Changes to the Live Zone Configuration.
To make live zone configuration changes permanent, you apply the changes to the persistent zone configuration with the
zoneadm apply
command. For more information, see Persistent Changes to the Live Zone Configuration.To enable live mode, use the ‐r option with the
zonecfg
command, which retrieves the live zone configuration instead of the persistent zone configuration.global$ pfexec zonecfg -z zonename -r
You can work with the
zonecfg -r
command just as you do in default mode. The full set ofzonecfg
subcommands and both the interactive and the batch mode are supported.Not all resources can be reconfigured in the live configuration. For a list of supported resource types and properties, see the table in Live Zone Reconfiguration Support or Restriction in Oracle Solaris Zones Configuration Resources.