Home

 

Mediaserver::Serviio

Naar index

ReadyMedia Mediaserver voor Ubuntu

Introductie

ReadyMedia (voorheen MiniDLNA) is eenvoudige mediaserversoftware, waarmee mediabestanden van de computer naar andere apparaten in het lokale netwerk gestreamd kunnen worden.

De MiniDLNA daemon presenteert mediabestanden (afbeeldingen, muziek en video) naar clients in een network. Dit kunnen applicaties zijn zoals totem en Kodi, en apparaten zoals mediaplayers, smartphones, televisies en gamingconsoles.

DLNA staat voor Digital Living Network Alliance.
Dit is een van de meest gangbare manieren om bestanden te delen met je thuisnetwerk.

ReadyMedia is makkelijk te installeren en het programma installeert zichzelf als ‘service’ op je systeem, zodat het iedere keer opstart als de computer aangezet wordt.

Veel apparaten, zoals televisies, Playstation of Xbox en smartphones, beschikken tegenwoordig standaard over DNLA, waardoor ReadyMedia er makkelijk naartoe streamt vanaf een computer of thuisserver. Het koppelen van alle apparaten gebeurt via het (W)LAN thuisnetwerk.

ReadyMedia heeft de volgende kenmerken:

Naar index

ReadyMedia Mediaserver Installeren

root@testserver:~# apt update
root@testserver:~# apt upgrade
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@testserver:~# apt install minidlna
0 upgraded, 118 newly installed, 0 to remove and 0 not upgraded.
Need to get 139 MB of archives.
After this operation, 438 MB of additional disk space will be used.
root@testserver:/etc/clamav# systemctl status minidlna
     minidlna.service - MiniDLNA lightweight DLNA/UPnP-AV server
     Loaded: loaded (/usr/lib/systemd/system/minidlna.service; enabled; preset: enabled)
     Active: active (running) since Wed 2025-01-15 15:04:48 CET; 1 day 1h ago
       Docs: man:minidlnad(1)
             man:minidlna.conf(5)
   Main PID: 167502 (minidlnad)
      Tasks: 2 (limit: 9285)
     Memory: 1.4M (peak: 3.4G swap: 31.6M swap peak: 31.6M)
        CPU: 4min 4.853s
     CGroup: /system.slice/minidlna.service
             └─167502 /usr/sbin/minidlnad -f /etc/minidlna.conf -P /run/minidlna/minidlna.pid -S -r

Naar index

Configureren

# This is the configuration file for the MiniDLNA daemon, a DLNA/UPnP-AV media
# server.
#
# Unless otherwise noted, the commented out options show their default value.
#
# On Debian, you can also refer to the minidlna.conf(5) man page for
# documentation about this file.

# Specify the user name or uid to run as (root by default).
# On Debian system command line option (from /etc/default/minidlna) overrides this.
#user=minidlna


# Path to the directory you want scanned for media files.
#
# This option can be specified more than once if you want multiple directories
# scanned.
#
# If you want to restrict a media_dir to a specific content type, you can
# prepend the directory name with a letter representing the type (A, P or V),
# followed by a comma, as so:
#   * "A" for audio    (eg. media_dir=A,/var/lib/minidlna/music)
#   * "P" for pictures (eg. media_dir=P,/var/lib/minidlna/pictures)
#   * "V" for video    (eg. media_dir=V,/var/lib/minidlna/videos)
#   * "PV" for pictures and video (eg. media_dir=PV,/var/lib/minidlna/digital_camera)
media_dir=A,/home/files/muziek
media_dir=V,/home/files/video
media_dir=P,/home/files/afbeeldingen

# Set this to merge all media_dir base contents into the root container
# (The default is no.)
#merge_media_dirs=no

# Path to the directory that should hold the database and album art cache.
#db_dir=/var/cache/minidlna

# Path to the directory that should hold the log file.
# Not used when "systemd" mode is activated with -S switch.
#log_dir=/var/log/minidlna

# Type and minimum level of importance of messages to be logged.
#
# The types are "artwork", "database", "general", "http", "inotify",
# "metadata", "scanner", "ssdp" and "tivo".
#
# The levels are "off", "fatal", "error", "warn", "info" or "debug".
# "off" turns of logging entirely, "fatal" is the highest level of importance
# and "debug" the lowest.
#
# The types are comma-separated, followed by an equal sign ("="), followed by a
# level that applies to the preceding types. This can be repeated, separating
# each of these constructs with a comma.
#
# The default is to log all types of messages at the "warn" level.
#log_level=general,artwork,database,inotify,scanner,metadata,http,ssdp,tivo=warn

# Use a different container as the root of the directory tree presented to
# clients. The possible values are:
#   * "." - standard container
#   * "B" - "Browse Directory"
#   * "M" - "Music"
#   * "P" - "Pictures"
#   * "V" - "Video"
#   * Or, you can specify the ObjectID of your desired root container
#     (eg. 1$F for Music/Playlists)
# If you specify "B" and the client device is audio-only then "Music/Folders"
# will be used as root.
#root_container=.
root_container=B

