Skip to content

[BUG] Docker starts "successfully" and loops forever when sqlite database is corrupt #100

@evan

Description

@evan

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

I had a hard container shutdown (on Unraid) and my sqlite database got corrupted somehow. When the container restarted it started "successfully" but actually was looping this error forever:

2026-02-03 10:38:41 INF syncthing v2.0.14 "Hafnium Hornet" (go1.24.12 linux-amd64) root@buildkitsandbox 2026-02-03 09:33:54 UTC [modernc-sqlite, noupgrade] (log.pkg=main) 2026-02-03 10:38:41 ERR Error opening database (error="openbase (PRAGMA optimize = 0x10002): database disk image is malformed (11)" log.pkg=main)

Expected Behavior

Container should fail to start instead of getting stuck in an error loop.

Steps To Reproduce

  1. Install container
  2. Corrupt index-v2 sqlite files
  3. Restart container

Environment

- Unraid 7.2.3
- Syncthing v2.0.14, Linux (64-bit Intel/AMD Container)  
- Docker installed via Community Applications

CPU architecture

x86-64

Docker creation

Community Application template defaults

Container logs

2026-02-03 10:38:41 INF syncthing v2.0.14 "Hafnium Hornet" (go1.24.12 linux-amd64) root@buildkitsandbox 2026-02-03 09:33:54 UTC [modernc-sqlite, noupgrade] (log.pkg=main)
2026-02-03 10:38:41 ERR Error opening database (error="openbase (PRAGMA optimize = 0x10002): database disk image is malformed (11)" log.pkg=main)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Issues

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions