stashed / stash

🛅 Backup your Kubernetes Stateful Applications
https://stash.run
Other
1.3k stars 86 forks source link

Unable to create lock in backend, repository already locked even though no lock exists #1490

Closed joeldeteves closed 1 year ago

joeldeteves commented 1 year ago

There seems to be some weird behaviour happening on one of my repositories where Stash thinks there's a lock on the repository.

However, when I check the repository for locks, no locks are found. In addition, when I run restic unlock it's successful.

Where is this old lock coming from? How do I get rid of it?

[golang-sh]$ /bin/restic forget --quiet --json --keep-hourly 3 --keep-daily 7 --keep-weekly 1 --keep-monthly 1 --prune --cache-dir /tmp/restic-cache
unable to create lock in backend: repository is already locked by PID 78 on site-backups-5565bd97bb-lksds by nobody (UID 65534, GID 65534)
lock was created at 2022-10-22 18:00:11 (144h0m0.059996167s ago)
joeldeteves commented 1 year ago

Now I feel stupid - some time ago, the path on the repository changed. I was confused because the bucket name is still the same.

When I identified the correct path, there were in fact locks. This issue is solved