[Haskell-beginners] forkProcess behaviour

PICCA Frederic-Emmanuel frederic-emmanuel.picca at synchrotron-soleil.fr
Tue Jul 24 07:05:18 UTC 2018


Hello

I have done the first solution and call the program changing the command line in oder to execute each child task.
It works well and I can change the uid gid of these process.

> For the most part, yes. You may need to reach deeper and use SIGKILL occasionally, depending on how stubborn the child process is. The `timeout` will only kill off the parent thread's call to block on the child's exit code.

Since all these tasks are executing also child process via other system cals.
So I have a hyerarchy of process.

Do you know how to manage that sort of things if something goes wrong and I need to kill the first child and all its children's ?
Is it possible for CreateProcess to track all these process and kill them all  on request ?

> Yes, you should avoid forkProcess in this case, it will have unpredictable and confusing results.

I take you advices seriously and now I start to build something (I hope) more robust.

Thansk

Frédéric


More information about the Beginners mailing list