>> The process's pid is 1 really.It has been take-overed by system init
>> process.
>>
Sorry for my mistake,it should be "the process's ppid" really.ppid just mean
'parent process id'.
--
Jeff Pang
NetEase AntiSpam Team
http://corp.netease.com
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For
Thanks Jeff,
That clarifies it.
Regards
Cornelis
--memento mori
On 3/14/06, Jeff Pang <[EMAIL PROTECTED]> wrote:
>
>
> >
> >Does that not mean that a parent will stay alive until all children have
> >finished ?
> >
>
> No,the parent should get exited when it finish its session,in spite of
> chi
>
>Does that not mean that a parent will stay alive until all children have
>finished ?
>
No,the parent should get exited when it finish its session,in spite of childs
are still running or not.
When the parent exit,the childs should be take-overed by system init
process,whose process ID is typi
Thanks a lot for your replies, I've incorporated the children counter
variable, increasing it after every fork, decreasing it after every
SIG{CHLD}.
However, I still have an unresolved issue,
Jay:
> It's not missing; it was never there. Your parent process dies before
> its children are finished
>This would be a bad idea since the process never exits.
En? I just want to show the childs exiting status.
Surely,you could modify it simply to get main process exit normally.
for example:
# you could get the childs numbers by counting the @files array
$CHILD_COUNT=N;
# defined the sig handle
Jeff Pang wrote:
You can't see the output in your log is because when your childs are
executing,your parent has exited.
In order to see the callbacking childs,just add this line in the code end:
sleep while(1); # parent sleep to wait for childs exiting
This would be a bad idea since the proc
>
>The SIG{CHLD} handler doesn't get called since the output from
>
>> print LOG "Child process no. $stiff exited with status $?\n";
>>
>is missing.
>
You can't see the output in your log is because when your childs are
executing,your parent has exited.
In order to see the callbacking childs,jus
hi there,
I'm trying to use fork in a script that batch converts my old taped Simpsons
episodes to dvd.
This is the first time I've used fork and I'm a bit bewildered by the behaviour
exhibited
when a child process dies.
Basically, I want the main process to fork a list of children(one for e
On 3/13/06, Cornelis Swanepoel <[EMAIL PROTECTED]> wrote:
>
> I have found the following text in the perlfork manpage:
>
> Calling exec() within a pseudo-process actually spawns the requested
> > executable in a separate process and waits for it to complete before exiting
> > with the same exit st
Cornelis Swanepoel wrote:
The SIG{CHLD} handler doesn't get called since the output from
print LOG "Child process no. $stiff exited with status $?\n";
is missing.
It's not missing; it was never there. Your parent process dies before
its children are finished. It is no longer around to reap
hi there,
I'm trying to use fork in a script that batch converts my old taped Simpsons
episodes to dvd with tovid.
This is the first time I've used fork and I'm a bit bewildered by the
behaviour exhibited when a child process dies.
Basically, I want the main process to fork a list of children(on
11 matches
Mail list logo