Operating System - HP-UX
1753774 Members
6963 Online
108799 Solutions
New Discussion юеВ

parent hangs when child exits

 
Jim Walsh
New Member

parent hangs when child exits

I am working with an application which forks off children in the background to try and establish a network connection (over X.25). We are running into a situation where *only sometimes* when the child exits, the parent hangs. Sometimes its after SIGCHLD has been caught by the parent, sometimes its before, and in all cases SIGCHLD is being processed if and when it is caught. 'ps' shows that the child did indeed exit, and the parent is still there, and is owned by its respective parent, not init or anything like that.
Has anyone experienced this before, or does anyone know which utilities would be good to use to try and see exactly what the state of the parent is when it appears to be hanging?
2 REPLIES 2
Robert Gamble
Respected Contributor

Re: parent hangs when child exits

Jim,

It almost sounds like the child is providing a service the parent requires.

It does not sound like a shell problem.
Thats my two cents.

Good Luck!
Nandan
New Member

Re: parent hangs when child exits

Jim,

Can you attach to the process (using gdb or dde)?
or can you run tusc on the process ?
Can you kill the process ?

One thing I have found and happens
to me sometimes.
whats the priority of the process
(ps -l ).
If the priority is less than 154, then the process is
in an unrecovrable kernel state and you
cant do much about it.

Good luck.