cli: Check pid file before random_delay

If there is another process running now, there is no need to wait, especially
without pidfile, so create such file immediately, then wait if needed.
in 0 seconds, using 0 compute credits, and was queued for 0 seconds
latest