Operating System - HP-UX
1831218 Members
2678 Online
110021 Solutions
New Discussion

Tunable Kernel Parameters?

 
SOLVED
Go to solution
WSS
Frequent Advisor

Tunable Kernel Parameters?

Hi All,

After reading up about vhand, it mentions something about the tunable kernel parameters for lotsfree, desfree and minfree. When I go to SAM or /stand/system I cannot see these parameters, where I expected to.

Can anyone shed some more light on this, and as to why I cannot see them currently in the Tunable Kernel Parameter section of SAM ...

Thanks
Trev
16 REPLIES 16
Patrick Wallek
Honored Contributor

Re: Tunable Kernel Parameters?

I would not mess with those parameters. If you actually get to a point where those come into play you want to be sure things work well.

Your best bet is to make sure you have enough RAM in the system so you never actually page out to a significant extent. As long as that is the case those parameters will not really be in play.
WSS
Frequent Advisor

Re: Tunable Kernel Parameters?


Yeah fair play, but we are at a point where we don't have enough RAM.

My point was, should those parameters be in the kernel already, or IF I do plan on changing them, do they need to be added?

Thanks for your quick reponse
Trev
A. Clay Stephenson
Acclaimed Contributor
Solution

Re: Tunable Kernel Parameters?

You can get to these values using kmtune.
e.g. kmtune -q minfree or simply kmtune to list all. kmtune can also be used to set these values. Man kmtune for details.
If it ain't broke, I can fix that.
WSS
Frequent Advisor

Re: Tunable Kernel Parameters?


Thanks alot, will take a look at kmtune ... :-)
WSS
Frequent Advisor

Re: Tunable Kernel Parameters?


Clay, when I run kmtune I can still not see the parameters desfree, lotsfree and minfree. I was expecting to see them when I ran kmtune (which is getting replaced by kctune by the way) ...

Shouldn't there be a parameter setting of at least 0 in there for these parameters (or maybe a default value) ... or can these parameters be added?

Cheers
Trev
Muthukumar_5
Honored Contributor

Re: Tunable Kernel Parameters?

Which platform? uname -a

In 11.11 ,

# kmtune | awk '/free/ { print "kmtune -q "$1" -l" }' | ksh
Parameter: desfree
Current: -
Planned: 0
Default: 0
Minimum: -
Module: -
Version: -
Dynamic: No
Parameter: lotsfree
Current: -
Planned: 0
Default: 0
Minimum: -
Module: -
Version: -
Dynamic: No
Parameter: minfree
Current: -
Planned: 0
Default: 0
Minimum: -
Module: -
Version: -
Dynamic: No

hth.
Easy to suggest when don't know about the problem!
WSS
Frequent Advisor

Re: Tunable Kernel Parameters?


Continued from above's post.

I cannot see the parameter when simply listing all the tunable parameters, by running a kmtune on it's own, but I can get the values for the parameters when running it with the -q option ... Is this right??

Thanks
Trev
Muthukumar_5
Honored Contributor

Re: Tunable Kernel Parameters?

You can tune lotsfree, desfree and minfree kernel parameters. (Dynamic: No).

hth.
Easy to suggest when don't know about the problem!
Muthukumar_5
Honored Contributor

Re: Tunable Kernel Parameters?

You have to do kernel rebuild for tunning this parameters. You can not change with kmtune -u utility.

hth.
Easy to suggest when don't know about the problem!
WSS
Frequent Advisor

Re: Tunable Kernel Parameters?


Ah lovely, cheers. I thought these were tunable with kmtune -u ... Is this why they don't show up when doing a kmtune on it's own? (to list all parameters) ...

# kmtune

This must just list those parameters that are tuneable in real time.
Cem Tugrul
Esteemed Contributor

Re: Tunable Kernel Parameters?

Hi,

-q name Query the value of the specified system parameter.

-s name{=|+}value
Set the value to a system parameter. If the separator is an
equal sign (=), the parameter is set to the value specified.
If the separator is a plus sign (+), the parameter is
incremented by the value specified. Negative values cannot
be used with plus sign (+). The name{=|+}value format must
not include spaces or tabs.

