I have configured just 1 backup repo and scheduled auto backup. But every time it creates three backup jobs, among which 1 gets completed and the other 2 fails. Though the backup is working and getting pushed to the configured repo, I do not understand why there are additional jobs triggered. Here are my backup manifest file and the logs from each job.
Log from Working Backup Job
---------------------------
time="2021-09-19T04:00:13Z" level=info msg="crunchy-pgbackrest starts"
time="2021-09-19T04:00:13Z" level=info msg="debug flag set to false"
time="2021-09-19T04:00:13Z" level=info msg="backrest backup command requested"
time="2021-09-19T04:00:13Z" level=info msg="command to execute is [pgbackrest backup --stanza=db --repo=2 --type=full]"
time="2021-09-19T04:01:02Z" level=info msg="output=[]"
time="2021-09-19T04:01:02Z" level=info msg="stderr=[]"
time="2021-09-19T04:01:02Z" level=info msg="crunchy-pgbackrest ends"
---
Log from Failing Backup Job
---------------------------
time="2021-09-19T04:00:03Z" level=info msg="crunchy-pgbackrest starts"
time="2021-09-19T04:00:03Z" level=info msg="debug flag set to false"
time="2021-09-19T04:00:03Z" level=info msg="backrest backup command requested"
time="2021-09-19T04:00:03Z" level=info msg="command to execute is [pgbackrest backup --stanza=db --repo=2 --type=full]"
time="2021-09-19T04:00:03Z" level=info msg="output=[]"
time="2021-09-19T04:00:03Z" level=info msg="stderr=[ERROR: [050]: unable to acquire lock on file '/tmp/pgbackrest/db-backup.lock': Resource temporarily unavailable\n HINT: is another pgBackRest process running?\n]"
time="2021-09-19T04:00:03Z" level=fatal msg="command terminated with exit code 50"
---
Log from Failing Backup Job
---------------------------
time="2021-09-19T04:00:01Z" level=info msg="crunchy-pgbackrest starts"
time="2021-09-19T04:00:01Z" level=info msg="debug flag set to false"
time="2021-09-19T04:00:01Z" level=info msg="backrest backup command requested"
time="2021-09-19T04:00:01Z" level=info msg="command to execute is [pgbackrest backup --stanza=db --repo=2 --type=full]"
time="2021-09-19T04:00:01Z" level=info msg="output=[]"
time="2021-09-19T04:00:01Z" level=info msg="stderr=[ERROR: [050]: unable to acquire lock on file '/tmp/pgbackrest/db-backup.lock': Resource temporarily unavailable\n HINT: is another pgBackRest process running?\n]"
time="2021-09-19T04:00:01Z" level=fatal msg="command terminated with exit code 50"
---
YAML Manifest
-------------
backups:
pgbackrest:
global:
repo2-path: /pgbackrest/postgres-operator/hippo/repo2
repo2-retention-full: "7"
repo2-retention-full-type: time
repoHost:
dedicated: {}
configuration:
- secret:
name: pgo-azure-creds
repos:
- name: repo2
azure:
container: pgo-test
schedules:
full: "0 4 * * *"
incremental: "0 */2 * * *"