popen() alternative - I am using the accepted
answer (pipe/fork/exec method) to solve my issue. Only difference is, instead of execl
, I am using execv
.
Now, my question is, does parent process have any control over child process created by execv
? Lets say this whole sequence suggested in accepted
answer is for tailing 1 file and I have many such files; I put this whole sequence in a function and if I call this function many times, at a point in time, is it possible to have many child tail
processes around?
What I want to know is,
1) Can I have multiple child processes running at any point in time?
2) how does child processes (created by execv) terminate? after execv
call does parent know when child process (created by execv) is done/terminated? - answered.