How to install ffmpeg mplayer and mancoder on CentOS 6

Download PDF

Installing FFmpeg, MPlayer and MEncoder on CPanel and Centos 6

First, we need to install RPMforge repository on CentOS 6.

1. Install the DAG GPG key.

rpm --import


2. Download RPMforge-release package.

cd /home
wget (if your server x86)


3. Verify the RPMforge-release package you have downloaded.

rpm -K rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm


4. Install the RPMforge-release package.

rpm -i rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm


5. Now we can install FFmpeg, MPlayer and MEncoder.

yum install ffmpeg ffmpeg-devel mplayer mencoder


6. You may get this error when you try to install components.

Requires: perl-SGMLSpm >= 1.03ii


7. Download perl-SGMLSpm package to CentOS.



8. perl-SGMLSpm may require OpenJade.


9. Let’s install openjade on CentOS.

yum install openjade


10. Try re-install perl-SGMLSpm.

rpm -ivh perl-SGMLSpm-1.03ii-14.noarch.rpm


11. After perl-SGMLSpm installation, you can continue to install FFmpeg, MPlayer and MEncoder.

yum install ffmpeg ffmpeg-devel mplayer mencoder


12. Now, you can test your ffmpeg installation.

ffmpeg -v


19 replies
  1. Asch
    Asch says:

    This is amazing, thank you! It saved my life! I spent the past hour looking for a way to install mplayer but everything ended up resulting in errors!

  2. Andrej OSmicro
    Andrej OSmicro says:

    If you need to install MP4Box (Gapac) as well, search in our forum for a tutorial.
    FFMPEG is in general very sensitive to missing dependencies and will often fail to compile if anything is missing. If you are running a server with WHM & cPanel installed and if you are a “root” you can buy a great plugin for WHM called “Cpanel Xtra Admin”, it installs FFMPEG, mp4box, mancoder, mplayer etc with one click. The plugin is subscription based $4 per month, but you only need it once and then you can cancel it.

  3. Asch
    Asch says:

    I’m actually trying to get screenshots working on a video server of mine, and I “supposedly” had to install Mplayer. It however, isn’t working, it would seem, and I’m back to where I started now.

  4. Asch
    Asch says:

    A video thumbnail that us auto generated using JW Player. I have thousands of videos, but no thumbnail appearing. I know other sites that use the same software, with the same version of JW Player, and the same JW Player skin, but for the life of me… I just can’t seem to get it to work.

  5. Asch
    Asch says:

    XFileSharing Pro. With the Video mod. I’m not using it for file sharing, but for video streaming. It works great; I just cannot seem to auto generate a thumbnail no matter what I try.

  6. Asch
    Asch says:

    Sadly, the video mod isn’t open source. I’d be more than happy to let you take a look at my server with the mod installed if you’re interested though. I’ve been searching for days. I’m currently paying $200/mo for this and can’t let it go live until I have the thumbnails working! lol

  7. Asch
    Asch says:

    Hey Andrej,

    Sorry for the late reply. I actually managed to get it sorted out! Yay for me haha. Thanks anyway!


  8. Alex
    Alex says:

    Thank you very much for these instructions. FTP download in section 7 did not work so I downloaded perl-SGMLSpm-1.03ii-21.el6.noarch.rpm from

    It worked and I just tested by converting a few files from one format to another. Except that I could not convert to mp4 format properly. To convert to mp4 I got a message “The encoder ‘aac’ is experimental but experimental codecs are not enabled, add ‘-strict -2’ if you want to use it”. I need to look in to this.

    Many thanks again for these very helpful instructions.

    • Andrej OSmicro
      Andrej OSmicro says:

      Cheers mate, glad it helped! Look, I have installed more than dozen of ffmpeg servers and every single one had a different problem lol . The problem is that repos and packages keep changing versions and that will cause problems. Google the issue, pretty sure someone found a solution for this particular prob.. Lately I have been using only cPanel based servers and there is a plugin you can purchase for $4 p/m called Xtra Ultimate and it has an inbuilt FFMPEG installer together with all other things needed to run a media server and its all done with one click, so I don’t have to waste my time anymore.

    • Andrej OSmicro
      Andrej OSmicro says:

      Since I have written this post, versions have upgraded, so the links provided may not be the latest. For cPanel, I recommend installing a tool called WHMXTRA > . It is very cheap, like $3-4 per month from . Once installed, the tool will give you an option (amongst many many other) to install FFMPEG, MP4Box, FLVtool etc. It will all install it with one click. Once installed and confirmed it works, you can easily stop monthly payments. This is the easiest way to install FFMPEG and its modules.
      Let me know if you need any help.


Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply