A chronological documentation test project, nothing serious, really!

14 Jan 2008 Rename image files according to EXIF date

This rename trick can be run in Windows, Linux and even Mac since the commandline program I’m going to use, exiv2, is available in all three platforms. Rename all image files in current folder to the format YYYYMMDDHHMM_Filename.EXT

This has been tested on my Nikon D80 JPEG and NEF image files.


exiv2 -r'%Y%m%d-%H%M_:basename:' rename $(ls)

Windows (from the command prompt)

exiv2.exe -r %Y%m%d-%H%M_:basename: rename d*

Windows (in a MS-DOS batch file)

exiv2.exe -r %%Y%%m%%d-%%H%%M_:basename: rename d*

You have to add an extra % if you are going to use exiv2 in a Windows batch file, because % in batch files is treated as a variable and not as a switch to exiv2.

These examples require that you have access to the exiv2 program from the current folder.

Now my image files have names like


Change in workflow
Since I rename all my files in the format YYYYMMDD-HHMM_Filename I’ve included it in my image “workflow” (a simple MS-DOS batch file) I wrote about in Rotate images depending on the EXIF orientation post.

This has been tested successfully on the Windows exiv2 version 0.16

The new batch file can be downloaded here.

Tags: , , , , , , , ,

Posted by

08 May 2007 Rule-based DoS attacks prevention shell script

Dette scriptet er ikke testet samt DoS bør hindres på kernel nivå!

A simple rule-based DoS attack-prevention shell script. However, the proposed shell script is not a perfect tool for preventing DoS attacks, but a powerful tool for alleviating DoS attacks overheads of the Linux servers significantly.

Tags: , , , , ,

Posted by