Saturday, 28 December 2013

Soalris 11 zones: CAPPED -CPU assign ment(all cpus from global zone are visible to guestzone)

1)To see confitured zones in verbose manner
root@solaris2:~# zoneadm list -cv
  ID NAME             STATUS     PATH                           BRAND    IP
   0 global           running    /                              solaris  shared
   7 testzone         running    /TESTZONE                      solaris  excl
2)to halt zones
root@solaris2:~# zoneadm -z testzone halt
3)to list zones
root@solaris2:~# zoneadm list -cv
  ID NAME             STATUS     PATH                           BRAND    IP
   0 global           running    /                              solaris  shared
   - testzone         installed  /TESTZONE                      solaris  excl
4)to configure zones
root@solaris2:~# zonecfg -z testzone
zonecfg:testzone> info
zonename: testzone
zonepath: /TESTZONE
brand: solaris
autoboot: true
bootargs:
file-mac-profile:
pool:
limitpriv:
scheduling-class:
ip-type: exclusive
hostid:
fs-allowed:
net:
        address not specified
        allowed-address not specified
        configure-allowed-address: true
        physical: net3
        defrouter not specified
capped-cpu:
        [ncpus: 4.00]
capped-memory:
        physical: 4G
        [swap: 1G]
        [locked: 100M]
rctl:
        name: zone.cpu-cap
        value: (priv=privileged,limit=400,action=deny)
rctl:
        name: zone.max-swap
        value: (priv=privileged,limit=1073741824,action=deny)
rctl:
        name: zone.max-locked-memory
        value: (priv=privileged,limit=104857600,action=deny)
zonecfg:testzone> add dedicated-cpu
The capped-cpu resource already exists.
5)to boot zones
root@solaris2:~# zoneadm -z testzone boot
6)to list configured zones in verbose manner
root@solaris2:~# zoneadm list -cv
  ID NAME             STATUS     PATH                           BRAND    IP
   0 global           running    /                              solaris  shared
   8 testzone         running    /TESTZONE                      solaris  excl
7)to see no of processors allocated to zone
root@testzone:~# psrinfo
0       on-line   since 12/27/2013 23:12:07
1       on-line   since 12/27/2013 23:12:09
2       on-line   since 12/27/2013 23:12:09
3       on-line   since 12/27/2013 23:12:09
4       on-line   since 12/27/2013 23:12:09
5       on-line   since 12/27/2013 23:12:09
6       on-line   since 12/27/2013 23:12:09
7       on-line   since 12/27/2013 23:12:09
8       on-line   since 12/27/2013 23:12:09
9       on-line   since 12/27/2013 23:12:09
10      on-line   since 12/27/2013 23:12:09
11      on-line   since 12/27/2013 23:12:09
12      on-line   since 12/27/2013 23:12:09
13      on-line   since 12/27/2013 23:12:09
14      on-line   since 12/27/2013 23:12:09
15      on-line   since 12/27/2013 23:12:09
16      on-line   since 12/27/2013 23:12:09
17      on-line   since 12/27/2013 23:12:09
18      on-line   since 12/27/2013 23:12:09
19      on-line   since 12/27/2013 23:12:09
20      on-line   since 12/27/2013 23:12:09
21      on-line   since 12/27/2013 23:12:09
22      on-line   since 12/27/2013 23:12:09
23      on-line   since 12/27/2013 23:12:09
24      on-line   since 12/27/2013 23:12:09
25      on-line   since 12/27/2013 23:12:09
26      on-line   since 12/27/2013 23:12:09
27      on-line   since 12/27/2013 23:12:09
28      on-line   since 12/27/2013 23:12:09
29      on-line   since 12/27/2013 23:12:09

No comments:

Post a Comment