1837945 Members
2532 Online
110124 Solutions
New Discussion

Re: Sys Mem

 
John Goetz
Advisor

Sys Mem

Is there a kernel parameter to change the amount of memory that the system will use?
3 REPLIES 3
Michael Tully
Honored Contributor

Re: Sys Mem

no, not unless your speaking of shared memory.

# kmtune -l -q shmmax
Anyone for a Mutiny ?
Sridhar Bhaskarla
Honored Contributor

Re: Sys Mem

Well,

There is a parameter dbc_max_pct by default set to 50% of the memory.

kmtune -l -q dbc_max_pct

This will be used by the system for buffer cache. You may want it to reduce it to around 300-400MB.

Other parameters do not really matter much. If is a 11i system, vx_ninode can play a part as it is dynamically alloted by the kernel. This can be made static.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Bill Hassell
Honored Contributor

Re: Sys Mem

The amount of system memory is determined by the size of the kernel code (not much you can do except to remove uneeded modules (perhaps saving a few Kbytes, not really important). Palces to save memory are the maximum table sizes. The most common table that is too large is ninode. Typically, it needs to be only a few thousand entries, but since it is built in SAM using a formula that is badly out of date, the number may be 8000 or even 20000, way too high. Override the formula witha fixed value of 2048.

nfile and nproc can be reduced by looking at sar -v 1 and checking the maximum value for file and proc versus the peak values. You can reduce nproc and nfile to where about 70-80% utilization is typical.

Now the buffer cache is not exactly part of the kernel but it is shared by ll processes. This is by far the biggest change you make to increase free memory. In SAM, change the dbc_mac_pct from 50 to 10 as a start. Now even though the max value is 50%, the kernel will reduce the size of the buffer cache to the dbc_min_pct when processes need more memory.

However, your question may actually be a request to fix a memory problem with an application such as Oracle or Sybase. Rarely are memory errors related to the amount of physical memory. HP-UX is a virtual memory system and as long as you have lots of swap space, you won't physical memory problems. Instead, these errors usually relate to shared memory limits and 32bit program limits which are solved with software changes. Perhaps you can tell us why you need to reduce the system memory usage.


Bill Hassell, sysadmin