ExifTool on Linux - Unexpected Warning about MD5

Started by Mac2, December 20, 2021, 09:25:52 AM

Previous topic - Next topic

Mac2

I usually use ExifTool on Windows, but today had to use it on Linux for the first time.
I followed the installation instructions from the ExifTool web site and all worked well in no time.

I test the same set of JPEG files on Windows and Linux. Metadata is extracted on both platforms just fine.
But on Linux I see two additional warnings (reported via stderr):

IPTCDigest is not current. XMP may be out of sync
Digest::MD5 must be installed in Photoshop:IPTCDigest


I'm quite sure that I have never seen these before (?) so I wonder is something in my ExifTool installation missing? Or just some Linux thing?
Google did not return anything useful.

The args I use can be seen here: https://exiftool.org/forum/index.php?topic=13119.0

Phil Harvey

Digest::MD5 is an optional package that may not be installed on all systems.  You'll have to install this yourself if you want to use it.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

StarGeek

Depending upon your Perl installation, you would run either of these in a shell/terminal
cpanm Digest::MD5
or
cpan Digest::MD5
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

Mac2

Thanks for your help. Unfortunately, no luck.

I run ExifTool in a Docker container based on Microsoft WSL2 / Ubuntu.
perl -v returns This is perl 5, version 28, subversion 1 (v5.28.1)

I get "command not found" for both commands.
I now know that cpan is a Perl package manager, but it seems to be missing from the WSL2 distro.
Googling only results in the typical circles and mix of outdated or unrelated info, not working examples etc.

I will have to dig into that soon, but not now. I can live without MD5 digests in ExifTool for now.

Phil Harvey

You might want to do exiftool -ver -v to see if you are missing any other optional libraries:

  Archive::Zip         (ZIP, DOCX, PPTX, XLSX, ODP, ODS, ODT, EIP, iWork)
  Compress::Zlib       (DNG, PNG, PDF, DCM, MIE and SWF files)
  Digest::MD5          (PDF files, IPTC information, and JPG Extended XMP)
  Digest::SHA          (PDF with AES-256 encryption)
  IO::Compress::Bzip2  (RWZ files)
  Time::HiRes          (for generating ProcessingTime tag)
  POSIX::strptime      (for inverse date/time conversion)
  Time::Piece          (alternative to POSIX::strptime)
  Unicode::LineBreak   (for column alignment of alternate-language output)
  Win32::API           (for proper handling of Windows file times)
  Win32::FindFile      (for Windows Unicode directory support, app only)
  Win32API::File       (for Windows Unicode file names and file times)
  IO::Compress::RawDeflate   (for writing FLIF images)
  IO::Uncompress::RawInflate (for reading FLIF images)


- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

Mac2

Looks sad. None of these installed.

Well, I just need more digging and learning. I'm new to Docker and WSL and Perl and only slightly experienced in Linux.
I'm sure I'll figure this out in a couple of days and learn how to setup my DockerFile so all this stuff is included in my test image.

At least I can run ExifTool from .NET, extract metadata, ingest the resulting JSON file etc. That's good enough for a day  ;)


Phil Harvey

Sounds like a minimal Perl installation.

The good news is that none of these optional libraries are really necessary unless you care about the specific feature that they enable.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

StarGeek

Can the docker container see a .exiftool_config file?  If so you could try downloading the module and then add a statement like this to the top of the config file.  It this case, I have all the Windows strawberry perl lib locations included
BEGIN{ push @INC, 'C:\Strawberry\perl\lib'; push @INC, 'C:\Strawberry\perl\site\lib'; push @INC, 'C:\Strawberry\perl\vendor\lib'}
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

Phil Harvey

The problem with this are module dependencies.  Sometimes you have to install a number of modules just to get one working.  This is why I designed ExifTool to work without needing any other modules (which is why they are "optional").  This is also why package managers like cpanp exist.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

Mac2

Thanks to all for providing useful info and suggestions  :)

I managed to get it working. Learning about Linux while learning about Docker... ::)

I've had to install make, gcc, built-essentials and then cpanminus.
Then I could install the missing Perl modules ExifTool needed for my usage scenario.
Then I could download ExifTool, unpack, run the MakeFile and tests to get ExifTool, following installation instructions

No the MD5 warning is issued anymore when processing the files, so I guess that's that. Another step forward!

Just for reference, if somebody else tries to do the same (change 12.38 to whatever ExifTool version is current):

apt update
apt-get install gcc
apt-get install make
apt-get install build-essential

apt-get install cpanminus
cpanm Digest::MD5
cpanm Archive::Zip
cpanm Unicode::LineBreak

cd /tmp
curl -o Image-ExifTool-12.38.tar.gz https://exiftool.org/Image-ExifTool-12.38.tar.gz
tar -xzvf Image-ExifTool-*.tar.gz
cd Image-ExifTool-*
rm -rf Image-ExifTool-*.tar.gz
cd Image-ExifTool-*
perl Makefile.PL
make test
exiftool -ver -v

Keywords: Microsoft Windows WSL2 Ubuntu install ExifTool install Perl Modules

Phil Harvey

Thanks for posting your complete solution.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

StarGeek

Optional change, based upon what I could find on StackOverflow
cd /tmp
ver=$(curl -s https://exiftool.org/ver.txt)
curl -o Image-ExifTool-${ver}.tar.gz https://exiftool.org/Image-ExifTool-${ver}.tar.gz
tar -xzvf Image-ExifTool-*.tar.gz


I haven't tested it because I can't figure out how WSL works.

And I like the light grey keywords below your post.  I'm going to have to check google in a few days to see if it helps.
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype