Oracle Solaris Trusted Extensions Configuration Guide

ProcedureCreate ZFS Pool for Cloning Zones

If you plan to use a Solaris ZFSTM snapshot as your zone template, you need to create a ZFS pool from a ZFS file or a ZFS device. This pool holds the snapshot for cloning each zone. You use the /zone device for your ZFS pool.

Before You Begin

You have set aside disk space during Solaris installation for a ZFS file system. For details, see Planning for Zones in Trusted Extensions.

  1. Unmount the /zone partition.

    During installation, you created a /zone partition with sufficient disk space of about 2000 MBytes.


    # umount /zone
    
  2. Remove the /zone mount point.


    # rmdir /zone
    
  3. Comment out the /zone entry in the vfstab file.

    1. Prevent the /zone entry from being read.

      Open the vfstab file in an editor. Prefix the /zone entry with a comment sign.


      #/dev/dsk/cntndnsn  /dev/dsk/cntndnsn  /zone  ufs  2  yes  -
    2. Copy the disk slice, cntndnsn, to the clipboard.

    3. Save the file, and close the editor.

  4. Use the disk slice to re-create /zone as a ZFS pool.


    # zpool create -f zone cntndnsn
    

    For example, if your /zone entry used disk slice c0t0d0s5, then the command would be the following:


    # zpool create -f zone c0t0d0s5
    
  5. Verify that the ZFS pool is healthy.

    Use one of the following commands:


    # zpool status -x zone
    pool 'zone' is healthy

    # zpool list
    NAME     SIZE     USED   AVAIL   CAP   HEALTH   ALTROOT
    /zone    5.84G   80K    5.84G    7%   ONLINE   -

    In this example, the initial setup team reserved a 6000 MByte partition for zones. For more information, see the zpool(1M) man page.