Using Digikam in a Linux/Mac/Windows environment
Jack Haverty <jack-/[email protected]>
| Newsgroups | gmane.comp.kde.digikam.user |
|---|---|
| Message-ID | <[email protected]> |
For the usual reasons, our IT environment contains a mix of computers including Linux, Mac, and Windows desktops. Digikam runs on all those devices, so I've been figuring out the logistics of making it all work. Success! I figured I'd write it down in case someone else is trying to do the same thing. We have one machine (happens to be a Mac) which is the "master" Digikam machine. The actual photos all live on a NAS, which is configured as a network collection. All changes (adding new photos, tags, etc.) are made on the Mac. The 4 database files on the Mac (Digikam's .db files) are then copied to each of the other machines. I use Syncthing to make that easy and automatic. On each other machine, the goal is to make it possible to use Digikam to search, retrieve, and use the Digikam database, but not to make any changes such as adding photos to the collection or changing tags etc. All changes are done on the master Mac. The challenge hs been dealing with the differences in naming conventions on Windows, Mac, and Linux. I tried various approaches with the "network collections" features of Digikam, but didn't succeed. On the Mac, the network collection was acessible as "/Volumes/photo". On Linux, I could easily mount the NAS photo folder as /Volumes/photo as well, so the Linux Digikam could find photos using the Mac database settings. On windows however, I could mount the NAS photo collection as a virtual disk (I used P: to indicate Photos). But there was no obvious way to create a link from /Volumes/photo to P: -- Windows uses \s, but Mac and Linux like /s. I tried, on the Mac, adding a path to the photo collection for "P:\" but it wouldn't let me do that on the Mac. ChatGPT gave me the answer, and it actually worked! The steps are: On each Windows device running Digikam: 1/ Mount your NAS photo store as a virtual disk (I used P:), and set it to reconnect when you log in so it's always accessible 2/ Using the command line, as Administrator, create a link -- "MKLINK /D "\VOLUMES\PHOTO" "P:\" Result - Digikam on Windows, using the database copied from the Mac, can successfully access the photo files from the NAS. This works, at least for now, because Windows apparently treats \ and / as equivalent when trying to find a file. So /Volumes/photo (from the Mac database) gets used as \Volumes\photo (on Windows). ChatGPT pointed me to several other ways to approach this problem. One way was to use a database on the LAN rather than on the Mac. I could run MySQL, MariaDB, or such on the NAS, and keep the Digikam database there, but I'd rather not complicate the picture with another device needed to use Digikam for basic searching and browsing. I also wanted to avoid problems with situations such as multiple machines simultaneously using the database, or "browsing" clients able to do things like change tags thath the master put in. There was another option to directly edit the Digikam database file to add the Windows path directly, bypassing the checks that prevent adding things like "P:\" while running on a Mac. But that seemed risky and might be undone by some future release of Digikam. I tried using the new "Remap" feature of Digikam. That works but only in the case where each Digikam installation keeps its own database. That's useful but not compatible with the approach of keeping a "master" database on some particular machine. If anyone's interested, my full conversation with the AI is here: https://chatgpt.com/share/6914da04-f3ac-8001-a52b-a68562611b25 There is still one quirk which can be worked around. Whenever Digikam runs, it apparently changes something in the database files. So when I run Digikam on a Windows (or any) desktop, the local database files are modified. Syncthing tries real hard to avoid losing data, and the locally modified database files will not be overwritten when the "master" files on the Mac are changed. It's easy to tell Syncthing to "Revert Local Changes" which makes the master files overwrite the local ones on the Windows (or Linux) machines. But you have to remember to do that to avoid working with an old Digikam database that won't have photos, tags, etc., from the latest updates on the master. I could also solve that problem by avoiding Syncthing and just using rsync to force a copy of the master to each other machine where Digikam will run. Anybody have a better way...? /Jack
OpenPGP_0x746CC322403B8E50.asc
(application/pgp-keys, 2.4 KB)
-----BEGIN PGP PUBLIC KEY BLOCK----- xsDNBGCm2psBDADGOWO8n9wfkDW9ZUEo8o+SZ5MU9us2il+fS4EFM/RaZFIbQ+P7 2bExzSd3WnJdPfqO1O7Q+dRnvVO9+G2/9oT/uRZVaE05+SothzKZBv32HcZoUkdN ZOTqSkdo3EwNPjidLLxX+dMBxMpR3pBdvGN8Z7lnZe6fV4QO2xtd58y3B33AVZJp +RuNwucby9dY2meyy2BJVKrxmKhYXAucVyg0ALVIchHt9UknVW4aLvQF+oMfzXVv CWeguW+DvbyazVceWGO7FSgUJ8ED3Ii7xAR5zZJ1LASoMhG1ixg07P9Uy4ohV6c+ c0yV9SY4yqhZ3+zN2cm9h/aXpwjSuiVVAJbK7zzbFjI+h89dbnaVQrLx6GikV0OV YqC6TCeMfCFZQAJLs1icxQi3BLL7O1fbTGatEfTgLa5nqfKqK/D/HlOCUeFxqZI8 hXvT5dG4e1m3ilpF2/ytc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80WB6jAg8tlJ5VlYlpbzASpJRNj+FL1LLBQxCbPUeFwrzqYgNvtdKR7j 5nTgdndCxq+2aws/aAjdL10S8yeH7ZOpNPzjDJfMSt/L1O25zPUhXdQC9AZNYsfy V7rf+POEgVpIEth1fT9WbmS0rZxRd/+y628n31GicbA+teN890vdABEBAAHCwPYE GAEIACAWIQRku8yfm+a9MCUUQgt0bMMiQDuOUAUCYKbanQIbDAAKCRB0bMMiQDuO UF1LC/4q4pLtmDt6TIET2H7zGj5ie3ng7kC7YqtFPYwgLQzs9WeqQ/5WowEmHOPo nBcqhGbtDj22GebQ7w0RoUHb+aXsbC85I/C+nWgT1ZcfMBTHGlBcIQvOCNG18g87 Ha9jgD0HnW4bRUkZmGMpP0YdTLM+PBNu41AK6z82VPQrfTuPKqwAAS2FK/RpF2xB 7rjpETzIPl9Dj9EAkRbviURIg0BQkmejl02FLzGmlTfBIDHBdEgzvD71Z5H9BP8D AbxBzonSTzx/KZyv7njSUzdVLW+5O/WzPgb4Qt4IjQd66LS9HWS1G7AcLjiSQAIf 8v7JkX3NwtN+NGX5cmt2p0e9FOOKWXVgCIgPN3/712EEGAgqUUxuPEBD5DrRCgjZ L40eHxQza2BAhoVoWopUCGZdCCZJP3iF7818wIph0U393DELG9NAGLJaqkoA8KBi mXp9Rd2QvpA864JRy/REoEOEF9lm3clriLyEqaL/VMIQRhl/VSkUuez4Wr68eHus TFdwePg= =1/9g -----END PGP PUBLIC KEY BLOCK-----
OpenPGP_signature.asc
(application/pgp-signature, 665 B)
-----BEGIN PGP SIGNATURE----- wsD5BAABCAAjFiEEZLvMn5vmvTAlFEILdGzDIkA7jlAFAmkU4eAFAwAAAAAACgkQdGzDIkA7jlAj gAv/b8fouel7ZeTKFfKpUYg6AypbcPEeNz0VJ/l/Ku6nJ73bVC4x1898UyRCIimtJVBMtHlrVPjX gWAdrDb4KxsKyxMd1Ge11/mCWvmjklM2GQDhUcePVB+2wvSeVGxBfhg3SfRmwXL3T2Q6g0UYG/N/ 5IQ+UJhxS62CRknbpSuBXRgq5zTSrg0ElrTAopq/Yu7xX5wqFvXbvoosODbX5mLzVxa/rdjywUIK Zp204nNFBcmtycub7bqfSFnPzGUH+K1MfGf3snbwUYW3Nzc6qXf3+mpnrLyQijHPfRYw4aRP3jnn M2+BxHJ/0Uqpopvv6NprnLkrgl1LZmdVvLvXYuJ0NJL1rAOF9XeOXZtXUfnk56jTq0rzq87mVF37 2RORNxp9cePi8OONq+QA86JJe1asD5/+GBwNKPzYJQzLN9vSbb39Ce1yrLsbZQDy95T9zyr9tlxN Qp3Wrzk3jK8nguGhowQSemVMHzKUTuWV1R2xrnjD51AIxKECSxVlVebD+iRX =5WB+ -----END PGP SIGNATURE-----