How to Install ffmpeg tool for converting Multimedia File

Posted on

Basically, it is an article providing information on how to install ffmpeg tool. This tool is available in common Linux operating system distribution. What is the usage of ffmpeg tool ?. By typing the command ‘show ffmpeg’ tool in the command line, the output will show the information of its usage. Below is the output of the command showing the usage of ffmpeg tool :

user@hostname:~$ apt show ffmpeg
Package: ffmpeg
Version: 7:3.4.4-0ubuntu0.18.04.1
Priority: optional
Section: universe/video
Origin: Ubuntu
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Original-Maintainer: Debian Multimedia Maintainers <debian-multimedia@lists.debian.org>
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Installed-Size: 2.276 kB
Depends: libavcodec57 (>= 7:3.4.4) | libavcodec-extra57 (>= 7:3.4.4), libavdevice57 (>= 7:3.4.4), libavfilter6 (>= 7:3.4.4) | libavfilter-extra6 (>= 7:3.4.4), libavformat57 (>= 7:3.4.4), libavresample3 (>= 7:3.4.4), libavutil55 (>= 7:3.4.4), libc6 (>= 2.14), libpostproc54 (>= 7:3.4.4), libsdl2-2.0-0 (>= 2.0.8), libswresample2 (>= 7:3.4.4), libswscale4 (>= 7:3.4.4)
Suggests: ffmpeg-doc
Breaks: libav-tools (<< 6:12~~), qt-faststart (<< 7:2.7.1-3~)
Replaces: libav-tools (<< 6:12~~), qt-faststart (<< 7:2.7.1-3~)
Homepage: https://ffmpeg.org/
Task: ubuntustudio-video, ubuntustudio-audio, ubuntukylin-desktop, ubuntu-budgie-desktop
Supported: 3y
Download-Size: 1.587 kB
APT-Manual-Installed: yes
APT-Sources: http://id.archive.ubuntu.com/ubuntu bionic-updates/universe amd64 Packages
Description: Tools for transcoding, streaming and playing of multimedia files
 FFmpeg is the leading multimedia framework, able to decode, encode, transcode,
 mux, demux, stream, filter and play pretty much anything that humans and
 machines have created. It supports the most obscure ancient formats up to the
 cutting edge.
 .
 This package contains:
  * ffmpeg: a command line tool to convert multimedia files between formats
  * ffserver: a multimedia streaming server for live broadcasts
  * ffplay: a simple media player based on SDL and the FFmpeg libraries
  * ffprobe: a simple multimedia stream analyzer
  * qt-faststart: a utility to rearrange Quicktime files

N: There is 1 additional record. Please use the '-a' switch to see it
user@hostname:~$ 

As shown in the above output command, one of the tool available in the package named ‘ffmpeg’ is ffmpeg itself. The tool is a command useful for converting multimedia files between formats. For an example converting from ‘mp4’ to ‘mp3’. One of the article related with this article is available in this link. So, in order to install the package containing ‘ffmpeg’ tool, below are the steps taken.  Just execute the following steps which are compatible in Ubuntu Linux 18.04. For another Linux distribution, just try to find the compatible package manager installer :

1. Make sure it is available for the installation process.

Just type ‘apt-cache search ffmpeg’ in the command line. This is a command to search if the package exist and it is available for installation on Debian or Ubuntu based system. For other linux distribution, there is also a specific command to achieve it. Just use the suitable command to do it. Below is an example on how to do it in Debian or Ubuntu based system :

root@hostname:~# apt-cache search ffmpeg
...
ffmpeg - Tools for transcoding, streaming and playing of multimedia files
...
root@hostname:~#

2. After ensuring the package is available for further installation, type the following command to start installing the package as shown below :

root@hostname:~# apt-get -y install ffmpeg
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  libavdevice57 libavfilter6 libavresample3 libdc1394-22 libflite1 libmysofa0 libnorm1 libpgm-5.2-0 librubberband2 libsdl2-2.0-0 libzmq5
Suggested packages:
  ffmpeg-doc
The following NEW packages will be installed:
  ffmpeg libavdevice57 libavfilter6 libavresample3 libdc1394-22 libflite1 libmysofa0 libnorm1 libpgm-5.2-0 librubberband2 libsdl2-2.0-0 libzmq5
