Bonjour,
mediatomb me retourne ce résultat au lancement:
root@enterprise /home/llaumgui> service mediatomb status
Redirecting to /bin/systemctl status mediatomb.service
mediatomb.service - UPnP MediaServer
Loaded: loaded (/usr/lib/systemd/system/mediatomb.service; disabled)
Active: failed (Result: exit-code) since Mon, 04 Jun 2012 08:12:41 +0200; 1h 55min ago
Process: 14092 ExecStart=/usr/bin/mediatomb -d -u mediatomb -g mediatomb -P /run/mediatomb.pid -l /var/log/mediatomb -m /etc -f mediatomb -p 50500 -e eth0 (code=exited, status=0/SUCCESS)
Process: 14085 ExecStartPre=/usr/sbin/ifconfig eth0 allmulti (code=exited, status=255)
Process: 14082 ExecStartPre=/usr/sbin/route add -net 239.0.0.0 netmask 255.0.0.0 eth0 (code=exited, status=7)
Main PID: 14093 (code=exited, status=1/FAILURE)
CGroup: name=systemd:/system/mediatomb.service
Warning: Unit file changed on disk, 'systemctl --system daemon-reload' recommended.
Ce qui est normal car le port et l'interface réseau sont faux. Avant lorsque MediaTomb passait par un script init.d, j'avais un fichier /etc/mediatomb/mediatomb.conf qui me servait a définir mon service :
root@enterprise /home/llaumgui> cat /etc/mediatomb/mediatomb.conf
## This is a sambel configuration file for the MediaTomb daemon script
## used on Fedora Core
## By default the configuration will be created in /etc/mediatomb
## Network interface on which the server will run, you need to edit this!
MT_INTERFACE="eth2"
## User defined command line options that may be passed to the server
MT_OPTIONS=""
## MediaTomb will be started on port 50500
MT_PORT="49152"
## MediaTomb will run as mediatomb
MT_USER="mediatomb"
MT_GROUP="mediatomb"
## Location of the PID file
MT_PIDFILE="/var/run/mediatomb.pid"
## Location of the log file
MT_LOGFILE="/var/log/mediatomb"
## Location of the config file/database
MT_HOME="/etc"
MT_CFGDIR="mediatomb"
Mais ça c'était avant... Maintenant je dois passer par une édition de
/usr/lib/systemd/system/mediatomb.service ? Car j'ai modifié ce fichier mais sans succès :
root@enterprise /home/llaumgui> cat /usr/lib/systemd/system/mediatomb.service
[Unit]
Description=UPnP MediaServer
After=network.target
[Service]
Type=forking
PIDFile=/run/mediatomb.pid
ExecStartPre=-/usr/sbin/route add -net 239.0.0.0 netmask 255.0.0.0 eth2
ExecStartPre=-/usr/sbin/ifconfig eth2 allmulti
ExecStart=/usr/bin/mediatomb -d -u mediatomb -g mediatomb -P /run/mediatomb.pid -l /var/log/mediatomb -m /etc -f mediatomb -p 49152 -e eth2
[Install]
WantedBy=multi-user.target