Error while opening database / Fehler beim Öffnen der Datenbank

Hey there,

I have the following problem:

Darktable won’t open but instead show this message:

For those who don’t know German (basic translation):

"There’s a mistake while trying to open database [filepath]. Probably database is damaged. quick_check shows: […]

How shall we go on?

  • close darktable now to restore the database manually from a backup.
  • Try an automatic restoration frfom recent database snapshot.
  • Delete the damaged database in order to start with a new base."

No matter if I click on “restore” or “delete” this windows opens once again.
How to restore the database manually from a backup - I have no idea.

However, I cannot use darktable at all and that sucks!

Some information that might help:

  • I’ve installed the latest version of darktable before this error.
  • Recently, I cloned my HDD onto an SSD. Afterwards, I exchanged the hard drives. This was a success, but worked not perfectly. Some apps including darktable struggle to work problem-free: I now have crashes more often than before. Mostly, I have errors with OpenCL, but I don’t have much knowledge about this.
  • I’ve already read some articles with similar problems but neither found my exact problem nor understood what was going on there… :frowning:

I appreciate every sort of assistance and will be here to answer any sort of questions.



In the path shown rename the darktable folder to something else and see if a fresh start works.

Yep, Windows :slightly_smiling_face: :gun:

So you mean I should rename this folder to anything?
Why and what is this supposed to change?
I’m just curious and sceptical because I don’t want to destroy my whole PC… :sweat_smile:

It will simply reset darktable to its default state. The folder contains all configurations.

This is simply to verify that darktable itself still works. Any photo edits are NOT in this folder.

There is no data loss, you can always revert the change.

The procedure to repair a broken database is much more involved, I assume a fresh start is good enough.

I did it and it worked as you described it. Unfortunately, styles, layouts and all that is missing as well, but since this program worked so horribly in the past two weeks this was propably the best possibility to chose.

Thank you a lot :handshake:

1 Like

That may indicate errors during data transmission, or a faulty destination drive. Do you have any tools to test the disk (SSD)? And/or to check its SMART values?

Much of that is in your data.db… you could try copying your old one over… if the issue was in your library then you might still have all the styles… you should also maybe have some backups to work with??

1 Like

See Synchronize Settings between multiples devices - #3 by kofa.
Adding to that: the preferences you can set from the UI are (mostly?) in darktablerc.

1 Like

How do I test on errors?

You can type that into any search engine to get links like

1 Like