# Network interface(s) to bind to (e.g. eth0), comma delimited.
# This option can be specified more than once.
#network_interface=

# Port number for HTTP traffic (descriptions, SOAP, media transfer).
# This option is mandatory (or it must be specified on the command-line using
# "-p").
port=8200

# URL presented to clients (e.g. http://example.com:80).
#presentation_url=/

# Name that the DLNA server presents to clients.
# Defaults to "hostname: username".
friendly_name=ReadyMedia (homeserver.makkink.eu)

# Serial number the server reports to clients.
# Defaults to the MAC address of nework interface.
#serial=

# Model name the server reports to clients.
#model_name=Windows Media Connect compatible (MiniDLNA)

# Model number the server reports to clients.
# Defaults to the version number of minidlna.
#model_number=

# Automatic discovery of new files in the media_dir directory.
inotify=yes

# List of file names to look for when searching for album art.
# Names should be delimited with a forward slash ("/").
# This option can be specified more than once.
album_art_names=Cover.jpg/cover.jpg/AlbumArtSmall.jpg/albumartsmall.jpg
album_art_names=AlbumArt.jpg/albumart.jpg/Album.jpg/album.jpg
album_art_names=Folder.jpg/folder.jpg/Thumb.jpg/thumb.jpg

# Strictly adhere to DLNA standards.
# This allows server-side downscaling of very large JPEG images, which may
# decrease JPEG serving performance on (at least) Sony DLNA products.
#strict_dlna=no

# Support for streaming .jpg and .mp3 files to a TiVo supporting HMO.
#enable_tivo=no

# Which method to use for registering in TiVo: 'bonjour' (default) or
# legacy 'beacon'
#tivo_discovery=bonjour

# SSDP notify interval, in seconds.
#notify_interval=895

# Path to the MiniSSDPd socket, for MiniSSDPd support.
#minissdpdsocket=/run/minissdpd.sock

# Always set SortCriteria to this value, regardless of the SortCriteria
# passed by the client
# e.g. force_sort_criteria=+upnp:class,+upnp:originalTrackNumber,+dc:title
#force_sort_criteria=

# Maximum number of simultaneous connections
# note: many clients open several simultaneous connections while streaming
#max_connections=50

# set this to yes to allow symlinks that point outside user-defined media_dirs.
#wide_links=no

# Enable subtitle support by default on unknown clients.
#enable_subtitles=yes

# Generate video's thumbnails.
# To use this option, thumbnail generation must be enable at compile time.
#enable_thumbnail=no

# The width of the thumbnail image. Large images takes more time to generate.
#thumbnail_width=160

# Thumbnail Image quality.
#thumbnail_quality=8

# Should the thumbnail have a film strip?
#enable_thumbnail_filmstrip=no

Naar index

Leestoegang Mappen met Media

root@testserver:/etc# usermod --append --groups lanshare minidlna
root@testserver:/etc# cat /etc/group| grep lanshare
lanshare:x:1001:ububen,erica,ben,benjamin,minidlna

De ReadyMedia Server App is een geregistreerde gebruiker 'minidlna' en kan als dusdanig dan ook toegevoegd worden aan de LANSHARE groep voor toegang tot de File Server 'samba' mappen.
Om te zorgen dat Serviio de mappen met media toch kan vinden moet voor de betreffende mappen leestoegang gegeven worden aan iedereen.

Vind alle mappen die nog niet mod 0755 gezet zijn:

find /home/files/ -type d ! -perm 0755 -exec chmod -v 0755 {} \;

Vindt alle bestanden die nog niet mod 644 geet zijn:

find /home/files/ -type f ! -perm 0644 -exec chmod -v 0644 {} \;

Hierna kunnen de mappen muziek, video en afbeeldingen door ReadyMedia gevonden worden in '/home/files/'

Naar index

Firewall instellingen

Zie voor Firewall instellingen ook Server::Firewall > Benodigde open inkomende verbindingen

Als de firewall ingeschakeld is moet toegestaan worden dat ReadyMedia communiceerd over het netwerk.
Gebruik het volgende commando voor streaming via poort 8200:

root@testserver:~# ufw allow from 192.168.178.0/24 to any port 8200

Het Simple Service Discovery Protocol (SSDP) is een netwerkprotocol voor het adverteren en ontdekken van netwerkservices en is de basis van het 'Broadcast' protocol van Universal Plug and Play (UPnP).

root@resrserver:~# ufw allow from 192.168.178.0/24 to any port 1900

Naar index

Webinterface

 

De ReadyMedia Mediaserver is nu beschikbaar op o.a. TV's in hetzelfde netwerk als ook bijvoorbeeld op Windows PC's met een DLNA Browser App.

Naar index