Create pid file on Unix.