"Checking db due to upgrade" stuck for days

One of my machines in a syncthing shared folder seems to have gotten an automatic upgrade, but is unable to start syncthing anymore. The log shows that it’s “checking db due to upgrade”… and while it’s understandable that it may take a while, it doesn’t make sense that it’s taking days.

Also, task manager in Windows doesn’t report any disk or CPU activity from the syncthing process, leading me to believe that it’s stuck somehow

I am using syncthing under SyncTrayzor. The syncthing version is 1.6.1. Based on the logs the previous version was 1.5.0

I’m mostly wondering if I can safely delete the database file and have syncthing regenerate, or if it is risky. If I understand correctly, the database file only holds a cache of file indexes and things like that, right?

That’s odd, but perhaps tricky to debug in the current setup. You could try a restart to see what happens, the db check should finish in seconds generally. There might be an I/O error or something similar making reads take a long time.

Removing the database is safe-ish. If you have changes on both sides you should get conflicts and will have to clean those out. If you have deleted files but that hasn’t synced to the other side, those will probably be revived. Might be other corner cases.

Would like to mention that I have tried rebooting the machine a few times. But I still get the same issue. My only conclusion is that the database got corrupted somehow and needs a reset.

So I’ll go ahead and delete it and see what happens.

I’m not sure how, but the issue seems to have fixed itself. It’s not a machine I am constantly using (rather it’s just running in the background), so I don’t really know the details of what happened unfortunately. I think a reboot seems to have resolved it somehow. The log file shows that on the last start, the “check reboot” step took at most 20 seconds (that’s the time difference between it and the next log entry).

Can’t explain it. Oh well…

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.