Syncthing on Unraid: repairing malformed database disk image

Mostly as a note to myself, but here’s what to do if you’re running linuxserver/syncthing via Docker on Unraid and it keeps saying:

ERR Database error when getting previous version (error="getkv: database disk image is malformed (11)" log.pkg=syncthing)

The problem is that Syncthing’s index has been corrupted. I was able to fix it by getting a shell into the relevant Docker container and moving the index: Syncthing detected it as absent and re-created it, re-indexing everything. Here’s what I did:

docker exec -it syncthing bash
mv /config/index-v2 /config/index-v2-BROKEN

Everything fixed itself immediately and the Docker logs showed the reindex underway.

0 comments

    Reply here

    Your email address will not be published. Required fields are marked *

    Reply on your own site

    Reply by email

    I'd love to hear what you think. Send an email to b28208@danq.me; be sure to let me know if you're happy for your comment to appear on the Web!