Gebruikershulpmiddelen

Site-hulpmiddelen


installatie_handleidingen:universalmediaserver

Dit is een oude revisie van het document!


UMS Headless DLNA server on CentOS 7

Universal Media Server is oorspronkelijk een fork van PS3 Media Server. Een eenvoudige transcoding DLNA server voor Linux.

Tools

Installeer de tools die tijdens de install nodig hebt. Na de install is het zinnig om ze weer te verwijderen.

yum install wget

Pre-requisites

repositories

de nodige rpm's bevinden zich in de EPEL en de NUX repository. verbind daarmee door:

yum install epel-release
yum install http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm

software

Installeer programa's nodig voor transcoding:

yum install mplayer mencoder ffmpeg mediainfo

Installeer Java.

yum install java-1.7.0-openjdk

Installeer UMS

Download de laatste versie van de UMS website.

cd /tmp
wget http://downloads.sourceforge.net/project/unimediaserver/Official%20Releases/Linux/UMS-5.2.2-Java7.tgz

pak uit en instaleer:

tar -xvzf UMS-5.2.2-Java7.tgz
cp -r ./ums-5.2.2 /opt
ln -s /opt/ums-5.2.2 /opt/ums
mkdir /etc/ums
cp UMS.conf WEB.conf /etc/ums

maak een user ums aan om de applicatie onder te draaien:

useradd -g 100 -d /opt/ums -s /sbin/nologin ums

zet de permissies op de files goed:

chown -R ums:users/opt/ums-5.2.2
chown -R ums:users/etc/ums

Configuratie

Edit de file /etc/ums/UMS.conf en zet de instellingen zoals gewenst:

Systemd startup files

Systemd is de vervanger van het SysV init system op CentOS 7.

Maak de file /etc/systemd/system/ums.service.

[Unit]
Description=Universal Media Server

[Service]
Type=simple
Environment="UMS_PROFILE=/etc/ums/UMS.conf"
User=ums
Group=users
ExecStart=/opt/ums/UMS.sh

[Install]
 WantedBy=multi-user.target
1
2
3
4
5
6
7
8
9
10
11
12

zorg dat systemd deze nieuwe configuratiefile kent:

systemctl daemon-reload

enable en start vervolgens de service:

sudo systemctl enable ums
sudo systemctl start ums

check of alles goed is gegaanL systemctl status ums

ums.service - Universal Media Server
   Loaded: loaded (/etc/systemd/system/ums.service; enabled)
   Active: active (running) since Sun 2014-11-30 19:12:20 MST; 32min ago
   Main PID: 12912 (java)
   CGroup: /system.slice/ums.service
           └─12912 java -Xmx768M -Xss2048k -Dfile.encoding=UTF-8 -Djava.net.p...

Systemd captures all the output from UMS and stores it in its logs. You can access all that information with journalctl. This is extremely useful if there are problems. To view all messages from UMS, you could use the command: sudo journalctl _SYSTEMD_UNIT=ums.service

firewall

Zet de firewall open voor de DLNA daemon:

zet de poorten voor de tracker en het verkeer open:

firewall-cmd --permanent --add-port=9001/tcp
firewall-cmd --permanent --add-port=5001/tcp
firewall-cmd --permanent --add-port=1900/udp
firewall-cmd --reload

Let’s first look at the ports that UMS uses:

netstat -pln | grep java

tcp        0      0 0.0.0.0:9001            0.0.0.0:*               LISTEN      12912/java          
tcp        0      0 10.0.0.204:5001         0.0.0.0:*               LISTEN      12912/java          
udp        0      0 0.0.0.0:1900            0.0.0.0:*                           12912/java

Unless you’ve changed anything, by default, those are 5001/tcp, 9001/tcp and 1900/udp. Port 9001/tcp is optional. Enable it if you want to browse your media via a web browser. Let’s utilize the firewall-cmd utility to poke the holes:

Determine the active zone for your network interface. In the command below, the zone in use is internal. Yours will likely be the default, which is public. Notate it, and use it for the next commands:

firewall-cmd –get-active-zones

public
  interfaces: eth0

bron

installatie_handleidingen/universalmediaserver.1443358176.txt.gz · Laatst gewijzigd: 2015/09/27 14:49 door abel