Though fancy media server technology like Emby and Plex exist, not everyone can use it. It is because of this that many people still use DLNA servers to deliver their media libraries to DLNA-ready devices like game consoles, smart TVs and even phones and tablets.
There are a few choices for DLNA servers on Linux. Each of them have their own pros and cons, but they all have something in common: they severely lack any sort of user-friendliness – that is until MediaTomb came along.
MediaTomb is DLNA server software that does all the standard things the others do but with a friendly and easy-to-configure set of options, as well as a competent web interface to boot. But how do you set up MediaTomb on Linux?
MediaTomb is available on most modern Linux distributions in one way or another. If you’re running Ubuntu, MediaTomb can easily be installed by entering the following command:
Running Arch Linux? It’s available as a package in the AUR. Just point your favorite AUR helper to it and install it.
Distro not listed? Chances are you’ll be able to install it. Just open your package manager and search for “mediatomb”and install it. If your Linux distribution does not package it, you may need to visit the project’s website and install it from source.
For most users, the default settings in MediaTomb should be sufficient. Still, as not every DLNA enabled device is the same, it’s safe to explore all the configurations that can be used with this software.
Generating a user-level configuration file
If you have no need to run MediaTomb as a root user and instead want to run it as a regular user, enter the command below:
This will launch the server in the terminal and keep it running as long as the window is open. It’ll also generate the default configuration file for whichever user ran the command.
Generating a system-wide configuration file
Want to generate a configuration file for the entire system instead of just one user? Run MediaTomb with root permission instead.
Alternatively, if your distro has
systemd, this command can be run instead:
Generating a system-wide configuration file with MariaDB support
If you’re not happy with the default database used within MediaTomb, it’s possible to use it with MariaDB instead. Just run the following command, and MediaTomb will generate a system-wide configuration with MariaDB support added in:
Running as a Daemon
MediaTomb has the ability to be run as a daemon. When starting it in terminal, whether with a regular user or as root, either use this command:
or this one:
This will launch the server and pull the default configuration file out, then push Mediatomb into the background to run as a daemon.
Media can be added to your MediaTomb server within a web interface. If your server started with a regular user, the default port is 49152. Running as root? It may be on 50500. To get to the user interface, enter this into your web browser:
http://127.0.0.1:50500/ or http://ip.address.of.server:50500/
http://127.0.0.1:49152/ or http://ip.address.of.server:49152/
To add media in the web interface, click the Filesystem link. This will open a file-system tree.
Using this tree, navigate to folders that house your media, and then click the “+” sign on the far right side of the page.
Want the directories to automatically update? Click the plus sign with the circle around it. This will open an option window.
Inside this setting window select “Timed” for Scan Mode, and “Full” for Scan level. You should also select the Recursive box so that Mediatomb can scan any folders inside the main scanned folder.
With Mediatomb configured and media added, all there is to do is browse for it on a DLNA-supported device. No worries on changing the settings up too much. DLNA technology is rearly standard, and almost everyone that implements it does it roughly the same way.
How do you feel about DLNA? Would you use MediaTomb as your solution or stick with the DLNA server software you’re using now? Tell us below!
Image Credit: flash.pro