Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: How to salvage damaged, unplayable mp4? (Read 14970 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

How to salvage damaged, unplayable mp4?

I have two mp4 files recorded with MS Lumia onto a dying microSD card, I managed to read them on the PC directly from the card - they're more or less of correct length, full of hex content, and have proper ASCII strings in the headers, but won't play at all on anything I tried (Lumia itself, Windows 10 player app, MPC, VLC).
With what tool I would have the most luck in extracting as much as possible from them?

Re: How to salvage damaged, unplayable mp4?

Reply #1
Try to remux the files into mkv using mkvtoolnix and see if swapping the container does the trick.

Re: How to salvage damaged, unplayable mp4?

Reply #2
The file was not recognized as a supported format (exit code: 2)  :(
TrID sees them as Generic MP4 container, while proper files are seen as MPEG-4 Video, so headers are probably corrupted too, even thought there are "ftypmp42 mp423gp6isomM4V mdat" strings...


Re: How to salvage damaged, unplayable mp4?

Reply #4
Looks promising, I'll give it a spin, thanks!

Re: How to salvage damaged, unplayable mp4?

Reply #5
Have you tried seeing what MP4Box says about the file?

MP4Box.exe -v -info "filename.mp4"

It is possible that the corrupt mp4 files are missing (or a misplaced) moov atom. This post might be of use.

The Untrunc prog mentioned above may also fix it.

Please report back if you fix it as it's handy for others to know :-)


Re: How to salvage damaged, unplayable mp4?

Reply #7
Untrunc salvaged 2 minutes of one file and 10 seconds of the other, which would be roughly 90% and 5% respectively. There are no jumps in the videos so it doesn't look like it brute forces through the whole stream to extract as much as possible. Was worthwhile anyway, thanks again.

MP4Box returns the following:
Code: [Select]
[iso file] Current top box start before parsing 0
[iso file] Read Box type ftyp size 32 start 0
[iso file] Current top box start before parsing 32
[iso file] Warning Read Box type mdat (0x6D646174) size 0 reading till the end o
f file
[iso file] Read Box type mdat size 271568835 start 32
[iso file] Current top box start before parsing 0
[iso file] Read Box type ftyp size 32 start 0
[iso file] Current top box start before parsing 32
[iso file] Warning Read Box type mdat (0x6D646174) size 0 reading till the end o
f file
[iso file] Read Box type mdat size 271568835 start 32
Truncated file - missing 0 bytes
Error opening file wp.mp4: IsoMedia File is truncated

Re: How to salvage damaged, unplayable mp4?

Reply #8
I used untrunc in the past, and it was the only thing that worked to restore the file at least partially for me.

I'd use ddrescue (linux, commandline) to read out the files from the sdcard if you still have it, ddrescue was created with "dying hardware" scenario in mind, so it should get the most off the sdcard it can.
Usage would be something like
Code: [Select]
ddrescue -idirect /path/to/damaged/file.mp4 /some/path/recovered.mp4 /some/path/recovered.map
-idirect accesses the storage bypassing any caches etc, the .map file stores progress so you can stop and resume the process.

After it is done (might take a long while depending on how damaged and big your sdcard is), best case is it will restore the files completely, worst it will be about the same as it is now. You could run untrunc again on the file recovered by ddrescue, maybe it will be able to restore more this time.

 

Re: How to salvage damaged, unplayable mp4?

Reply #9
There was no problem with reading the files from the card - they read at normal speed and whole - there was a problem with writing when filming, which corrupted the filesystem.