Convert flv to mp3 or ogg in Ubuntu
estebandido | 3 January 2009Today we find many music videos, lectures, films through Youtube , Vimeo , etc. and is very nice to be able to hear songs from years ago that would find them anywhere, well that's my case, that many songs from the 80s not find them.
We can download the videos to play on our computers via a firefox add-on called Download Helper , but when we hear by means of an audio things get complicated.
That is why for GNU / Linux a program called FFmpeg that can be installed through the repositories, or via terminal
sudo apt-get install ffmpeg
With this program you can convert any video format to audio, and also convert any video format to another video.
In this case I will explain how to convert flv to mp3 or ogg, so we'll use the console.
Come through the console to the directory where the files and we have the following command
ffmpeg -i video.flv -vn -ar 44100 -ac 2 -ab 160k -f mp3 nombre.mp3 (in the case of mp3)
ffmpeg -i video.flv -vn -ar 44100 -ac 2 -ab 160k -f ogg nombre.ogg (in the case of ogg)
video.flv is the name of the file you downloaded from the web
-Ab: is the audio bitrate. You put the value you want as default is 64k, some videos can leave you to extract audio in 128k, 160k, 192k or 256k, and you'll see the value that lets you extract, but usually no problem with 160K, the higher bitrate quality.
-C: is the number of channels 1 if you want to be mono, and 2 if you want it to be stereo.
nombre.mp3 or ogg: it is how you want to call the audio file, then you choose the extension you want.
And that's good with everything, depending on the minutes of the video is delayed and enjoy.
Greater detail for audio processing can be found here or to convert videos in various formats in this other page .
Related Posts
- Broad Band Internet NIU Allegro in Ubuntu GNU / Linux
- Ubuntu 8.10 on HP Pavilion tx1420us
- The opportunity comes, do not stop dreaming
- There is always a chance
- Free Software in Ecuador Decree 1014
- Free software and FLISOL
- Helps migrants with the internet
- History of the meeting of Stallman and Correa (2 years)
- 25 years of GNU
- Free and The State

















[...] Atopeino http://www.estebanmendieta.com/blog/convertir-flv-a-mp3-o-ogg-en-ubuntu here [...]
xardinerama »Blog Archive» Gardar or two youtube videos | 16 January 2009[...] Here atopeino http://www.estebanmendieta.com/blog/convertir-flv-a-mp3-o-ogg-en-ubuntu [...]
Thanks, I served well, only one thing: In the case of
Jorge Daniel Sampayo Vargas | 4 April 2009Thanks, I served well, just a detail:
For Ogg, has an error, as the filter has "mp3", must be changed to "ogg" pa 'to work
ffmpeg-i video.flv-vn-ar 44100-ac 2-ab 160k-f ogg nombre.ogg
Greetings.
Jorge Daniel Sampayo Vargas @: Thanks for the detail, have all
estebandido | 4 April 2009Jorge Daniel Sampayo Vargas':
Thanks for the detail, you're right then fix it.
I really gets this error: Stream mapping: Stream # 0.1
alex_orochi | 29 April 2009I really gets this error:
Stream mapping:
Stream # 0.1 -> # 0.0
Unsupported codec for output stream # 0.0
What may be due?
I really gives the same error ... The problem always
verily | 7 May 2009I really gives the same error ...
The usual problem in all linux programs. It is because you do not see ffmpeg codec (although probably installed) configuration for some reason so, namely, you probably have ubuntu 8.10.
So, you have to search in forums for a few hours (or days) where the solutions they propose half of the time are not true and the other half have nothing to do with the initial problem, because despite the good will of people, most do not usually have no idea where the problem lies, or follow a strict procedure to find the source of the problem.
This is usually a classic problem in Linux which I'm starting to get fed, and that although there are very good programs, well programmed and operated, programmers always end up shitting in absurdities, such as configuration files, the use of libraries or the graphical interface and thus ruin todo.el give the work to be done. It's like making a successful career to stumble and fall precipitously by a stone 1 meter before the finish.
Summing up: 99% good job and a 1% "pelotazas" may end up being a resounding fudge because programmers like to program, but not "debugear". Proof?, Ffmpeg does not convert the file
Well, next time I promise to answer with a solution ...
I think I found the solution ... After the annoying critical
verily | 7 May 2009I think I found the solution ...
After the annoying criticism (but real), it seems I've found the solution is here
http://www.pyrosoft.co.uk/blog/2008/04/15/encoding-mp3-audio-with-ffmpeg-on-ubuntu-hardy/
Apparently the problem is as always, funnciones libraries that are not installed correctly because some packages from other distributions etc go. Sometimes it's for legal reasons, other times (as for example when xmms was removed in the latest distributions) are whims of those who take distributions. So then what happens happens.
Good luck
@ Verily: Well if the problem often goes by the
estebandido | 7 May 2009@ Verily:
Well if the problem often goes by the libraries as you say, and is very annoying that.
Now there is an application that allows you to do so is called WinFF easier http://winff.org/html/ works pretty well and you can use to convert both videos and audio
Hope this helps
ffmpeg-i just file.flv-acodec copy file.mp3
chivas | 11 November 2009single
ffmpeg-i-acodec copy file.flv file.mp3
try http://www.oggconvert.com nothing to download, it's all online
Chris | 23 May 2010try http://www.oggconvert.com nothing to download, it's all online
Excellent thanks for the code, the unit to another
vsanchez | 19 January 2012Excellent thanks for the code, so I found another unit by converting a lot there I leave them there:
#! / Bin / bash
for i in *. flv, do
echo "Converting: $ {i%. flv}. mp3"
ffmpeg-i "$ {i%. flv}. flv"-vn-ar 44100-ac 2-ab 128k-f mp3 "$ {i%. flv}. mp3"
done