0
votes

I know how to run one cron job after another from this: https://askubuntu.com/questions/923260/cron-run-a-script-after-the-other

But, if I have jobs A, B, and C, how do I make job C wait for BOTH A and B to be finished? Either A or B could finish first, and C cannot start running until both A and B have finished.

1

1 Answers

1
votes

I would just put the entire thing into a script and use standard process management, something like:

#!/bin/env bash
jobA &  # start A in the background.
jobB    # start B in the foreground, A and B running.
wait    # B now finished, wait for A if necessary.
jobC    # A and B now finished, do C.