The same happened to me and I was able to restore the video, using a tiny and very easy tu use program: mp4fixer
Step 1: find the mux files
First (for someone else who is a step behind), you need to find the lost temp video files, with
.mux extension. In your linux terminal, go to the root folder and type:
$ find . -type f -name "*.mux"
My files were located in my Videos folder:
Step 2: record a new sample video
Now, you need to generate with Kazam a new video of at least 20 seconds long, if possible similar to the one you are trying to recover:
Be sure to record it exactly under the same conditions, including even
shaking on the screen (same bitrate), if it was - so we will find
exactly what we are looking for. The length of the video is 20
seconds, but if you feed more - it's ok.
You will get a new video file, for example:
Step 3: download mp4fixer
Go to mp4fixer Github page and download the zip file (there is a green dropdown button on the top-right section of the screen).
Save the file somewhere in your disk and unzip it.
mux files and the sample
mp4 file into the same folder.
Step 3: run the program
In the terminal, go to the folder where you unzipped the program and you copied the video files, and run:
$ perl fixer.pl goodvideo.mp4 kazam_mv84r5fr.movie.mux recovered
When the program finishes, you will see some new files in the folder:
recovered-out-audio.raw <-- AUDIO
recovered-out-video.h264 <-- VIDEO
Step 4: convert to mp4
The last step is to convert the recovered video from .h264 to .mp4, and to include the audio in it.
I did it using the ffmpeg utility (install it first):
$ ffmpeg -i "recovered-out-video.h264" -i "recovered-out-audio.raw" -c:v copy -c:a copy -f mp4 "recovered-video.mp4"
recovered-video.mp4 working video file will be created in the folder.
It worked for me, I hope it works for you as well.