develooper Front page | perl.ithreads | Postings from March 2013

Re: Issues with process forking when 'multithreaded'.

Thread Previous | Thread Next
Sander Smeenk
March 4, 2013 15:32
Re: Issues with process forking when 'multithreaded'.
Message ID:
Quoting Sander Smeenk (

> In fact, it does work, for 95% of all threads it works as designed, only
> a select few (but not the same) threads fail each time, i was hoping to
> find out why only this small portion of threads fail their waitpid() call. ;)

Also, this might not be clear from my original message, the main process
is the process that creates the threads, one for each server that needs
to be backed up. Each thread calls fork() only once (through open3) for
the rsync to do the heavy lifting.

So, it's not a fork() from the main process (which would perhaps
copy all threads to the fork()ed process, or maybe not, who knows).

Amazing there is so little known about what this does / how this works,
i'll see if i can get a working testcase instead of the snipped i

| One tequila, two tequila, three tequila, floor.
| 4096R/20CC6CD2 - 6D40 1A20 B9AA 87D4 84C7  FBD6 F3A9 9442 20CC 6CD2

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About