How to Install UPnP Gerbera Media Server on Linux

Currently, the use of multimedia elements is taking a big boom, and it is ideal to have the necessary tools to be able to share these between different devices in a safe and fully functional way.

One of the applications developed for this purpose in Linux is Gerbera which is a UPnP media server through which it will be possible to transmit our digital media through the home network and reproduce them in a wide range of devices compatible with UPnP.

Gerbera is based on MediaTomb like as a UPnP Open Source MediaServer (GPL).

Step 1: How to Install Gerbera on Linux

For Ubuntu distributions, there is a PPA created and maintained by Stephen Czetty, from which it will be possible to install Gerbera by running the following commands:

sudo add-apt-repository ppa:stephenczetty/gerbera

sudo apt update

Finally, install Gerbera using the following command:

sudo apt install gerbera

For Debian, Gerbera is available in the test repositories and are unstable, for this, enable the PPA by adding the following lines to the file /etc/apt/sources.list

sudo nano /etc/apt/sources.list

There, add the following:

# Testing repository - main, contrib and non-free branches
deb testing main non-free contrib
deb-src testing main non-free contrib
# Testing security updates repository
deb testing/updates main contrib non-free
deb-src testing/updates main contrib non-free
# Unstable repo main, contrib and non-free branches, no security updates here
deb unstable main non-free contrib
deb-src unstable main non-free contrib

Once this is done, execute the following:

apt update
apt install gerbera

Step 2: How to Manage Gerbera Services

Run the following lines to start and enable the service:

sudo systemctl start gerbera.service
sudo systemctl enable gerbera.service
sudo systemctl status gerbera.service

The next step is to define a network interface that is currently in use which will act as the environment variable MT_INTERFACE.

The default is “eth0”, but in case of wireless connection, you must configure it as “wlp1s0” In Debian/Ubuntu, these options can be set in the file /etc/default/gerbera

sudo nano /etc/default/gerbera

There, enter the interface and save the changes using the Ctrl + O keys and exit the editor using Ctrl + X.

Step 3: How to Access Gerbera

Gerbera uses port 49152, so go to a browser and execute the following syntax:


When running this, you will see the following:

In case of receiving this error, you must enable the graphical interface and to do this, execute the following:

sudo nano /etc/gerbera/config.xml

There, change the value of the line enabled=”no” to enabled=”yes.” Save the changes and exit the editor.

Now, restart the service to apply the changes:

sudo systemctl restart gerbera.service

Now, if you access again you will see the following:

Gerbera is a useful tool for multimedia transmission in a home environment.

Similar Posts

One Comment

  1. Nice tuto but got a problem from sources with sudo update :
    Reading package lists… Done
    E: The repository testing/updates Release’ does not have a Release file.
    N: Updating from such a repository can’t be done securely, and is therefore disabled by default.
    N: See apt-secure(8) manpage for repository creation and user configuration details.

    Any clue for a debian noob user ?


Leave a Reply

Your email address will not be published. Required fields are marked *