runlock is insufficient, because it only takes into account the process
name, and not the arguments.

For instance, try this in terminal 1:
 $ runlock sleep 100

And in terminal 2:
 $ runlock sleep 200

Your second terminal's runlock will terminate with an error condition
because the "sleep" process is running (nevermind that you're running a
different screen).  Imagine something like "rsync", where you might have
several different backup jobs that use rsync, each with their own
arguments.

Instead, try this with run-one, terminal 1:
 $ run-one sleep 100

And terminal 2:
 $ run-one sleep 200

Both of these are allowed to run, because they're unique commands with
different arguments.

Open a third terminal and try to 'run-one sleep 100', and you'll see
that it terminates, because one of those specifically is already
running.

I don't see anything like 'run-this-one' in cronutils.  Again, in
terminal 3 try 'run-this-one sleep 200'.  It should kill the other one,
and run THIS one.

And keep-one-running is different from nohup (in case you're wondering),
because keep-one-running will restart the command (and parameters)
again, in ANY case of exit (zero, non-zero, as well as interrupt
signals).  nohup just ignores signals.

** Changed in: run-one (Ubuntu)
       Status: Incomplete => New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/888770

Title:
  [MIR] run-one

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/run-one/+bug/888770/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to