Hello,
I need some advice on synchronzation with multiple devices.
I have a shared folder with images which is synchronized with two computers and a smartphone. New images are uploaded outside of darktable on the two computers and on the smartphone. The image folder is managed by darktable on the computers inkl. sub folder structure for film rolls.
Now I like to synchronize the darktable meta information. I learned that it is not feasible to synchronize the sqlite database directly, but rely on the information in the XMP files instead.
To further break down the problem I identified three use cases:
- Images have been deleted on one side
- XMP files have been changed
- New images have been added
For case 1 I could not find any builtin database cleanup, but the dbmaint lua script could do the trick.
For case 2 I could enable the setting “storage - look for updated XMP files on startup”. Although there could be a performance impact when the database keeps growing.
But how could I catch case 3?
First I just re-import the same folder manually. The “add to library” dialog automatically selects the new images. Existing XMP files are not touched. However the flipside is that this is a manual task: I need to go through all filmrolls manually and select the correct folder on disk.
So I wrote a lua script which loops over all film rolls and does a dt.database.import for each film roll path. That basically worked.
But when I added an image which already has an XMP file (because darktable on computer A already imported it) then on computer B the field “darktable:import_timestamp” is updated darktable automatically detects the changed (XMP timestamp vs. database timestamp) an shows the dialog to update the database.
Is there a better workflow when working with multiple computers?
Regards
Georg