Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm having problems regarding conversion of video to flv format. Below is my command for conversion, but it seems to convert the video to flv but the file size remains 0 KB, what could be the problem, please suggest. My command:

exec("/usr/bin/ffmpeg -i $inputFile -ar 22050 -b 300000 -ab 128 -f flv -r 25 -s 320x240 - | /usr/bin/flvtool2 -U stdin $outputFile", $output);

I tried to do:

exec("which ffmpeg");

And it showed me /usr/bin/ffmpeg, So what could be the problem. Is is that the flvtool2 is not working properly, or the path the flvtool2 is wrong (if yes then how can i check the path) Help needed

share|improve this question

WinFF is a GUI for the command line video converter, FFMPEG.

It will convert most any video file that FFmpeg will convert. WinFF does multiple files in multiple formats at one time. You can for example convert mpeg’s, flv’s, and mov’s, all into avi’s all at once.

WinFF is available for Debian, Ubuntu, Redhat based GNU/Linux distributions. WinFF is available in Brazilian Portuguese, Bulgarian, Chinese Traditional, Danish, English, French, German, Greek, Hebrew, Italian, Norwegian, Polish, Portuguese, Russian, Serbian, Slovenian, Spanish and Turkish.

This may provide an easier solution instead of CLI.

To install sudo apt-get install winff


enter image description here

share|improve this answer

You can run "which flvtool2" and it'll show you the path. Have you tried running the command directly on a commandline, not from within PHP, and seeing if you get errors or output?

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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