4be32c6b8249226b6abb7dc0dcb18e3838a39f19
When the scheduler checks whether the last run of a job has finished,
it dies if the task log of that run does not exist. The job is then
skipped with 'could not update job state, skipping - no such task' on
every iteration, so it never runs again until its state file is
cleaned up manually.
The task log can be gone, for example after a crash. If the task is
not running anymore, treat it as stopped with an error status instead,
so that the job gets scheduled again, like Proxmox Backup Server does
since commit 48fbce07 ("fix #4895: scheduled jobs: ignore task-log not
found error").
The check now comes after the one whether the task is still running,
so a running task does not get marked as stopped.
Signed-off-by: Michal Fox <me@dualfroz.com>
Description
My contributions to proxmox-git/pve-manager: 31 commits
206 KiB
0 Stars
1 Watchers
0 Forks
Languages
JavaScript
64.8%
Perl
34.9%
Makefile
0.3%