0 upgraded, 12 newly installed, 0 to remove and 0 not upgraded.
Need to get 16,6 MB of archives.
After this operation, 37,2 MB of additional disk space will be used.
...
Fetched 16,6 MB in 1min 55s (145 kB/s)
Selecting previously unselected package libavresample3:amd64.
(Reading database ... 162270 files and directories currently installed.)
Preparing to unpack .../00-libavresample3_7%3a3.4.4-0ubuntu0.18.04.1_amd64.deb ...
Unpacking libavresample3:amd64 (7:3.4.4-0ubuntu0.18.04.1) ...
Selecting previously unselected package libflite1:amd64.
Preparing to unpack .../01-libflite1_2.1-release-1_amd64.deb ...
Unpacking libflite1:amd64 (2.1-release-1) ...
Selecting previously unselected package libmysofa0:amd64.
Preparing to unpack .../02-libmysofa0_0.6~dfsg0-2_amd64.deb ...
Unpacking libmysofa0:amd64 (0.6~dfsg0-2) ...
Selecting previously unselected package librubberband2:amd64.
Preparing to unpack .../03-librubberband2_1.8.1-7ubuntu2_amd64.deb ...
Unpacking librubberband2:amd64 (1.8.1-7ubuntu2) ...
Selecting previously unselected package libnorm1:amd64.
Preparing to unpack .../04-libnorm1_1.5r6+dfsg1-6_amd64.deb ...
Unpacking libnorm1:amd64 (1.5r6+dfsg1-6) ...
Selecting previously unselected package libpgm-5.2-0:amd64.
Preparing to unpack .../05-libpgm-5.2-0_5.2.122~dfsg-2_amd64.deb ...
Unpacking libpgm-5.2-0:amd64 (5.2.122~dfsg-2) ...
Selecting previously unselected package libzmq5:amd64.
Preparing to unpack .../06-libzmq5_4.2.5-1_amd64.deb ...
Unpacking libzmq5:amd64 (4.2.5-1) ...
Selecting previously unselected package libavfilter6:amd64.
Preparing to unpack .../07-libavfilter6_7%3a3.4.4-0ubuntu0.18.04.1_amd64.deb ...
Unpacking libavfilter6:amd64 (7:3.4.4-0ubuntu0.18.04.1) ...
Selecting previously unselected package libdc1394-22:amd64.
Preparing to unpack .../08-libdc1394-22_2.2.5-1_amd64.deb ...
Unpacking libdc1394-22:amd64 (2.2.5-1) ...
Selecting previously unselected package libsdl2-2.0-0:amd64.
Preparing to unpack .../09-libsdl2-2.0-0_2.0.8+dfsg1-1ubuntu1.18.04.1_amd64.deb ...
Unpacking libsdl2-2.0-0:amd64 (2.0.8+dfsg1-1ubuntu1.18.04.1) ...
Selecting previously unselected package libavdevice57:amd64.
Preparing to unpack .../10-libavdevice57_7%3a3.4.4-0ubuntu0.18.04.1_amd64.deb ...
Unpacking libavdevice57:amd64 (7:3.4.4-0ubuntu0.18.04.1) ...
Selecting previously unselected package ffmpeg.
Preparing to unpack .../11-ffmpeg_7%3a3.4.4-0ubuntu0.18.04.1_amd64.deb ...
Unpacking ffmpeg (7:3.4.4-0ubuntu0.18.04.1) ...
Setting up libpgm-5.2-0:amd64 (5.2.122~dfsg-2) ...
Setting up libavresample3:amd64 (7:3.4.4-0ubuntu0.18.04.1) ...
Setting up libflite1:amd64 (2.1-release-1) ...
Setting up libdc1394-22:amd64 (2.2.5-1) ...
Setting up libnorm1:amd64 (1.5r6+dfsg1-6) ...
Processing triggers for libc-bin (2.27-3ubuntu1) ...
Setting up librubberband2:amd64 (1.8.1-7ubuntu2) ...
Setting up libsdl2-2.0-0:amd64 (2.0.8+dfsg1-1ubuntu1.18.04.1) ...
Processing triggers for man-db (2.8.3-2) ...
Setting up libmysofa0:amd64 (0.6~dfsg0-2) ...
Setting up libzmq5:amd64 (4.2.5-1) ...
Setting up libavfilter6:amd64 (7:3.4.4-0ubuntu0.18.04.1) ...
Setting up libavdevice57:amd64 (7:3.4.4-0ubuntu0.18.04.1) ...
Setting up ffmpeg (7:3.4.4-0ubuntu0.18.04.1) ...
Processing triggers for libc-bin (2.27-3ubuntu1) ...
user@hostname:~#

There are no errors in the above installation process. It means, the installation process is success. The above command can be executed in the Linux-based operating system distribution. Try to execute the suitable command available in the current Linux-based operating system used.

Leave a Reply