Operating System - HP-UX
1850352 Members
2750 Online
104054 Solutions
New Discussion

Re: error message about fork

 
Suriya Wanna_1
Occasional Advisor

error message about fork

Hi everyone

I found the error message in syslog.log about fork , main focus message is list below.

Dec 21 09:49:58 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 09:59:39 cdgmrd2 su: - 3 firsthop-root
Dec 21 10:00:15 cdgmrd2 su: + 3 firsthop-root
Dec 21 10:00:06 cdgmrd2 su: - 3 firsthop-root
Dec 21 10:01:15 cdgmrd2 above message repeats 2 times
Dec 21 10:04:26 cdgmrd2 sshd[9246]: fatal: fork of unprivileged child failed
Dec 21 10:04:34 cdgmrd2 sshd[9248]: fatal: fork of unprivileged child failed
Dec 21 10:04:38 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 10:04:38 cdgmrd2 sshd[9252]: fatal: fork of unprivileged child failed
Dec 21 10:04:38 cdgmrd2 sshd[9255]: fatal: fork of unprivileged child failed
Dec 21 10:04:38 cdgmrd2 sshd[9257]: fatal: fork of unprivileged child failed
Dec 21 10:04:38 cdgmrd2 sshd[9259]: fatal: fork of unprivileged child failed
Dec 21 10:04:43 cdgmrd2 sshd[9261]: fatal: fork of unprivileged child failed
Dec 21 10:10:20 cdgmrd2 su: + 4 firsthop-root
Dec 21 10:13:08 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 10:19:57 cdgmrd2 sshd[9474]: fatal: fork of unprivileged child failed
Dec 21 10:13:59 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 10:21:25 cdgmrd2 sshd[9494]: error: openpty: Not enough space
Dec 21 10:21:25 cdgmrd2 sshd[9496]: error: session_pty_req: session 0 alloc failed
Dec 21 10:21:25 cdgmrd2 sshd[9496]: Disconnecting: fork failed: Not enough space
Dec 21 10:21:43 cdgmrd2 sshd[9501]: error: openpty: Not enough space
Dec 21 10:21:43 cdgmrd2 sshd[9503]: error: session_pty_req: session 0 alloc failed
Dec 21 10:21:43 cdgmrd2 sshd[9503]: Disconnecting: fork failed: Not enough space
Dec 21 10:22:28 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 10:22:46 cdgmrd2 su: - 1 firsthop-root
Dec 21 10:23:46 cdgmrd2 sshd[9525]: load_modules: can not open module /usr/lib/security/libpam_unix.1
Dec 21 10:24:10 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 10:24:00 cdgmrd2 sshd[9525]: load_modules: can not open module /usr/lib/security/libpam_unix.1
Dec 21 10:34:37 cdgmrd2 sshd[903]: error: fork: Not enough space
Dec 21 10:38:55 cdgmrd2 su: + 1 firsthop-root
Dec 21 10:36:31 cdgmrd2 sshd[903]: error: fork: Not enough space
Dec 21 10:39:37 cdgmrd2 sshd[9649]: fatal: fork of unprivileged child failed
Dec 21 10:36:55 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 10:41:16 cdgmrd2 above message repeats 2 times
Dec 21 10:47:58 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 10:50:51 cdgmrd2 sshd[9741]: error: openpty: Not enough space
Dec 21 10:50:31 cdgmrd2 prngd[2699]: Could not fork: Not enough space
Dec 21 10:50:51 cdgmrd2 sshd[9743]: error: session_pty_req: session 0 alloc failed
Dec 21 10:50:51 cdgmrd2 sshd[9743]: Disconnecting: fork failed: Not enough space
Dec 21 10:50:51 cdgmrd2 sshd[9743]: clnt_dg_create: out of memory
Dec 21 10:51:02 cdgmrd2 sshd[9748]: error: openpty: Not enough space
Dec 21 10:51:02 cdgmrd2 sshd[9750]: error: session_pty_req: session 0 alloc failed
Dec 21 10:51:02 cdgmrd2 sshd[9750]: Disconnecting: fork failed: Not enough space
Dec 21 10:51:02 cdgmrd2 sshd[9750]: clnt_dg_create: out of memory
Dec 21 10:51:21 cdgmrd2 sshd[9753]: error: openpty: Not enough space
Dec 21 10:51:21 cdgmrd2 sshd[9755]: error: session_pty_req: session 0 alloc failed
Dec 21 10:51:21 cdgmrd2 sshd[9755]: Disconnecting: fork failed: Not enough space
Dec 21 10:51:21 cdgmrd2 sshd[9755]: clnt_dg_create: out of memory
Dec 21 10:55:03 cdgmrd2 vmunix:
Dec 21 10:55:03 cdgmrd2 vmunix: Shutting down machine, please wait.

During this message happen i can not run any command ,when i type command it has message "fork failed: Not enough space" everytime.I have to reboot machine and after that it work fine but i want to know the cause of this problem.Does anyone have suggestion about this problem?
6 REPLIES 6
Steven E. Protter
Exalted Contributor

Re: error message about fork

Shalom Suryia,

You are out of memory.

swapinfo -tam

If allocated swap is all used up, get more memory.

If swap is very small, consider increasing it.

Check following kernel parameters:

nproc
nfile
maxuprc

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Arunvijai_4
Honored Contributor

Re: error message about fork

Can you try to get # swapinfo -tam as soon as you start getting these messages ? May be your memory is full?

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
Bill Hassell
Honored Contributor

Re: error message about fork

As mentioned, you are completely out of RAM *and* swap space. You need to double or triple the amount of swap space which can be done online with swapon. If you are also experiencing very slow performance, you also need to double or triple your RAM size.


Bill Hassell, sysadmin
James R. Ferguson
Acclaimed Contributor

Re: error message about fork

Hi:

Do a 'swapinfo -tam'. If you do not see a line marked "memory" in the first column, then you do not have pseudo-swap enabled. If not, change the kernel parameter 'swapmem_on' to one (1). This will cause 75% of you phyical memory to be counted for swap reservation purposes. You may find that your "can't fork (errno 12) errors vanish.

Regards!

...JRF...
Kent Ostby
Honored Contributor

Re: error message about fork

Keep in mind that the general recommendation on hp-ux is for disk swap to equal 2x RAM.

Compare your swapinfo for disk swap to your RAM and adjust as needed.
"Well, actually, she is a rocket scientist" -- Steve Martin in "Roxanne"
HGN
Honored Contributor

Re: error message about fork

Hi

I agree with others you need to increase your swap space

do a swapinfo -mat and see the swap & priotiy.

Rgds

HGN