A race condition can arise when two servers are started simultaneously. Both
instances may complete the check for an existing pidfile before either one
Now the pidfile is opened with ::File::EXCL, which raises an error if the file
already exists. This error is handled by retrying the check and the write.