Bug 189362

Summary: After moving the collection on a new HD, Digikam doesn't find it
Product: [Applications] digikam Reporter: Frédéric COIFFIER <frederic.coiffier>
Component: Database-MediaAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: caulier.gilles, marcel.wiesweg
Priority: NOR    
Version: 0.10.0   
Target Milestone: ---   
Platform: Gentoo Packages   
OS: Linux   
Latest Commit: Version Fixed In: 7.0.0
Sentry Crash Report:

Description Frédéric COIFFIER 2009-04-11 12:44:43 UTC
Version:           0.10.0 (using KDE 4.2.1)
Compiler:          gcc (Gentoo 4.3.3-r2 p1.1, pie-10.1.5) 4.3.3
 
OS:                Linux
Installed from:    Gentoo Packages

On Linux, I have added a new disk and I have changed the mouting point where was stored my collection. So, the collection is in the same directory but on a new disk.
When I start Digikam, it doesn't find it and I loose all my thumbnails, album dates...

Is there a way to associate a new path to an old collection ?
Comment 1 Marcel Wiesweg 2009-04-11 18:04:59 UTC
I would like to mark this as duplicate for 175923 because it requires the same solution.

digikam will find your partition by the UUID and store the path from that partition's mount point on (mount point is not relevant).
In the absence of a nice tool to do the job, and if you want to keep your album thumbnails descend to the digikam4.db database file and change the UUID of your old disk to your new partition's one. Something like
UPDATE AlbumRoots SET identifier='volumeid:?uuid=...' WHERE id=...;
Ask back if it doesnt work

Completely different: You cannot do much about the image thumbnails if the _mount path_ changed (They are stored by path hash. In fact, it is possible to write a script that takes the old path and the new path, the hashes and renames the thumbnails. I dont know of such a tool so far)

*** This bug has been marked as a duplicate of bug 175923 ***
Comment 2 Frédéric COIFFIER 2009-04-11 18:53:00 UTC
Yes, I solved the problem by dumping the database with sqlite3 and by replacing the old disk UUID by the new one.
It works but it's not really user-friendly (In my case, as my mount path hasn't changed, I retrieved all my thumbnails, album dates...).
Thank you for your quick answer (and as usual, for your work).
Comment 3 caulier.gilles 2019-12-29 22:29:25 UTC
Not reproducible with 7.0.0 beta 1.