Today, we will explore how to create a small «Multimedia Server» home using a simple and well-known technology called DLNA. Acronyms that correspond to "Digital Living Network Alliance", which translated into Spanish means "Alliance for the Networked Digital Lifestyle".
And for this we will use a small and very popular terminal application called MiniDLNA. Which is available in almost all the repositories of the GNU / Linux Distros best known and used. And to view the content from other network devices, desktops or mobiles, we will use a well-known and widely used multimedia application called VLC.
And as usual, before going fully into today's topic we will leave for those interested in exploring some of our latest previous related posts with the theme of Multimedia Servers y DLNA, the following links to them. So that they can click quickly if necessary, after finishing reading this publication:
"DLNA (Digital Living Network Alliance) is an association of electronics and computer manufacturers that agreed to create a kind of compatible standard for all their systems. DLNA allows the different devices that may be within the same network to interconnect with each other to share different content. The advantage it can offer is an easy configuration and its versatility. This system can work on both Wi-fi and Ethernet networks." Streaming on Linux using DLNA
Multimedia Server: MiniDLNA + VLC
What is a Media Server?
Un «Multimedia Server» it is nothing more than a network device where multimedia files are stored. This device can be from a robust Server or a simple desktop or laptop computer. It can also be a NAS (Network Storage Drives) drive or other compatible storage device.
It is important to keep in mind that for a Playback device can communicate with a «Multimedia Server», normally it must be compatible with one of two existing standards.
One is DLNA, which ensures that home network devices can communicate and share multimedia content. And the other is UPnP (Universal Plug and Play), which is a more generic sharing solution between a media server and a compatible playback device. Also, DLNA is an outgrowth of UPnP and is more versatile and easier to use.
What is MiniDLNA?
According to MiniDLNA website, said application is described as follows:
"MiniDLNA (currently known as ReadyMedia) is a simple multimedia server software, which aims to be fully compatible with existing DLNA / UPnP-AV clients. It was originally developed by a NETGEAR employee for the ReadyNAS product line.
How to install and configure MiniDLNA?
The package containing MiniDLNA called in almost all repositories "Minidlna", therefore, all you have to do is choose and use the GUI / CLI package manager preferred to install and enable it as usual. For instance:
sudo apt install minidlna
sudo service minidlna start
sudo service minidlna status
Once installed, only the following should be done command orders and small changes in your configuration file and run afterwards so that any Computer with GNU / Linux become a small and simple «Multimedia Server»:
- Run
sudo nano /etc/minidlna.conf
- Make the following changes. In my practical case I did these:
Assign media content paths / folders
media_dir=A,/home/sysadmin/fileserverdlna/music
media_dir=P,/home/sysadmin/fileserverdlna/pictures
media_dir=V,/home/sysadmin/fileserverdlna/videos
media_dir=PV,/home/sysadmin/fileserverdlna/camera
Enable DLNA Database Storage Path
db_dir=/var/cache/minidlna
Enable directory path of logs (records)
log_dir=/var/log/minidlna
Validate / Enable assigned port for DLNA protocol
port=8200
Set DLNA Media Server name
friendly_name=MediaServerMilagrOS
Enable automatic discovery of new files in media content paths / folders
inotify=yes
Configure the SSDP notification interval, in seconds
notify_interval=30
Save changes and restart MiniDLNA Media Server
sudo service minidlna restart
Locally validate the operation of the Multimedia Server with a Web browser using the URL
http://localhost:8200/
Now it only remains, copy multimedia files in the configured routes / folders. And if everything has gone well, they will be seen locally through the interface of the used Web browser.
Manage DLNA / UPnP-AV content with VLC from Android
Henceforth, for example, on a Android mobile device and running the VLC app, it will show after a few seconds in the section called "Local network" the name of our «Multimedia Server». And we can explore the configured routes / folders and play the hosted multimedia content.
Summary
In short, use the DLNA / UPnP-AV technology through the application MiniDLNA to build a simple and useful «Multimedia Server» home is an excellent alternative to easily access and enjoy as much as possible multimedia content that we own. That is, to our archives of audios / sounds, videos / movies and images / photos that we can have in a simple home or office computer to share with others freely and without major or complex measurements or configurations.
We hope that this publication will be very useful for the entire «Comunidad de Software Libre y Código Abierto»
and of great contribution to the improvement, growth and diffusion of the ecosystem of applications available for «GNU/Linux»
. And do not stop sharing it with others, on your favorite websites, channels, groups or communities of social networks or messaging systems. Finally, visit our home page at «DesdeLinux» to explore more news, and join our official channel Telegram from DesdeLinux.
Hello, I need to make an inquiry. I have started the server, but I cannot configure the routes where I have the multimedia files.
Change the paths as explained above, but it gives me an error like "directory not accessible". What could I be doing wrong? I appreciate the answer.
Below I copy what it gives me as output when I check the status of the server:
Nov 17 20:58:49 friendly_name systemd [1]: Starting LSB: minidlna server…
Nov 17 20:58:49 friendly_name systemd minidlna [6081]: [2021/11/17 20:58:49] minidlna.c: 631: error: Media directory "A, / media / **** / Music /" not accessible [Permission denied]
Nov 17 20:58:49 friendly_name systemd minidlna [6081]: [2021/11/17 20:58:49] minidlna.c: 631: error: Media directory "P, / media / **** / Images /" not accessible [Permission denied]
Nov 17 20:58:49 friendly_name systemd minidlna [6081]: [2021/11/17 20:58:49] minidlna.c: 631: error: Media directory "A, / media / **** / Videos /" not accessible [Permission denied]
Nov 17 20:58:49 herchez-Inspiron-1440 systemd [1]: Started LSB: minidlna server.
Greetings, Hernan. Assuming you've done everything exactly the same, you might want to give the command "chmod 777 -R / paths / folders" to your destination folders to see if that fixes the no-access problem.