[Digikam-users] BUG? move to album / overwrite destination problem

John Stumbles john at stumbles.org.uk
Wed May 16 09:16:49 BST 2012


On 16/05/12 05:07, Remco Viƫtor wrote:

> I think it's actually the hard linking that causes the problem:
> Digikam sees that the file you want to copy to exists, asks for permission to
> overwrite, and then tries to open that file for writing, truncating the
> contents. But that file is also opened for reading through the other file
> name...

I just checked and dolphin has the same problem so it's really a bug in 
kde. Maybe I'm missing something but overwriting - bitwise copying - one 
file to another in order to move it seems like a really stupid thing to 
do! I wonder why kde doesn't actually do a `mv` when the source and 
destination are on the same filesystem? Maybe it was a bit of q&d coding 
(saving having to check whether a mv is possible) that hasn't been 
refined? (I know: it's open source, I should fix it myself instead of 
complaining about it! But it's not like a little C file: there's a huge 
learning curve to get up to start hacking on something like kde ... 
would take me months to get going :-()


> You seem to use the hard links to avoid making a temporary copy.

One of the main ways I enjoy my photo collection is having my better 
pictures displayed on kde's slideshow screen-saver when my PC is idle. I 
acheive this by, when I've uploaded a set of photos containing some I'd 
like to have on the screensaver, I `cp -rl` the album to a directory in 
the tree the screensaver accesses; then I go through images in that 
directory deleting poorer ones and tweaking the better ones. So now I 
have one directory tree containing all my pictures, good and bad, and 
another tree ("show") containing only good ones, including some edited 
versions that aren't in the original tree. And since the "show" tree 
contains a significant amount of images, using hard links saves a 
worthwhile amount of space.

Now I've started using digikam I'd like to merge the "show" tree back 
into the originals tree. I could just copy (or hard-link) images in each 
album in the show tree back to their corresponding albums in the 
original tree but, since the photos in the "show" tree are all good, I 
can quickly star-rate them all and save myself having to re-rate all the 
pictures in the new, merged, tree.


> Is the use of hard links really worth the hassle and savings on disk space,
> even with your snapshot backups?

Definitely with the snapshot backups: I've only got a 2.5TB drive 
backing up a 3.5TB array! Obviously it's not backing up everything on 
that array (I exclude DV videos for example) but even so I have to be 
careful what I do back up. Of course a de-duplicating file system (e.g. 
ZFS) would be the ideal: I did try setting something up but couldn't get 
whatever it was (I forget now) working.



-- 
John Stumbles                                    http://stumbles.org.uk
:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:




More information about the Digikam-users mailing list