我剛剛在樓下的 Ubuntu 伺服器上安裝了 Gerbera 並嘗試使用gerbera
.它首先產生一個配置文件,然後給出以下錯誤:
sarah@scilab_comp_0:~$ gerbera
2019-05-19 05:42:33 INFO: Gerbera UPnP Server version 1.1.0 - http://gerbera.io/
2019-05-19 05:42:33 INFO: ===============================================================================
2019-05-19 05:42:33 INFO: Gerbera is free software, covered by the GNU General Public License version 2
2019-05-19 05:42:33 INFO: Copyright 2016-2017 Gerbera Contributors.
2019-05-19 05:42:33 INFO: Gerbera is based on MediaTomb: Copyright 2005-2010 Gena Batsyan, Sergey Bostandzhyan, Leonhard Wimmer.
2019-05-19 05:42:33 INFO: ===============================================================================
2019-05-19 05:42:33 INFO: Loading configuration from: /home/sarah/.config/gerbera/config.xml
2019-05-19 05:42:33 INFO: Checking configuration...
2019-05-19 05:42:33 INFO: Setting filesystem import charset to UTF-8
2019-05-19 05:42:33 INFO: Setting metadata import charset to UTF-8
2019-05-19 05:42:33 INFO: Setting playlist charset to UTF-8
2019-05-19 05:42:33 WARNING: You enabled the YouTube feature, which allows you
to watch YouTube videos on your UPnP device!
Please check http://www.youtube.com/t/terms
By using this feature you may be violating YouTube
service terms and conditions!
2019-05-19 05:42:33 INFO: Configuration check succeeded.
Exception raised in [src/server.cc:123] upnp_init(): upnp_init: UpnpInit failed
2019-05-19 05:42:33 ERROR: main: upnp error -203
2019-05-19 05:42:33 ERROR: Could not bind to socket.
2019-05-19 05:42:33 INFO: Please check if another instance of Gerbera or
2019-05-19 05:42:33 INFO: another application is running on port 0.
2019-05-19 05:42:33 ERROR: upnp_cleanup: UpnpUnRegisterRootDevice failed
Exception raised in [src/server.cc:248] shutdown(): upnp_cleanup: UpnpUnRegisterRootDevice failed
不知道為什麼。
奇怪的是 gerbera 服務已啟動並運行:
● gerbera.service - Gerbera Media Server
Loaded: loaded (/lib/systemd/system/gerbera.service; enabled; vendor preset: enabled)
Active: active (running) since Sun 2019-05-19 05:40:08 UTC; 6min ago
Docs: man:gerbera(1)
https://gerbera.io/
Main PID: 28343 (gerbera)
Tasks: 12 (limit: 4467)
CGroup: /system.slice/gerbera.service
└─28343 /usr/bin/gerbera -c /etc/gerbera/config.xml
May 19 05:40:08 scilab_comp_0 gerbera[28343]: 2019-05-19 05:40:08 INFO: Setting playlist charset to UTF-8
May 19 05:40:08 scilab_comp_0 gerbera[28343]: 2019-05-19 05:40:08 WARNING: You enabled the YouTube feature, which allows you
May 19 05:40:08 scilab_comp_0 gerbera[28343]: to watch YouTube videos on your UPnP device!
May 19 05:40:08 scilab_comp_0 gerbera[28343]: Please check http://www.youtube.com/t/terms
May 19 05:40:08 scilab_comp_0 gerbera[28343]: By using this feature you may be violating YouTube
May 19 05:40:08 scilab_comp_0 gerbera[28343]: service terms and conditions!
May 19 05:40:08 scilab_comp_0 gerbera[28343]: 2019-05-19 05:40:08 INFO: Configuration check succeeded.
May 19 05:40:08 scilab_comp_0 gerbera[28343]: 2019-05-19 05:40:08 INFO: Initialized port: 49152
May 19 05:40:08 scilab_comp_0 gerbera[28343]: 2019-05-19 05:40:08 INFO: Server bound to: 192.168.1.222
May 19 05:40:08 scilab_comp_0 gerbera[28343]: 2019-05-19 05:40:08 INFO: The Web UI can be reached by following this link: http://192.168.1.222:49152/
我是否錯誤地使用了非洲菊?我怎樣才能讓它工作並觀看媒體資料夾?
答案1
在 ubuntu 上安裝後,gerbera 會自動作為守護程式啟動(透過 user gerbera
)。為了手動啟動它,你必須殺死守護進程,例如
ps aux | grep gerbera
sudo kill <pid>