1851433 Members
4592 Online
104058 Solutions
New Discussion

Re: CPU load balancing

 
SOLVED
Go to solution
Jeffry Tank
Occasional Contributor

CPU load balancing

I was wondering if there is some way to distribute the CPU load evenly across multipul CPU's in an N Class server. In all my N Class servers the oracle processes seem to load one or two CPU's while the rest remain mostly idle. I have several servers with 4 to 8 CPU's and 8 to 12Gig of memory. All system are runing HPUX 11.X and Oracle 8.1.7 and 9i databases.

Thanks in advance

Jeff
9 REPLIES 9
Pete Randall
Outstanding Contributor
Solution

Re: CPU load balancing

Jeff,

That's what HP-UX attempts to do. I don't think there's any further tuning that can be done, unless it's to your Oracle engine.

Pete

Pete
Bill Hassell
Honored Contributor

Re: CPU load balancing

There is no way to spread the load of one program across multiple CPUs. That's because each instruction must be executed in order. If separate CPUs ran different instructions, the result would be chaos. Applications must be specifically written to handle multiple CPUs. This technique is called threading and is similar to writing mini programs within a single application.

These threaded applications can take advantage of multiple CPUs as each mini program runs by itself and signaling the main program when it is done. An example of a threaded application is a web browser like Netscape, Opera or IE. While downloading a web page, the mouse still works and can pull down menus or change the current URL. To do this, the browser must run a separate task to perform the download, another to monitor mouse clicks, another to pull down a menu and so on.

In the case of Oracle, conact your DBA to look at the configuration file and version. Sone versions od Oracle can take advantage of multiple processors when the startup config file specifies the number of parallel tasks that can be run at the same time.


Bill Hassell, sysadmin
Ian Dennison_1
Honored Contributor

Re: CPU load balancing

Jeff,

In terms of multi-threading, you will probably require a re-design of that way your Oracle System does its work.

FYI, we benchmarked our (ahem) 'multi-threaded', in-house developed Oracle 8.1.7.3.0 App on a 32-CPU Superdome last year. After the initial benchmark run, we dropped the number of CPUs down and re-ran it again. It was only when we got down to 8 CPUs that the program started to run in a longer time (12 CPUs provided all the resources Oracle could use).

Ergo, even though an Oracle system may be designed to be multi-threaded, you may still run into some design flaws that prevent usage of the available hardware / OS resources.

Maybe Oracle 9i has some tweaks for this (partitioning perhaps?)

Share and Enjoy! Ian
Building a dumber user
Jeffry Tank
Occasional Contributor

Re: CPU load balancing

Thanks all
this is what I suspected but I wanted to make sure I was correct in my asumptions before presenting it to my boss as he was concerned that there may have been other problems that would cause this behavior.

Jeff Tank
Rory R Hammond
Trusted Contributor

Re: CPU load balancing

Jeff,

When I investigate these types of problems on our system. I look at the dominating CPU process using Oracle's Top Session and sometimes SQL analyze. We have fixed many performance problems by adding and Index or by rewriting a query. Some times we just have to pass on the issue to the developer and he fixes it.
There are a 100 ways to do things and 97 of them are right
Tim D Fulford
Honored Contributor

Re: CPU load balancing

Hi

We use Informix. Informix has a basic "work horse" process termed cpu-vp. In HP-UX it just appears as a process "oninit", but the general rule of thumb is number of CPU-1 = number of cpu-vps. Informix will spread the load over these cpu-vps and HP-UX will try to run each oninit on a processor. Informix actually has quite a few vps (virtual processes)
but generally a cpu-vp is by far the busiest.

I know you use Oracle, but there is probably a similar class of process, it may be that you could run more "work horse" processes.

Regards

Tim
-
Paula J Frazer-Campbell
Honored Contributor

Re: CPU load balancing

Jeff

Please assign points, as these forum members have gone out of their way to assist you.


Paula
If you can spell SysAdmin then you is one - anon
Tim D Fulford
Honored Contributor

Re: CPU load balancing

Try looking at ....

mpsched -c cpu# -p pid

I can't find the command on my system, but it is only a 1CPU machine, I just happened to see this today and thought of you (ahhh!!!)

Tim
-
RAC_1
Honored Contributor

Re: CPU load balancing

If you have multiple Oracle instances running on your system you may consider installing PRM(Process Resource Manager)

Basically with PRM installed you can allot CPU,MEM,DISK to different groups.(These groups you define in config file)

We run PRM with CPU allocation in SHARE mode.
With this we can allocate 50 % of CPU(all CPUs) power to this progrm another 30 % to another programm and likewise.

Check documents at docs.hp.com for detailed information on PRM.
There is no substitute to HARDWORK