You can use the Flash Archiving tools to create an image of an installed system that can be migrated into a zone.
The image can be fully configured with all of the software that will be run in the zone. This image is used by the installer when the zone is installed.
Use this process to create the system image. This example procedure uses NFS to place the flash archive on the target Solaris system, but you could use any method to move the files.
You must be the global administrator in the global zone to perform this procedure.
Become superuser, or assume the Primary Administrator role.
Log into the source system to be archived.
Change directories to the root directory.
# cd / |
Use flarcreate to create a flash archive image file named s-system, and place the archive onto the target system:
target-system # flarcreate -S -n s-system /net/target/export/s-system.flar Determining which filesystems will be included in the archive... Creating the archive... cpio: File size of "etc/mnttab" has increased by 435 2068650 blocks 1 error(s) Archive creation complete. |
In some cases, flarcreate can display errors from the cpio command. Most commonly, these are messages such as File size of etc/mnttab has increased by 33. When these messages pertain to log files or files that reflect system state, they can be ignored. Be sure to review all error messages thoroughly.
You can use alternate methods for creating the archive. The installer can accept the following archive formats:
cpio archives
gzip compressed cpio archives
bzip2 compressed cpio archives
pax archives created with the -x xustar (XUSTAR) format
ufsdump level zero (full) backups
Additionally, the installer can accept a directory of files created by using an archiving utility that saves and restores file permissions, ownership, and links. Thus, an example of a utility that cannot be used is tar, because tar does not handle links.
For more information, see the cpio(1), pax(1), bzip2(1), gzip(1), and ufsdump(1M) man pages.