Gear / Technical Help > Photo / Video Recording

How to fix a corrupt MDT file from a Panasonic ZS100 camera on a Mac

(1/1)

ol' dirty taper:
The other night my camera shut down from excessive heat and I was left with a corrupt .MDT file, rather than a .MP4, on my Lumix ZS100.

I spent all day scouring the internet for methods on how to retrieve the data from the 39 GB file and here is the combination of methods I landed on. It may be others know of better ways to achieve this.
______

STEP 1

First you will need to prepare your files. Move the file from your SD card to your HDD. Duplicate the corrupt file in a folder on your HDD. I went with P1000_2.mdt and P1000.mdt.

Open Terminal

Change directory to the folder container your files, if on an external drive, you will need to use the command :

--- Quote ---cd /Volumes/(drive name)
--- End quote ---
followed by

--- Quote ---cd /(folder)
--- End quote ---

Using the cat command, you want to have something like this :

--- Quote ---cat P1000.mp4 P1000_2.mdt > (your file name).mdt
--- End quote ---

This will create a single file that you need for the next step. It may take awhile, mine ran for about twenty min before the terminal produced a complete file, just let it run until the terminal prompts a new command line.

STEP 2

Download this app when Terminal is finished : https://main.grauonline.de/video-repair-tool/

Open mac start.command in the folder that was downloaded. It will open the terminal and possibly ask your admin password, once entered it will open the app and ask for a language.

Once opened, on the left column you have Repair, Batch, Options etc. You want to be on the Repair tab.

Where it says choose movie, this is where you select the file we created earlier using the Terminal.

It asks for a reference movie next, hopefully you have another video from this camera to use. Pick any file created using the camera, not sure if same settings matter or not, I had other shows on my SD card.

Next go to the Options tab.

Basically uncheck everything on Stage 1 and leave the top pull downs alone.

Go back to the Repair tab, hit Scan, and let it run.

The app will create a folder called "repaired" in the same folder the video is in.

Once completed, the app will produce a .MDT file that you can promptly just rename to .MP4

At this point you have a video that has choppy playback intermittently, maybe weird artifacts on the screen, do not worry.
(It's worth noting that at this point, VLC will play the file perfectly fine, but I was unable to configure any settings on VLC's Convert/Stream that would result in anything different than the same choppy video, it's probably possible, but I gave up)

STEP 3

Download this app : https://handbrake.fr/

Open the app, select Open Source and go to the folder with the repaired .MP4 file we created in Grau.

Select the preset that matches your video, I went with HQ 2160p60 4K HEVC, but modified the output.

Under Summary, I selected MP4 and checkmark on Align A/V Start, though, the sound in my case isn't necessary, I line up the video to a separate audio source.

Next tab for Dimensions I left alone.

The Filters tab I left alone, but you should have Interlace Detection set to Default and Deinterlace set to Decomb

The next tab is Video, I have selected for Video Encoder H.265 10-bit (x265) and Framerate set to my cameras 30 FPS, Peak Framerate is checked. For Quality, Constant Quality is checkmarked and my RF was set to 10.

I hit start on the top of the app window and a few hours later I was left with a flawless video, no skips or funny artifacts. 

______________________


Hopefully this will help anyone else who ends up stuck in a similar nightmare after a great night out. I noticed the connection to my camera was lost while monitoring on my phone, resulting in the .MDT file.

tjj5036:
I ran into this exact same issue filming Muse in 2022 at the Wiltern at a tiny club show where they debuted a song live and played a slew of deep cuts. It killed me when I saw the SD card error flash on the screen. Used a very similar set of steps to restore the footage, or most of it anyway. Thanks for posting and sharing this!

ol' dirty taper:
I was able to get 100% of my file recovered this way with no issues at all. Other methods left the video with unaligned audio or other playback issues. Figured since I had such a hard time finding these options, I would compile them for the next unfortunate person to find themselves with a .MDT file from a Lumix and using a mac.

if_then_else:
I had a similar issue last year when the external battery of my SONY RX100 VII camera was depleted at the end of a show. The video file was still there - but couldn't be played back.
I tried several (supposed) fixes and none of them worked. Eventually, I managed to recover the video file with an Open Source tool named untrunc. There is a version ported to Windows as well.

https://github.com/anthwlock/untrunc

Navigation

[0] Message Index

Go to full version