Lightroom: Some jpegs can not be exported in 'Original' format.

  • 1
  • Problem
  • Updated 7 years ago
Several dozen of my jpegs can not be exported in original format. They can be exported in jpeg format or whatever, just not 'ORIGINAL'.

I don't see anything special about them, nor can I find anything wrong with them (they look OK in a hex editor, they are viewable just fine in Lightroom and out, and pass ImageVerifier scrutiny...), EXCEPT: I can not write metadata to them (via Ctrl-S or 'Save Metadata to File' menu item). I can read metadata from them OK.



error message: updateMetadata: dng_error_bad_format
Photo of Rob Cole

Rob Cole

  • 4831 Posts
  • 379 Reply Likes

Posted 7 years ago

  • 1
Photo of John R. Ellis

John R. Ellis, Champion

  • 3587 Posts
  • 927 Reply Likes
Can Exiftool write metadata to them? In my experience, if a file's metadata is not completely kosher, Exiftool will sometimes report "minor" metadata format errors when you try to write but not when you read.

Is this a permissions issue?

Perhaps post one here and see if someone else can replicate in their LR/OS configuration.
Photo of Rob Cole

Rob Cole

  • 4831 Posts
  • 379 Reply Likes
Probably a metadata issue - most if not all were previously written by ACDSee.

ExifTool complained about maker-notes offset, but -F command to fix it only made ExifTool happy, not Lightroom.

Example:

Photo of Rob Cole

Rob Cole

  • 4831 Posts
  • 379 Reply Likes
Oops - the problem with this one was the read-only attribute was set. See below for example of problem with same symptoms but due to funky exif metadata.
Photo of John R. Ellis

John R. Ellis, Champion

  • 3587 Posts
  • 927 Reply Likes
Interesting -- with that pic on my LR 3.5, Windows 7, I'm able to Save Metadata To File and Export as Original.

Also, if I set the file permissions to read only, Save Metadata To File fails silently with no error message (seems like a bug).

This suggests that maybe the problem is with the particular metadata that LR is trying to write to the file? What if you import the file into a fresh test catalog?
Photo of Rob Cole

Rob Cole

  • 4831 Posts
  • 379 Reply Likes
Interesting - I tried importing same photo in new catalog and had same problem. But I saved from web (binary equal but with new name) and imported and did not have problem. i.e. I can make a copy of the file with a new name and the copy does not have the same problem. However, if I change the 'File Name' in Lightroom, it still has the same problem!

Anyway I've got a way to fix the problem, although I still don't have much clue what's causing it, other than the filename...

PS - I *definitely* agree that there should be a clear indication of what went wrong when attempting to save metadata to a read-only file.
Photo of John R. Ellis

John R. Ellis, Champion

  • 3587 Posts
  • 927 Reply Likes
I wonder if it's an obscure permissions issue. I've never taken the time to really understand Windows ACLs. But over the years I've encountered strange behaviors that required me to figure out how to use "cacls" just enough to reset the ACLs of thousands of files (e.g. when I migrated from XP to Vista).

I'm guessing these problem JPEGs may have migrated from older versions of Windows or from other computers?
Photo of Rob Cole

Rob Cole

  • 4831 Posts
  • 379 Reply Likes
Sorry - I had two different kinds of problem photos (identical symptoms, but different error message). One was due to read-only attribute (the one I posted above - oops). The other was due to exif metadata problem (posted below).

Note: I fixed this image thusly (dscn0032.jpg had problem, dscn0031.jpg did not):

- exiftool -all:all= dscn0032.jpg -tagsfromfile @ -all:all -F (fixes maker notes despite bad interopIFD directory - removes all tags and rebuilds exif metadata from all readable tags.
- exiftool dscn0032.jpg -tagsfromfile dscn0031.jpg -interopIFD:InteropIndex (copy desired interopIFD tag or any other unreadable tag from a non-problematic image - beware to copy only compatible values, otherwise set manually if you can figure out what to set them to).
- exiftool dscn0032.jpg -tagsfromfile dscn0031.jpg -interopIFD:InteropVersion (ditto, etc...)

Photo of John R. Ellis

John R. Ellis, Champion

  • 3587 Posts
  • 927 Reply Likes
Any idea where the metadata problems came from?
Photo of John R. Ellis

John R. Ellis, Champion

  • 3587 Posts
  • 927 Reply Likes
Also, I sure wish LR (and other applications) would include "more details" in their error messages that bubble up from deep inside layers of abstraction. Think about how much time we waste trying to figure out the reasons an application command files, simply because the programmers didn't bother to pass detail up from the lowest levels. In this case, if the error message said "Can't save metadata (can't open file for writing)", or "Can't save metadata (ExifIFD is malformed)", that would have saved you a fair bit of time narrowing down the problem.
Photo of Rob Cole

Rob Cole

  • 4831 Posts
  • 379 Reply Likes
I don't know where the problems came from. My first guess would be ACDSee, but that begs the question why more of their neighbors don't have the problem (also processed with ACDSee).

Indeed a better error message would be helpful.