add PID file creation support