-u Update the currently running kernel. This modifies the -s
and -r options, to update the running kernel as well as the
system files. The values specified must be numeric. The
whole command will fail if any non dynamic parameters are
being set. The -s and -r options are processed in the order
they are listed. When incrementing a value with the -s
option the kernel and the system files are set to the value
in the system file plus the increment value.

When used alone, or with -S, it updates all the dynamic
parameters to match the numeric values stored in the system
files. A warning is reported if any static parameters have
differences. The order the parameters are listed in the
system files is not important. The -d option can be used to
look at the differences to get a preview of what a lone -u
will do.

Use of -u requires super user privileges.


Detailed report with -l option

Parameter: name
Current: current value from running kernel
Planned: planned value from system file
Default: default value from master file
Minimum: minimum
Module: module
Version: version
Dynamic: Yes/No


Good Luck,
Our greatest duty in this life is to help others. And please, if you can't
Sreedhar Nathani
Valued Contributor

Re: Tunable Kernel Parameters?

Hi,

Is this why they don't show up when doing a kmtune on it's own? (to list all)
# kmtune
This must just list those parameters that are tuneable in real time

Not really. I am able to see the mentioned parameter with kmtune. -u option updates the running kernel if those parameters are dynamic.

Static parameters requires a kernel rebuild and needs to be rebooted to take into effect.

With the #kmtune output you can see whether kernel parameter is dynamic or not. i.e if dyn is "Y" then its a dynamic parameter, otherwise its a static parameter

-l option will give you long listing, where as #kmtune will give one line info

Hope this helps

A. Clay Stephenson
Acclaimed Contributor

Re: Tunable Kernel Parameters?

My kmtune lists those paramters in both 11.0 and 11.11. Kmtune can also (and should be used) to change these parameters rather than simply editing the /stand/system file. Of course, a kernel rebuild will be required although I have never felt the need to change any of these from the defaults because I simply don't have any machines that swap.

You can also examine the current values directly using this technique:

echo "desfree/d" | adb /stand/vmunix /dev/kmem

If it ain't broke, I can fix that.
WSS
Frequent Advisor

Re: Tunable Kernel Parameters?


Below is an extract of my kmtune command with no options, and what should be either side of desfree, lotsfree and minfree ... But as you can see they are not there !!

You might be able to see them on your system, but I cannot. I was just curious as to why I cannot see them running # kumtune but can when running # kmtune -q

# uname -a
HP-UX B.11.23
#
# kmtune
kmtune is a wrapper script which exists for compatibility reasons
The underlying command used is 'kctune'. New or modified scripts
procedures should use kctune directly.
About to execute: kctune

Tunable Value Expression Changes

default_disk_ir 0 Default
disksort_seconds 0 Default

NO minfree ENTRY

ksi_send_max 32 Default
max_acct_file_size 2560000 Default Immed

NO lotsfree ENTRY

maxvgs 10 Default
msgmap 32769 32769

NO minfree ENTRY


# kmtune -q desfree
Tunable Value Expression
desfree 0 Default
#

# kmtune -q lotsfree
Tunable Value Expression
lotsfree 0 Default
#

# kmtune -q minfree
Tunable Value Expression
minfree 0 Default
#

Cheers
Trev
Patrick Wallek
Honored Contributor

Re: Tunable Kernel Parameters?

OK, this is apparently something with 11.23. I checked an 11.11 server and I see those parameters with kmtune. I then checked an 11.23 machine and I do NOT see those with the default kmtune/kctune output.

Apparently this changed with 11.23.

Now, I have to ask, what exactly do you hope to accomplish by tuning these parameters? They will change the behavior of vhand, but they will not directly free up any RAM.
Ted Buis
Honored Contributor

Re: Tunable Kernel Parameters?

The first think to check with regard to memory is check your dbc_max_pct to make sure it isn't too high. Also, if you are running Oracle, then can avoid double buffering if you have OnLineJFS, see attached paper. This will allow you to keep buffer cache smaller, save memory and avoid memory to memory transfers.

Lastly, if you must swap, make sure that you have sufficient device swap, possibly crossing multiple disks and turn off psuedoswap (swapmemon=0) otherwise a small percentage of your RAM pages will get swapped out excessively (not fairly).
Mom 6