Migrating a zone from one system to another involves the following steps:
1. Detaching the Zone - This leaves the zone on the originating system in the configured state. Behind the scenes, the system generates a manifest of the information needed to validate that the zone can be successfully attached to a new host machine.
To detach a zone, first halt the zone, then perform the detach operation.
2. Data Migration - You move the data which represents the zone to a new host system.
3. Zone Configuration - You create the zone configuration on the new host using the zonecfg command, as shown in the example on this page.
Use the create subcommand to begin configuring a new zone,
4. Attaching the Zone - This validates that the host is capable of supporting the zone before the attach can succeed. The zone is left in the installed state. The syntax for attaching a zone is displayed on this page.
Detaching a Zone
host1# zoneadm -z work-zone halt
host1# zoneadm -z work-zone detach
Example of Migrating Zone Data
On host1:
host1# cd /export/zones
host1# tar cf work-zone.tar work-zone
host1# sftp host2
Connecting to host2...
Password:
sftp> cd /export/zones
sftp> put work-zone.tar
Uploading work-zone.tar to /export/zones/work-zone.tar
sftp> quit
On host2:
host2# cd /export/zones
host2# tar xf work-zone.tar
Creating a Zone Configuration
host2# zonecfg -z work-zone
work-zone: No such zone configured
Configuring a New Zone
zonecfg:work-zone> create -a /export/zones/work-zone
zonecfg:work-zone> commit
zonecfg:work-zone> exit
Attaching a Zone
host2# zoneadm -z work-zone attach
No comments:
Post a Comment