in reply to Re^3: Perl Daemons and SIGHUP
in thread Perl Daemons and SIGHUP

yes. but the exec call takes the process out.
After that when i do on shell: ps aux | grep mtsd i get nothing

Replies are listed 'Best First'.
Re^5: Perl Daemons and SIGHUP
by mje (Curate) on Feb 24, 2010 at 13:33 UTC

    If you are using warnings you should get a warning for that exec since exec says Since it's a common mistake to use "exec" instead of "system", Perl warns you if there is a following statement which isn't "die", "warn", or "exit"

    Why not check exec worked as described in the exec pod.

    How many arguments are in @argv (and what do they contain?) as that affects whether the command in passed to your shell or to execve?

    You could always run strace (or whatever depending on your platform) to see what is really going on - although remember to follow children.

      @argv should be empty. But even though i removed the argv from exec it still make the process vanish ...

        You don't know your process has "vanished" since you have not ascertained it even started. Check your exec call as per the examples in perldoc -f exec. Put some code after the exec which should not be reached if the exec works. If this does not help you trace it with something like strace.