Skip to content

Stale Locks Remain Stale Until you Manually Unlock Them (not good for automation) #6094

Description

@Lonniebiz

I find it ironic that this issue is "locked" (given that it pertains to stale "locks"). The issue is marked as resolved, but it doesn't seem to be in resolved in borg 1.1.16:
#3191

A power outage is what caused my stale lock. I can unlock it, but what concerns me is Borg's inability to auto-notice that a lock is stale. I ultimately intend to automate these borg backups, and if it cannot recover from a stale lock, I can see potential for recurring failures going unnoticed. I will certainly take great care in my scripting to be notified of such failures, because I read here of a person who went 3 months without noticing that a stale lock was preventing all his automated backups!

Rather than just complaining about this, maybe I can suggest some solutions. Hmm.

Certainly borg logs activity on a repo with timestamps, no? If so, it seems that a stale lock rejection should trigger a log evaluation to occur, if there's been no log activity in the last 10 minutes (for example), then instead of continuing to cry about a lock, maybe borg should simply make a checkpoint out of the abandoned session and auto-unlock the repo. That's the first thing that comes to my mind; hopefully someone else can top it.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions