Search This Blog

Saturday, 19 March 2011

Configuring Zpool with Solaris Zone

Set up details: 
Server: globalzone
Zone name: testzone
1. Creating testpool named testpool with two disks in global zone

root@global # testpool create testpool  c4t60050768018E8327B800000000000005d0s0 
c4t60050768018E8327B800000000000008d0s0 

2. Checking the status of created pool testpool 

root@global # zpool status -v testpool
  pool: testpool
 state: ONLINE
 scrub: none requested
config:


        NAME                                       STATE     READ WRITE CKSUM
        testpool                                      ONLINE       0     0     0
          c4t60050768018E8327B800000000000005d0s0  ONLINE       0     0     0
          c4t60050768018E8327B800000000000008d0s0  ONLINE       0     0     0


errors: No known data errors
3. Adding the pool to zone
root@global # zoneadm -z testpool halt
root@global # zonecfg -z testpool
zonecfg:testzone> add dataset
zonecfg:testzone:dataset> set name="testpool"
zonecfg:testzone:dataset> end
zonecfg:testzone> commit
zonecfg:testzone> exit
root@global # zoneadm -z testzone boot

4. Creating first filesystem named mqm 
root@testzone# zfs create testpool/mqm
5. Setting quota for each file sy stem
root@testzone# zfs set quota=110G testpool/apps
root@testzone# zfs set quota=1G testpool/oraapps          
root@testzone# zfs set quota= 4G testpool/mqm  
6. Changing  mount point from non-global zone
bash-3.00# zfs set mountpoint=/apps testpool/apps
bash-3.00# zfs set mountpoint=/var/mqm  testpool/mqm
bash-3.00# zfs set mountpoint=/oracle/orapp testpool/oraapps
7. Since we don’t  need to pool to mounted,  removing pool from mounting
bash-3.00# zfs set mountpoint=legacy testpool

No comments:

Post a Comment