Fedora 39 WS (Running on a 2014 imac, beautifully I might add!!)
I have a 650GB Photos/iPhoto database from Mac. I want to import those into Fedora. I haven’t found a suitable photo viewing app yet so just want to move all photos into the Pictures folder in Fedora. I am unsure but last time I unpacked the Photos database on Mac, it had various folders (thumbnails, originals etc). I don’t have a working Mac currently to play around with it.
Just wondered if anyone had any ideas for how to go about this using Fedora and a connected ‘Clone’ backup of my old mac?
thanks
Looking at Photos on my mac I see that all my pictures are in a single big file, as you describe.
What seems to be required is to open Photos app, select all images and choose Export Unmodified Originals
to get a set of files.
Are you saying you do not have macOS to do the export from?
Thanks very much. Yes, currently I have no Mac OS to use, so I may have to get more creative. ALthough it sounds messy and in a day or two I should have mac os Ventura running (huge thanks to OCLP for that!) on an old imac, so I could import the photo library file there and do as you suggest
I have a Mac set up now and trying your suggestion. I tested it on 1000 photos (before doing 60,000!). It seemed to work, except I seem to have lots of duplicates, 3 copies of all. Very weird.
Before I pay (yuk!) for software to remove Photos app duplicates, before export, is there a way to remove duplicates in Fedora very easily? I think Shotwell is the app I will be using but not sure yet (and this question may change that decision!)
Of the top of my head i would generate a hash for each file, sha256.
Then only keep one file for each unique hash.
ha, er, ok. thanks!
Since you have duplicates, @barryascott suggested to use hashing, a technology used (among others) for file integrity. Running a checksum command (such as sha256sum or md5sum) on your photos would generate for each photo a 256/128-bit string, which uniquely identifies file contents. Two identical photos (i.e. duplicates) would have the same checksum.
You can test this by running the commands md5sum /path-to-your-file/file1
and md5sum /path-to-your-file/duplicate-to-file1
, and would obtain the same generated checksum.
Now comes the interesting part. There is a command line utility, called fdupes
(available in the repos), which can identify duplicates based on hashing algorithm, and also remove them. Please see the man page to see its use.
To list duplicates you can run the command:
fdupes /path/to/your/photos/ -r
(-r means to check subfolders recursively, ignore if not needed)
To list and delete duplicates interactively:
fdupes /path/to/your/photos/ -rd
(see help command for syntax when using interactive mode)
To list and delete duplicates without promting the user for confirmation:
fdupes /path/to/your/photos/ -rdN
Powerful yet easy, but data loss possible if not used correctly. Please test on a subset of data first.
Added macos-transition
Are they real duplicates or different resolutions (or some other property like, color models, and compression methods)? There are lots of command-line linux tools to display properties of images.
Fascinating thank you! I can see how useful that could be in so many ways!
I may have a play around, but I have now imported the photo library to another Mac (with newer OS and it appears the newer versions of Photos app have a “Remove Duplicates” function (as well as a load of trash which is why I left Apple!). I may see if that can sort it before importing a fresh bunch of files into Shotwell.
Thanks very much for the help on this thread.