Operating System - HP-UX
1832241 Members
2844 Online
110041 Solutions
New Discussion

Re: Tuning after added more memory?

 
SOLVED
Go to solution
Dan Rosen
Frequent Advisor

Tuning after added more memory?

I just doubled our memory from 512M to 1G in our D390, running 10.2.

Do I need to tune anything, now that this is done, or extra memory is extra memory?

Some details:
I do have swapmem_on.
We have 2x500M swap partitions.
dbc_min is 10%
dbc_max is 55% (!!!)

We use this machine to run a 7 gig progess database.

I only added memory last night, so I have no new monitoring stats yet.

TIA
10 REPLIES 10
Todd Lehr
Frequent Advisor
Solution

Re: Tuning after added more memory?

I would drop dbc_max_pct down to around 15%, you would be better off allocating that memory to database buffers ( -B on server ) that using the OS.

My experience has also shown that under 10.20 the OS will tend to take the max and not release it (although there may have been a patch to fix that behavior ).

RAC_1
Honored Contributor

Re: Tuning after added more memory?

dbc_min & dbc_max looks very high for me.

that means buffers vary between 100 to 550 MB

But if you are running just progress on it and have no other applications then it is OK.

Additional parameter you need to tune should be maxswapchunks-max swap space system wide.

Regards,
There is no substitute to HARDWORK
Dan Rosen
Frequent Advisor

Re: Tuning after added more memory?

April - what would be appropriate values for maxswapchunks? Right now they are at 512.

Or, if you can't give values, what would the reasons be for adjusting one way or the other, and I can decide what they should be based on other parameters.

Thx
RAC_1
Honored Contributor

Re: Tuning after added more memory?

Let me be honest I am not so expert on kernel.

But basic thing that I understand is swap space should be more than physical memory(I always put it 1.5 times or twice the physical memory)

That is because if system is crashing all the memory contents will be dumped.

Now you have increased the memory, so swap space should also be increased.

maxswapchunks is the amount of swap space configurable. then it should also be increased.

Let's see what gurus say on this.

Regards,
There is no substitute to HARDWORK
Sean OB_1
Honored Contributor

Re: Tuning after added more memory?

Whenver you increase memory it's a good idea to check dbc_min and dbc_max since they are a percentage of memory.

Typically those don't need to grow when memory grows, assuming that the are set correctly for the current system load.

I would decrease those. Set min to 2% and max to say 10%. Then check your buffer reads to make sure you are still at 100%. If you are you could consider dropping the max even more. If you aren't very near, or at 100% buffer hits then increase the max until you hit 100%.

HTH

Sean
Dan Rosen
Frequent Advisor

Re: Tuning after added more memory?

Sean - where do I find the buffer reads/hits?
Sean OB_1
Honored Contributor

Re: Tuning after added more memory?

sar -b 5 20

This will show buffer hits every 5 seconds for 20 seconds.

If you have sar being saved you can look for todays stats just by running "sar -b"

Otherwise run sar for every 10 seconds for a few hours and see what you get.

Dennis Chow
New Member

Re: Tuning after added more memory?

Pls also verify:
1. if the dump is configured to write in /var/adm/crash, it better be mount in a separate mount point. Otherwise you can't have the full dump when the /var is full.

2. shmmax - max of share memory is also needed to tune for DB to allocate more memory

hope these can help you
denden
Sean OB_1
Honored Contributor

Re: Tuning after added more memory?

Whoops, noticed a mistake.

sar -b 5 20 will show hits every 5 seconds for 20 iterations. So it will run for 100 seconds showing stats every 5 seconds and then giving an average.

Results show like this:

root@fs51839[/tmp]> sar -b 1 5

HP-UX fs51839 B.11.00 U 9000/800 09/06/02

10:33:19 bread/s lread/s %rcache bwrit/s lwrit/s %wcache pread/s pwrit/s
10:33:20 0 55 100 0 1 100 0 0
10:33:21 0 3 100 3 3 0 0 0
10:33:22 0 3 100 2 2 0 0 0
10:33:23 0 1 100 1 1 0 0 0
10:33:24 0 1 100 1 1 0 0 0

Average 0 13 100 1 2 12 0 0
root@fs51839[/tmp]>
keith persons
Valued Contributor

Re: Tuning after added more memory?

Dan,

maxswapchunks is used in conjunction with swchunks. swap is allocated in swchunks, 2k by deault. with the default value of 256 for maxswapchunks around 550mb of swap area can be addressed. your value of 512 can effectively address 1.1gb of swap space. should you want to add more physical swap space an increase of maxswapchunks would be advised. additionally, there's no penalty for having large values maxswapchunks. if it should be too small however, an excessively large amount of physical swap would be allocated immediately after a boot because all swap above the addressable range is usually marked as used in swapinfo output.

at this point, i wouldn't advise changing much until you can get some additional measurements after adding the memory. how the 'extra' memory gets utilized is dependent on several things including whether there was a memory bottleneck in the first. if performance measurements change a lot after the memory was added you'll need to set new baselines and retune to optimal config. if little changes other than overall memory util the question becomes how to best use the additional memory.

all this is a long-winded way of saying "it depends", but it is the first rule of tuning.

keith