I have a collection of around 35.000 JPG's and 5.000 NEF files. Previously I imported and "organized" this bulk load of pictures using RoboImport. It quite fitted my workflow as I could give it almost every name possible depending on the attached (EXIF) metadata.

Recently I got myself an extra hard drive to have as main photo drive, aiming to use the old one as a backup. I took the opportunity to create a new naming scheme separating the NEF files from the JPG's. This way I could have Windows Live Photo Gallery for only the JPEG part, preventing double images in the gallery.

However, Roboimport always has been stable, but with the biggest bulk, the NEF and JPG files from my dSLR, the app chokes around 1/5th. It crashes, and I can't really resume it, as it didn't exactly transfer the images chronologically.

What is a good application also capable of moving around files based on metadata. Doesn't have to be sophisticated, as I am using applications like Picasa etc to actually browse my collection. Linux is be preferred, as this is the OS I spend the most time on, although I have Windows on the same machine.

  • 2
    \$\begingroup\$ Meh. It's not Reddit here, you don't need the tl;dr-meme. \$\endgroup\$
    – Leonidas
    Commented Apr 5, 2011 at 20:31
  • \$\begingroup\$ Hmm, I'm to used to StackOverflow :] \$\endgroup\$
    – Dykam
    Commented Apr 6, 2011 at 14:24
  • \$\begingroup\$ See also photo.stackexchange.com/questions/2138/… \$\endgroup\$
    – mattdm
    Commented Apr 6, 2011 at 14:47
  • \$\begingroup\$ Try out Shotwell, I think you will be pleasantly surprised. \$\endgroup\$
    – labnut
    Commented Apr 6, 2011 at 17:52
  • \$\begingroup\$ I updated to the latest Shotwell, and it indeed now covers RAW files as well. That will probably be my choice if nothing else shows up. Another possibility is doing it manually based on exiv2 output, it will take some time however to write it. \$\endgroup\$
    – Dykam
    Commented Apr 6, 2011 at 21:13

4 Answers 4


Exiftool is a very powerful utility to sort and organize photos automatically. See RENAMING EXAMPLES section of its manual.

A new directory can be specified by setting the value of the Directory tag. For example, the following command moves all images originally in directory "DIR" into a directory hierarchy organized by year/month/day:

exiftool "-Directory<DateTimeOriginal" -d "%Y/%m/%d" DIR

To move and rename files you may also use -filename option. For example, to sort images by file type, year, and date and time when they were taken you can run:

exiftool -d '%%e/%Y/%Y%m%d/%H%I_%%f.%%e' '-filename<DateTimeOriginal' YOURDIR

Then a file in YOURDIR named like imgp1234.dng taken on May 20th, 2011 at 08:01 a.m. will be moved to folder dng/2011/20110520/ and renamed as 0801_imgp1234.dng.

Attention, please, that exiftool moves only images, so if you have sidecar files along with your RAW files, you need to take care of them somehow. If some of your photos lack EXIF data, they will not be moved this way. Add option -r to process YOURDIR recursively.

  • \$\begingroup\$ Looks exactly like what I need, though what does the '-filename<DateTimeOriginal' flag do? It seems -d is supplying all the information. \$\endgroup\$
    – Dykam
    Commented May 21, 2011 at 15:00
  • \$\begingroup\$ @Dykam The main purpose of exiftool is to read and modify image metadata. Syntax -DSTTAG<SRCTAG tells it to copy metadata from SRCTAG to DSTTAG. -filename acts as a tag to change (in effect, renaming a file), DateTimeOriginal acts as a source tag (actual metadata); -d specifies date format (and allows for some extensions, like %%f, %%e). You can also use CreateDate, FileModifyDate and ModifyDate too. \$\endgroup\$
    – sastanin
    Commented May 21, 2011 at 21:06

While you can find several "automator"-style programs for Linux (there's also one specific for working with images, though I can't remember the name off the top of my head).

But if you really want something advanced (and possibly cross-platform), I believe your best option is to develop something yourself. Personally, I quite like Python for such tasks (good with data management, cross-platform &c) - but you may have other preferences.

  • \$\begingroup\$ Hmm, that might work out indeed. I was a bit concerned about performance, python isn't exactly the fastest language, and it quire quite some gigabytes of pictures. But the bottleneck is IO probably, so if programmed correctly it'll be only limited by that. \$\endgroup\$
    – Dykam
    Commented May 19, 2011 at 20:15
  • 1
    \$\begingroup\$ Something reading the EXIF should not need to read the entire file, and if it's on the same filesystem a move will not touch the data at all. I/O shouldn't be an issue at all. \$\endgroup\$
    – Cakemox
    Commented May 20, 2011 at 20:49
  • \$\begingroup\$ Hmm, indeed, forgot I could delegate moving to the native tools. \$\endgroup\$
    – Dykam
    Commented May 21, 2011 at 14:58
  • \$\begingroup\$ Moving files around should be a fairly cheap operation (if source/target reside on the same disk, it's just moving a pointer somewhere). Otherwise, Python (and most other languages) provides tread-safe queues and thread-pools to easily deal with that sort of thing. \$\endgroup\$ Commented May 23, 2011 at 8:32

Renaming the files bases on EXIF/IPTC can be done by XnView under Windows and it is stable enough for my several GB (sometimes after a vacation). As you can search for EXIF/IPTC you could move them based on the metadata - but moving and renaming at the same time not.

find /path/to/photos -type f -name "*.NEF" -exec mv {} /path/to/destination/ \;

This command will find all files that have the extension "NEF" and move them to the specified destination (one at a time). You can repeat this for your jpeg files too.

  • \$\begingroup\$ That does only split out the NEF, I prefer if it is possible in one step. It is however part of the toolkit, thanks. \$\endgroup\$
    – Dykam
    Commented Apr 6, 2011 at 21:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.