my $rc = fork; if($rc == 0){ #child system("run_shell_script"); }else{ #parent #decide when to kill shell script by killing child #not sure if this won't create a zombie shell script #and system dosen't return a PID kill 9, $rc; }