issues with backup and lock  [SOLVED]

Have you discovered a bug? Tell us about it.
Post Reply
RikkerdNL
Posts: 18
Joined: Mon 27. May 2024, 10:05

issues with backup and lock

Post by RikkerdNL »

I'm sure the cause of the problem is within KeyHelp
Maybe it is in Restic, but using the native backup feature of Keyhelp.

Server operating system + version
Ubuntu Linux 24.04.3

Server virtualization technology used
KVM

KeyHelp version + build number
25.3 (Build 3565)


Problem description / error messages

We have setup keyhelp backup with a ftps repo with a daily schedule. When it starts the second backup or any next backup it shows the following error when keyhelp runs the cleanup:

Code: Select all

Failed to prune repository: {"message_type":"exit_error","code":11,"message":"unable to create lock in backend: repository is already locked by PID 3066733 on host.server.com by root (UID 0, GID 0)\nlock was created at 2026-01-04 15:46:57 (11m39.436724347s ago)\nstorage ID 08af0c1b\nthe `unlock` command can be used to remove stale locks"}
Please note this will happen only when running the second time, we can use the unlock option, but I tried this many times, it always has a stalled lock file. So I need to use this every backup, which makes the schedule backup unusable.

Expected result
Run multiple backups with cleanup with no lock issue

Actual result
As above, when the second or next backup run the cleanup will fail.

Steps to reproduce
Run the backup schedule minimal 2 times.

Additional information
I checked the log but I cannot find any more restic error log, I am searching why the lock file is not removed. The repo setip is a ftps server, and I also tried a custom rclone config with:

Code: Select all

type = ftp
host = host.server.com
user = username
pass = password
explicit_tls = true
no_check_certificate = true
And also with max connection set to 1 but still the same error. I tried 2 different machines but they all do the same. It looks like the problem can be in the ftps repo, but I do want to find the issue to solve.
User avatar
Alexander
Keyweb AG
Posts: 4706
Joined: Wed 20. Jan 2016, 02:23

Re: issues with backup and lock

Post by Alexander »

Can you switch to SFTP just for testing purpose? FTPS sometimes seams a bit fragile, if the remote server is using an outdated FTP Server version etc.
Also you may want to reduce the amount of concurrent connections below "Advanced settings" for the FTP connection.
Mit freundlichen Grüßen / Best regards
Alexander Mahr

**************************************************************
Keyweb AG - Die Hosting Marke
Neuwerkstr. 45/46, 99084 Erfurt / Germany
http://www.keyweb.de - http://www.keyhelp.de
**************************************************************
User avatar
Tobi
Community Moderator
Posts: 3532
Joined: Thu 5. Jan 2017, 13:24

Re: issues with backup and lock

Post by Tobi »

But the minimum is two connections.
Otherwise pruning will not work.
Gruß,
Tobi


-----------------------------
wewoco.de
Das Forum für Reseller, Digital-Agenturen, Bildschirmarbeiter und Mäuseschubser
RikkerdNL
Posts: 18
Joined: Mon 27. May 2024, 10:05

Re: issues with backup and lock  [SOLVED]

Post by RikkerdNL »

Thank you for the help. I changed the connection without any solution. I switched to sftp and this has no lock issues any longer. The issue is strange because I also use restic with my own bash script this does a backup and a clean action, without issues on the ftps host.

So for now it works via sftp.
Post Reply