Change file permissions on the pid file before switching users away from root.