Sponsored Content
Operating Systems Solaris Global and non-global zone resource sharing - tricky Post 302962684 by Peasant on Thursday 17th of December 2015 10:42:36 AM
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:
 

9 More Discussions You Might Find Interesting

1. 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

2. 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

3. 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

4. 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

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 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

7. 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

8. 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

9. 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
FSS(7)							   Device and Network Interfaces						    FSS(7)

NAME
FSS - Fair share scheduler DESCRIPTION
The fair share scheduler (FSS) guarantees application performance by explicitly allocating shares of CPU resources to projects. A share indicates a project's entitlement to available CPU resources. Because shares are meaningful only in comparison with other project's shares, the absolute quantity of shares is not important. Any number that is in proportion with the desired CPU entitlement can be used. The goals of the FSS scheduler differ from the traditional time-sharing scheduling class (TS). In addition to scheduling individual LWPs, the FSS scheduler schedules projects against each other, making it impossible for any project to acquire more CPU cycles simply by running more processes concurrently. A project's entitlement is individually calculated by FSS independently for each processor set if the project contains processes bound to them. If a project is running on more than one processor set, it can have different entitlements on every set. A project's entitlement is defined as a ratio between the number of shares given to a project and the sum of shares of all active projects running on the same proces- sor set. An active project is one that has at least one running or runnable process. Entitlements are recomputed whenever any project becomes active or inactive, or whenever the number of shares is changed. Processor sets represent virtual machines in the FSS scheduling class and processes are scheduled independently in each processor set. That is, processes compete with each other only if they are running on the same processor set. When a processor set is destroyed, all processes that were bound to it are moved to the default processor set, which always exists. Empty processor sets (that is, sets without processors in them) have no impact on the FSS scheduler behavior. If a processor set contains a mix of TS/IA and FSS processes, the fairness of the FSS scheduling class can be compromised because these classes use the same range of priorities. Fairness is most significantly affected if processes running in the TS scheduling class are CPU- intensive and are bound to processors within the processor set. As a result, you should avoid having processes from TS/IA and FSS classes share the same processor set. RT and FSS processes use disjoint priority ranges and therefore can share processor sets. As projects execute, their CPU usage is accumulated over time. The FSS scheduler periodically decays CPU usages of every project by multi- plying it with a decay factor, ensuring that more recent CPU usage has greater weight when taken into account for scheduling. The FSS scheduler continually adjusts priorities of all processes to make each project's relative CPU usage converge with its entitlement. While FSS is designed to fairly allocate cycles over a long-term time period, it is possible that projects will not receive their allocated shares worth of CPU cycles due to uneven demand. This makes one-shot, instantaneous analysis of FSS performance data unreliable. Note that share is not the same as utilization. A project may be allocated 50% of the system, although on the average, it uses just 20%. Shares serve to cap a project's CPU usage only when there is competition from other projects running on the same processor set. When there is no competition, utilization may be larger than entitlement based on shares. Allocating a small share to a busy project slows it down but does not prevent it from completing its work if the system is not saturated. The configuration of CPU shares is managed by the name server as a property of the project(4) database. In the following example, an entry in the /etc/project file sets the number of shares for project "x-files" to 10: x-files:100::::project.cpu-shares=(privileged,10,none) Projects with undefined number of shares are given one share each. This means that such projects are treated with equal importance. Projects with 0 shares only run when there are no projects with non-zero shares competing for the same processor set. The maximum number of shares that can be assigned to one project is 65535. You can use the prctl(1) command to determine the current share assignment for a given project: $ prctl -n project.cpu-shares -i project x-files or to change the amount of shares if you have root privileges: # prctl -r -n project.cpu-shares -v 5 -i project x-files See the prctl(1) man page for additional information on how to modify and examine resource controls associated with active processes, tasks, or projects on the system. See resource_controls(5) for a description of the resource controls supported in the current release of the Solaris operating system. By default, project "system" (project ID 0) includes all system daemons started by initialization scripts and has an "unlimited" amount of shares. That is, it is always scheduled first no matter how many shares are given to other projects. The following command sets FSS as the default scheduler for the system: # dispadmin -d FSS This change will take effect on the next reboot. Alternatively, you can move processes from the time-share scheduling class (as well as the special case of init) into the FSS class without changing your default scheduling class and rebooting by becoming root, and then using the priocntl(1) command, as shown in the following example: # priocntl -s -c FSS -i class TS # priocntl -s -c FSS -i pid 1 CONFIGURING SCHEDULER WITH DISPADMIN
You can use the dispadmin(1M) command to examine and "tune" the FSS scheduler's time quantum value. Time quantum is the amount of time that a thread is allowed to run before it must relinquish the processor. The following example dumps the current time quantum for the fair share scheduler: $ dispadmin -g -c FSS # # Fair Share Scheduler Configuration # RES=1000 # # Time Quantum # QUANTUM=110 The value of the QUANTUM represents some fraction of a second with the fractional value determied by the reciprocal value of RES. With the default value of RES = 1000, the reciprocal of 1000 is .001, or milliseconds. Thus, by default, the QUANTUM value represents the time quan- tum in milliseconds. If you change the RES value using dispadmin with the -r option, you also change the QUANTUM value. For example, instead of quantum of 110 with RES of 1000, a quantum of 11 with a RES of 100 results. The fractional unit is different while the amount of time is the same. You can use the -s option to change the time quantum value. Note that such changes are not preserved across reboot. Please refer to the dispadmin(1M) man page for additional information. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | |Architecture |SUNWcsu | +-----------------------------+-----------------------------+ SEE ALSO
prctl(1), priocntl(1), dispadmin(1M), psrset(1M), priocntl(2), project(4), attributes(5), resource_controls(5) System Administration Guide: N1 Grid Containers, Resource Management, and Solaris Zones SunOS 5.10 1 Oct 2004 FSS(7)
All times are GMT -4. The time now is 11:09 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy