Operating System - HP-UX
1823069 Members
3286 Online
109645 Solutions
New Discussion юеВ

How to know the values of "lotsfree" "desfree" and "minfree" on HP-UX

 
Wang,MinJie
Super Advisor

How to know the values of "lotsfree" "desfree" and "minfree" on HP-UX

Hi all
I ran:
***********************************************
echo "lotsfree/D"|adb -k /stand/vmunix /dev/mem
***********************************************
according to the manual to get the value of "lotsfree"
but it output the following information:
*********************************************
adb: info: Option -k is deprecated.
adb: warning: Trouble reading version string from memory file ...
adb: warning: Object file and memory file may not be matched.
lotsfree:
adb: warning: Unrecognized format character - 'D'.
*********************************************
So what's the problem
Thx in advance
3 REPLIES 3
Hasan  Atasoy
Honored Contributor

Re: How to know the values of "lotsfree" "desfree" and "minfree" on HP-UX

hi wang

echo lotsfree/D |adb /stand/vmunix /dev/mem
echo minfree/D |adb /stand/vmunix /dev/mem
echo desfree/D |adb /stand/vmunix /dev/mem

hasan.
rajdev
Valued Contributor

Re: How to know the values of "lotsfree" "desfree" and "minfree" on HP-UX

Hi ,

adb should have worked, for me on some systems it works and on others i get the same error. I am not sure what's the reason.

I made this small c program that can help.
[ lotsfree.c ]

To compile use : #make lotsfree

then run it ./lotsfree

Regards,
RD
Emil Velez
Honored Contributor

Re: How to know the values of "lotsfree" "desfree" and "minfree" on HP-UX

if you do a sysdef on a system you will notice the kernel parameters are 0.

This means that these parameters are based on certain ratios. Remember lotsfree is the parameter where vhand will start monitoring memory useage and figuring out what pages have been used and prepare them to be swapped out.

lotsfree (tunable): Threshold at which the memory manager decides that free memory is
becoming short of supply, specified in pages. When the number of free
pages falls below lotsfree, vhand() tunes its parameters each time it is
awakened. On systems with 32 MB of free memory or less after kernel
initialization (referred to here as small-memory systems), lotsfree is
set to 1/8 of non-kernel memory, not to exceed 256 pages (1 MB). On
systems with more than 32 MB of free memory but not more than 2 GB
after kernel initialization (referred to here as large-memory systems),
lotsfree is set to 1/16 of non-kernel memory, not to exceed 8192 pages
(32 MB). If non-kernel memory exceeds 2 GB, lotsfree is set to 16384
pages (64 MB). These default values may be overridden by explicitly
setting lotsfree.

desfree (tunable): Threshold at which the memory manager decides that more aggressive
measures are needed to prevent the system from running out of free
memory, specified in pages. When the number of free pages falls
below desfree, vhand() reaches its most aggressive state and tries to
free up pages as quickly as possible. On small-memory systems,
desfree is set to 1/16 of non-kernel memory, not to exceed 60 pages
(240 Kbytes). On large-memory systems, desfree is set to the 1/64 of
non-kernel memory, not to exceed 1024 pages (4 MB). If non-kernel
memory exceeds 2 GB, desfree is set to 3072 pages (12 MB). These
default values may be overridden by explicitly setting desfree, but
desfree must be less than lotsfree.


minfree (tunable): Threshold at which the memory manager starts deactivating processes
with the intent of moving all of the pages belonging to that process out
to swap space, specified in pages. When the number of free pages falls
below minfree, the swapper recognizes that the system is desperate
for memory and attempts to swap out a process whether it is runnable
or not. On small-memory systems, minfree is set to 1/2 of desfree, not
to exceed 25 pages (100 KB). On large-memory systems, minfree is set
to 1/4 of desfree, not to exceed 256 pages (1 MB). If non-kernel
memory exceeds 2 GBytes, minfree is set to 1280 pages (5 MB). These
defaults may be overridden by explicitly setting minfree, but minfree
must be less than desfree.