Linux: Extract audio and video using ffmpeg

less than 1 minute read

Today I had some mp4 video files and I wanted to extract the audio and video into separate files. So to do that you can do the following:

Extract audio from video file and convert it to mp3

To accomplish that, execute the command:

ffmpeg -i logothetis-bureaucracy.mp4  -ab 128k -ac 2 -ar 44100 -vn logothetis-bureaucracy.mp3

Extract only the video segment from a video

To accomplish that, execute the command:

ffmpeg -i video.wmv -vcodec copy -an onlyvideo.wmv 

Leave a Comment