deplace pid file creation in child process
Merge pull request #190 from deronnax/pid_file_creation_in_child

deplace pid file creation in child process