1820475 Members
2926 Online
109624 Solutions
New Discussion юеВ

Re: problem !!!!!!

 
federico_3
Honored Contributor

problem !!!!!!

If I try to connect to a HP_UX machine (11.00 B 9000/802) with a terminal session, I get the msg
Unable to fork, too many processes.

I tried again and now I connected, while the first session is still locked.

What cai i do ??


Federico
9 REPLIES 9
James R. Ferguson
Acclaimed Contributor

Re: problem !!!!!!

Hi Federico:

You aparently have a process that has spawned (forked) children to the kernel's 'nproc' limit. The processing doing the 'fork' could be continuing to do so. Look for the rogue parent and kill it.

...JRF...
Dan Hetzel
Honored Contributor

Re: problem !!!!!!

Hi Frederico,

You've hit the 'nproc' limit.
If you're logged-in, you probably have a chance to start a 'ps -ef' as soon as another process dies.
Maybe you'll have to retry a few times to succeed, as you're short of space to fork a new process.
Try to determine the parent process and kill it with 'kill -9'.

Best regards,

Dan
Everybody knows at least one thing worth sharing -- mailto:dan.hetzel@wildcroft.com
federico_3
Honored Contributor

Re: problem !!!!!!

Should i increase any kernel parameters??
The present ones are:
nproc 700
maxfiles 60
maxfiles_lim 1024
maxuprc 75
maxusers 50

Can you help me to fix the probled definitively?


Federico
Devbinder Singh Marway
Valued Contributor

Re: problem !!!!!!

hi,
nproc is for system wide processes and you have 700 , maxuprc is for individual users , currently you have 75 i.e. a user can have 75 processes which is quite a lot. What you can do is check if same user is logged on twice and check if anything is going loopy i.e. one of those users is running a program/script which is spawning alot of other processes , if so kill the user all together or the processes. If not try increasing maxuprc

HTH
Seek and you shall find
Dan Hetzel
Honored Contributor

Re: problem !!!!!!

Hi Frederico,

You could increase 'maxusers' as a lot of parameters rely on this one.
This will ensure that all parameters are adjusted in a logical way.

Increasing 'maxuprc' would help to push the limits a bit further (128 seems a nice value to me)

Best regards,

Dan
Everybody knows at least one thing worth sharing -- mailto:dan.hetzel@wildcroft.com
Sandor Horvath_2
Valued Contributor

Re: problem !!!!!!

Hi !

Wich HP license have You got ? 2 - users ???
Because in HP any different terminal means 1 user and network is 1 user license.
use uname -l.

If use network connection the see your process table before try login.

sar -v 2 2


regards, Saa
If no problem, don't fixed it.
Suhas_2
Regular Advisor

Re: problem !!!!!!

Hi fred,
In addition to "nproc" I would like to say something. Pls capture the output of "ps -ef" every 30 minutes,
using cron. Whenever you come across, such a problem, you can view those logs. That will tell you,
which process is spawning continuously. I am
suggesting this because, there might just be a
program, which is forking continuously.
Once you, find the culprit, you would not come
across the problem in future.
Hope this helps...;-).
Suhas.
Never say "Die"
Steven Sim Kok Leong
Honored Contributor

Re: problem !!!!!!

Hi,

An alternative to monitoring total concurrent processes via ps is to snmpquery the HP-UX MIB for the total number of concurrent processes any point in time and subsequently trigger of either an email or page alert upon an exceeded threshold value such as 80% of your nproc value.

For maxuprc, only those users who have exceeded the kernel value are affected. The system well-being as a whole is not impacted. For nproc, the entire system would not be able to proceed when exceeded. Thus monitoring of total concurrent processes is absolutely necessary whereas the monitoring of the number of concurrent processes each user is running is optional. A script can be written to monitor this using primarily ps but the benefits might not be worth the additional overhead added by the script onto the system.

Hope this helps. Regards.

Steven Sim.
Brainbench MVP for Unix Admin
http://www.brainbench.com
Darrel Louis
Honored Contributor

Re: problem !!!!!!

Frederico,

I agree with Dan.
It's better to increase maxusers, so that all the appropiate parameters will change aswell.

Check if the nproc parameter is a formula which include maxusers.

Good Luck