Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Canon R5 DAT (copputed MP4) file recovery Error: bad track: 'free' #170

Open
aidolov23 opened this issue Jun 16, 2024 · 10 comments
Open

Canon R5 DAT (copputed MP4) file recovery Error: bad track: 'free' #170

aidolov23 opened this issue Jun 16, 2024 · 10 comments

Comments

@aidolov23
Copy link

aidolov23 commented Jun 16, 2024

I will try recovery DAT file from Canon R5 (this file recovering with problems from another software). Untruct show error "Error: bad track: 'free'"

Info: version '' using ffmpeg '3.3.9' Lavc57.89.100
Info: reading /mnt/IMG_3598.MP4
Info: parsing healthy moov atom ...
Info: special track found (tmcd, '')

Info: unknown track 'twos' found -> fallback to dynamic stats
Error: bad track: 'free'

Corrupted DAT file appears instead of MP4 if Canon R5 is turned off while shooting.
I can send corrupted DAT and Good MP4 file if it needs.

@aidolov23 aidolov23 changed the title Canon R5 Dat recovery Error: bad track: 'free' Canon R5 DAT (copputed MP4) file recovery Error: bad track: 'free' Jun 16, 2024
@anthwlock
Copy link
Owner

Hey - please send me the files (healthy+broken) and I will take a look.
You can upload them on wetransfer. If you think they are too big, you can use untrunc -sh file.mp4.
In case you want to keep the link private, you can send me an email - see my Profile page.
Thank you!

@aidolov23
Copy link
Author

I sent a link to the uploaded files by email

@anthwlock
Copy link
Owner

The healthy file has a predictable track order.
However there is some additional padding between the packets (-> 'free' track), which currently confuses untrunc.
Luckily for us, this padding also seems to follow a predictable pattern.

When I have the time, I will do some changes to better handles this.

@vitos1k
Copy link

vitos1k commented Jun 18, 2024

uh, i got exactly the same situation. Canon R5 battery died and i left with DAT file. Untrunc says
Error: bad track: 'free'
is there any chance to save video? I can provide info on the file. However the file is huge 40+Gb i wouldn't be able to send it to you

@anthwlock
Copy link
Owner

is there any chance to save video?

Yes - it looks promising

@anthwlock
Copy link
Owner

Ok, I just committed a bunch of changes.

However there is some additional padding between the packets (-> 'free' track), which currently confuses untrunc.

Handling for this got added in 9e03db0

If the recovery ends prematurely, try to use '-s'.

@vitos1k
Copy link

vitos1k commented Jun 26, 2024

it does work! Thanks! It Showed alot of warnings! And only worked with '-s' arg. But video is playing

@aidolov23
Copy link
Author

Thanks a lot. The file that I sent as an example was completely restored.

But I also checked my other older corrupted file (also canon r5 *.dat), which I fully restored through another program with audio glitches - in latest Untrunc only the very beginning of the video is restored (I tried with "-s" and without).
It looks like there is not yet a universal fix for Canon Dat files.
But in any case, this is very useful, because there is no exact solution on the Internet on how to fix these canon *.dat files, and I was able to recover only through a paid program. I also found advice to turn to paid services, where they ask for more than $60 for restoring 1 file.

I no longer need to restore files, but I can send other corrupted DAT and Good MP4 files that are not currently being restored, if necessary.

@anthwlock
Copy link
Owner

but I can send other corrupted DAT and Good MP4 files that are not currently being restored, if necessary

Sure, I might take a look at some point

@aidolov23
Copy link
Author

Sure, I might take a look at some point

Sent new link to the uploaded files by email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants