[Digikam-users] Batch rename of albums best practice

Johnny yggdrasil at gmx.co.uk
Sat Sep 3 12:45:22 BST 2011

When I started using digikam, I was ignorant of "safe" filenaming
conventions and consequently have lots of silly characters (non-ascii
such as spaces and brackets), mainly in albums but also in a few
imagenames. I want to find and replace these names with minimal hassle
and wonder what is the best practice?


My first attempt was to simply open digikam (I think this makes the
database change-aware, right?) and from the shell (i.e. emacs dired
mode) do a find and replace on the filenames. This was instantaneous,
and it seemed digikam picked up the changed. However, digikam became
incredibly slow and after a few minutes, I just stopped and restarted
digikam. Upon restart, it didn't recognise the database and additionally
became unresponsive, so I killed digikam from the shell. I found two
digikam processess and killed both - in retrospect I suspect maybe one
process was from the initial digikam session and it was updating the
database, and hence kept it locked from the second digikam process. 

Now, this was several minutes after I did the initial file renaming, so
the question is why, if my guess is correct, digikam was so incredibly


I recovered from my backed up database, but now directory names were
misaligned in the database and on the filesystem, so I had to manipulate
the database directly. Using sqlite3 from the command line, I did a find
and replace operation in the database - this was practically instant,
hence the query why digikam does this slowly (again, if this is really
what happened)? Now, restarting digikam, everything is back to normal
/and/ the albums are renamed. While this is doable, it is somewhat of a
workaround, are there better ways to do this?

If anyone is inclined to try my method the steps are as attached.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: digikam_rename_albums_workaround.txt
URL: <http://mail.kde.org/pipermail/digikam-users/attachments/20110903/f57bcc01/attachment.txt>

More information about the Digikam-users mailing list