Facing problem with zone

i am using this way to create zone1 and zone2

bash-2.05b# zonecfg -z zone1
zone1: No such zone configured
Use 'create' to begin configuring a new zone.
zonecfg:zone1> create
zonecfg:zone1> set zonepath=/zone/1
zonecfg:zone1> set autoboot=true
zonecfg:zone1> add net
zonecfg:zone1:net> set address=192.168.35.210
zonecfg:zone1:net> set physical=hme1
zonecfg:zone1:net> end
zonecfg:zone1> info
zonepath: /zone/1
autoboot: true
pool:
inherit-pkg-dir:
        dir: /lib
inherit-pkg-dir:
        dir: /platform
inherit-pkg-dir:
        dir: /sbin
inherit-pkg-dir:
        dir: /usr
net:
        address: 192.168.35.210
        physical: hme1
zonecfg:zone1> verify
zonecfg:zone1> commit
zonecfg:zone1> ^D

how to assigne part from processor to each zone like 35% to zone1 and 35% to zone2 how can i do that

If you have 1 CPU, then use:

zonecfg:zone1> add capped-cpu
zonecfg:zone1>capped-cpu> set ncpus=0.35
zonecfg:zone1>capped-cpu> end

and

zonecfg:zone2> add capped-cpu
zonecfg:zone2>capped-cpu> set ncpus=0.35
zonecfg:zone2>capped-cpu> end

If you had for example 4 CPUs and wanted to assign 35% of the time of all four CPUs to each zone, then you need to specify 4*35/100 = 1.4 as ncpus for each zone.

very thanks for your effort helping me
during the zone creation that will be OK
but till now i can't edit configuration for zone already installed
could you till me how can i edit zone already installed

Did you try:

zonecfg -z zone1

?
I think most parameters can be modified after zone had been installed, I know that inherit-pkg-dir can't. Of course to take effect you need to restart that zone.

hi,
thanks bartus11 for this good article
the a problem prevent me to make this solution in this case
i have server carry 50 zone
all of then have application and web site working

so i can't divided the capacity of the processor to 50 zone
i divided this zone to 2 section
40 zone
10 zone
what i read about this
i should make 2 cpu pools
the first cpu pools takes 60 % from processor capacity
assign 40 zone to this pool
the secand cpu pools takes 40 % from processor capacity
assign 10 zone to this pool

if you know please provide me

I guess you need to create resource pool with poolcfg and pooladm (man pages section 1M: System Administration Commands - Sun Microsystems man pages section 1M: System Administration Commands - Sun Microsystems) and assign it to zones with pool keyword in zonecfg, like that:

example# zonecfg -z myzone
zonecfg:myzone> set pool=mypool
zonecfg:myzone> exit

Unfortunately I have no experience with creating resource pools, so you have to rely on manual pages :wink:

hi bartus11
thanks alot for your effort helping me
realy it is very usefull