1

I am running a compression script to compress my large AVI files to small mp4 files. The script look like this:

#!/bin/bash

FILEPATH="$1"
COMPRESSIONPATH="$2"

ffmpeg -i $FILEPATH -vcodec h264 -acodec mp2 $COMPRESSIONPATH
sudo rm $FILEPATH
curl -H "Content-Type:application/json" -X GET "http://localhost:3000/clovis/api/led"

Whenever I save a compressed video with a filename of compressedVideo#0.mp4 and open it; the newly compressed mp4 file contains footage of a very old video that I recorded and deleted about a week ago. It's almost as ffmpeg is cache that delete video and compressing any filename with compressVideo#0.mp4 with the cached video. What might be the case here? How do I clear ffmpeg cache? Changing the filename fixes this issue, but I wanted to use the filename compressedVideo#0.mp4. There are a few filenames that won't work actually; compressedVideo#0-4.mp4 all won't work. Depending on the filename used it loads the corresponding video that was created and delete long ago.

1 Answer 1

3

Solved by clearing browser cache.

1
  • Sure? What's the relation between a bash script using ffmpeg with your browser? What if I have a lot of different browsers installed? Which one should its cache be cleared? Commented Aug 10, 2023 at 22:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.