Author Topic: Corrupt CR2 File Assistance  (Read 2234 times)

xcane

  • Newbie
  • *
  • Posts: 2
Corrupt CR2 File Assistance
« on: May 03, 2013, 06:10:53 PM »
https://exiftool.org/forum/index.php?topic=4168.0

I tried to follow the steps in the above mentioned post but was not successful in my efforts.

https://docs.google.com/file/d/0ByE8nFbsnjR0SzkwT3ZDV2psTkU/edit?pli=1

The above google docs link contains a 17MB .CR2 file that has been corrupted, I tried the proposed solution in the other thread, searching for the hex start and end for the image and pasting them into a good CR2 file but it did not work for me.  I think I did it correctly but will not rule out user error.

I would love to know if this file is beyond repair and if not what the repeatable steps would be to fix this one and others like it. I have a couple hundred pics like this that I would love to fix.  I will keep trying but would like to know if it is even possible to fix these images.

Would be happy to "donate" to the cause for any technical assistance.

MOL

  • Full Member
  • ***
  • Posts: 93
Re: Corrupt CR2 File Assistance
« Reply #1 on: May 03, 2013, 11:20:03 PM »
If I were you I would try to retrieve the embedded JPG preview image.  Depending on your camera settings, it is quite large (5184 x 3456 pixel) and the quality is excellent.  Repairing the original CR2 file is an adventure, to say the least.

-Uwe

Phil Harvey

  • ExifTool Author
  • Administrator
  • ExifTool Freak
  • *****
  • Posts: 16878
    • ExifTool Home Page
Re: Corrupt CR2 File Assistance
« Reply #2 on: May 04, 2013, 06:27:16 AM »
I will take a look when I get a chance (tonight or tomorrow morning), but I wouldn't get my hopes up.  Extracting the large preview as MOL said is your best hope.

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

xcane

  • Newbie
  • *
  • Posts: 2
Re: Corrupt CR2 File Assistance
« Reply #3 on: May 04, 2013, 09:35:36 PM »
Would love to try to extract the large preview if possible, like I said, I believe I tried to do this and was unsuccessful.  I have been keeping my programming skills at the at the database and web layer for the past 10 years and have not done this type of work with images in many many years.  Although I did just compile my first COBOL program, seems like I am not moving in the right direction.

I tried using a program called HxD to do the hex editing to try and pull out what I though was the preview.

All I am really looking for is a process to extract the images if possible, not necessarily fix the corrupted file, I will take what I can get at this point.

Thanks for looking into this.

Phil Harvey

  • ExifTool Author
  • Administrator
  • ExifTool Freak
  • *****
  • Posts: 16878
    • ExifTool Home Page
Re: Corrupt CR2 File Assistance
« Reply #4 on: May 05, 2013, 06:47:34 AM »
Sorry to report that I can't find any useful metadata or a preview image in this file.  It looks like total gibberish as far as I can see, so if the rest are like this I don't think you have a hope of recovering anything.

I ran my extract_preview script on it, and it didn't find any embedded JPEG images at all.

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