Global and non-global zone resource sharing - tricky


 
Thread Tools Search this Thread
Operating Systems Solaris Global and non-global zone resource sharing - tricky
# 1  
Old 12-16-2015
Global and non-global zone resource sharing - tricky

hi all,

Just a simple question but i cant get the answers in the book -

In my globalzone , assuming i have 4 cpus (psrinfo -pv = 0-3), if i set dedicated-cpu (ncpus=2) for my local zone

Is my globalzone left with 2 cpus or still 4 cpus ? Does localzone "resource reservation.e.g. cpu in our case above" have any impact to the globalzone ?

For i am thinking-if it does and if i setup 2 local zones with dedicated cpu = 2, doesn't that leave my globalzone with no cpu to run ?

Regards,
Noob
# 2  
Old 12-16-2015
The zone restrictions do not apply to the global zone - it can use all 4 CPUs.
This User Gave Thanks to MadeInGermany For This Post:
# 3  
Old 12-17-2015
Quote:
Originally Posted by MadeInGermany
The zone restrictions do not apply to the global zone - it can use all 4 CPUs.

Hi MadeInGermany,

Thanks for your reply.

q1) Does that means that the global zone will always be able to utilized all the cpus resources irregardless if they are assigned to local zones or not ? - am I right

q2) I have an application running in globalzone, in that server, there are no other non-globalzone.

Is there anyway I can limit the cpu utilization in globalzone ?

- can I set dedicated-cpu to a global-zone ?
- I believe we can set a capped-cpu to a global zone


Regards,
Noob
# 4  
Old 12-17-2015
Well, rule of thumb is not to run applications in global zone.
Exception could be backup software or monitoring/log shipment software..

Is there any practical reason not to have that application running in non-global zone ?

Personally, i use FSS scheduler with global/non-global zones and control the CPU resources using shares. Global zone has 1 share by default.

Shares are bit different then CPU caps you are using.. for instance you have 10 shares of CPU (when used 100% all 10 shares are used) running 1 global zone and 2 zones.

You set 6 and 3 cpu shares for two non-global zones (1 is for global zone), which means that zone with 6 shares will get 60% of CPU in case of CPU resource contention.
Otherwise it can use all the CPU.

So FSS guarantees CPU time in mentioned relation.
10 CPU share = 100 % CPU, global zone : zone1 : zone2 = 1:6:3

10 is a number you choose, you can choose 100 as well as any other number which will represent maximum CPU time which you will divide among zones.

I found this to be most effective in terms of harnessing CPU power when needed by single zone so far and giving guarantees if things go bananas.

Of course, you can change that as administrator from global zone, even on runtime, using prctl effectively giving additional CPU shares to a zone or a single process.

Hope that helps
Regards
Peasant.
This User Gave Thanks to Peasant For This Post:
# 5  
Old 12-17-2015
q1) yes
q2)
you cannot put zone limits to the global zone.
Code:
man prctl

shows the available resources; you can try to set project.cpu-shares to a certain project, then assign certain processes to that project. I have no experience with that. Instead I have used the classic commands
Code:
nice startprocess

Code:
renice <pid>

This User Gave Thanks to MadeInGermany For This Post:
# 6  
Old 12-18-2015
Hi Peasant, Made in Germany,

Thank for the feedback.

-> Peasant
I am not sure if i am able to use FSS due to oracle database licensing which required me to cap the cpu utilization the a maximum of the amount of core which is/are licensed.

But however, i am curious about what you mentioned about FSS, do you mean if there are no contention, a zone which is assign e.g. 3 shared might be able to get more then >3 ?

-> MadeInGermany,

Somehow i felt that allocating dedicated cpu to non-globalzone did take away the cpu resource from the global, base on some simple finding which i observed

a) i cannot create a zone that utilized all the cpu resources available. (e.g. there are a total of 4 cpu, if i set dedicated = 4ncpus) the zone will fail to boot.
(if globalzone has access to all the cpus irregardless if any dedicated cpus are assigned to non-globalzone, then why can't we assign all the cpus to a non-globalzone then)


b) when assigning dedicated cpu to a non global-zone and issuing pooladm afterwards, the default pset cpu amount got lesser.
which i believe anyzone (including globalzone) which are not explicitly assign to anypool will be assigned to the default pool -> default pset .

please let me know your views. (i been googling, reading tons of docs but to no avail).

Regards,
Noob
# 7  
Old 12-18-2015
It is simple, if there is not contention, any zone can take all the CPU.

As for Oracle database licensing, this is a descent document :
http://www.oracle.com/technetwork/se...ng-2347187.pdf

FSS is not confromant unless you are paying all the physical cores in your machine.
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Solaris

Solaris 11 zone has no external network access (except to Global Zone)

Hi, hoping someone can help, its been a while since I used Solaris. After creating a NGZ (non global zone), the NGZ can access the GZ (Global Zone) and the GZ can access the NGZ (using ssh, zlogin) However, the NGZ cannot access any other netwqork devices, it can't even see the default router ... (2 Replies)
Discussion started by: GazinLincoln
2 Replies

2. Solaris

Date and time change in global and non global zone

Hi, If I change date and time in global zone, then it will affect in non global zones. During this process what files will get affect in non global zones and which mechanism it's using to change. gloabl zone:Solaris 11.3 X86 TIA (1 Reply)
Discussion started by: Sumanthsv
1 Replies

3. Solaris

showing 2 different time zones in global zone and nonglobal zone

can some one help me out as it is showing 2 different time zones in global zone and nonglobal zone .In global zone it is showing in GMT while in nonglobal zone i it showing as PDT. System in running with solaris 10 (3 Replies)
Discussion started by: ravijanjanam12
3 Replies

4. Solaris

How to access ENV variables of non global zones in global zone???

Hi Guys, My requirement is I have file called /opt/orahome/.profile in non global zone. PATH=/usr/bin:/usr/ucb:/etc:/usr/sbin:/usr/local/bin:/usr/openwin/bin:. export PATH PS1="\${ORACLE_SID}:`hostname`:\$PWD$ " export PS1 EDITOR=vi export EDITOR ENV=/opt/orahome/.kshrc export ENV... (1 Reply)
Discussion started by: vijaysachin
1 Replies

5. Solaris

Is there two different kernel`s running in global and non global zone?

Hi All, I want to know for non global zone there will be different kernal running? (1 Reply)
Discussion started by: vijaysachin
1 Replies

6. Solaris

How can we copy a directory from Global to Non-global zone?

Hi All, How can we copy a directory from global zone to non-global zone using SCP command? (8 Replies)
Discussion started by: vijaysachin
8 Replies

7. Solaris

[b]How to mount a folder from global zone to non global zone??

Hi All There is one folder in global zone I just want to share the same folder innon global zone. How can i do it? pls send me script for this. (2 Replies)
Discussion started by: vijaysachin
2 Replies

8. Solaris

sharing a directory between local and global zone

is this the step? add fs set dir=/export set special=/export set type=lofs add options rw end i notice i can't post immediately, moderator needs to moderate. i have 1 more post still haven't appear in the forum..hmm.... (1 Reply)
Discussion started by: binary0011
1 Replies

9. Solaris

How to know the global zonename from non-global zone?

It is easy to list all zones from global zones, but how to find out the global zone name from non-global zone? thx (11 Replies)
Discussion started by: honglus
11 Replies
Login or Register to Ask a Question