sindreruud
Dabbler
- Joined
- Sep 21, 2017
- Messages
- 24
Hi!
I have a issue with the service Bazarr that seems to be a TrueNAS/FreeBSD problem and not a bug with the service (?)
My system is TrueNAS-13.0-U4 and I have made a new iocage jail with 13.1-RELEASE-p7. Bazarr is installed and enabled with
Confirming it looks like it should
Now I should be able to do service bazarr start/stop/status. Note that I have added rc_debug and info to make it more verbose.
And now I try to start it:
And now I try to start it by giving it the path, which works, and even service status works
Now that it is running it responds to service status and stop:
But it is not able to start it again:
Here is the rc.d file
And here is sanity checking the paths:
Checking /var/log/messages for the jail I cannot see any relevant messages either. This makes me a bit lost, and I really have no idea where to go from here. Anyone see anything obvious that I might have overlooked?
Edit: Forgot to mention that restarting the iocage does not autostart the service either, and I can't find any log messages (also don't know where to look, other then /var/log/messages) to give me an idea why it doesn't start.
Edit2: Here is the /var/log/messages when restarting the iocage
I have a issue with the service Bazarr that seems to be a TrueNAS/FreeBSD problem and not a bug with the service (?)
My system is TrueNAS-13.0-U4 and I have made a new iocage jail with 13.1-RELEASE-p7. Bazarr is installed and enabled with
Code:
pkg install bazarr sysrc "bazarr_enable=YES"
Confirming it looks like it should
Code:
root@bazarr ~$ cat /etc/rc.conf cron_flags="$cron_flags -J 15" # Disable Sendmail by default sendmail_enable="NO" sendmail_submit_enable="NO" sendmail_outbound_enable="NO" sendmail_msp_queue_enable="NO" # Run secure syslog syslogd_flags="-c -ss" # Enable IPv6 ipv6_activate_all_interfaces="YES" ifconfig_epair0b="SYNCDHCP" bazarr_enable="YES" rc_debug="YES" rc_info="YES"
Now I should be able to do service bazarr start/stop/status. Note that I have added rc_debug and info to make it more verbose.
And now I try to start it:
Code:
root@bazarr ~$ service bazarr start /usr/local/etc/rc.d/bazarr: DEBUG: pid file (/usr/local/bazarr/bazarr.pid): not readable. /usr/local/etc/rc.d/bazarr: DEBUG: checkyesno: bazarr_enable is set to YES. /usr/local/etc/rc.d/bazarr: DEBUG: run_rc_command: start_precmd: bazarr_precmd Starting bazarr. /usr/local/etc/rc.d/bazarr: DEBUG: run_rc_command: doit: limits -C daemon su -m bazarr -c 'sh -c "/usr/sbin/daemon -f -p /usr/local/bazarr/bazarr.pid /usr/local/bin/python3.9 /usr/local/share/bazarr/bin/bazarr.py --no-update -c /usr/local/bazarr"' root@bazarr ~$ service bazarr status /usr/local/etc/rc.d/bazarr: DEBUG: pid file (/usr/local/bazarr/bazarr.pid): not readable. /usr/local/etc/rc.d/bazarr: DEBUG: checkyesno: bazarr_enable is set to YES. bazarr is not running.
And now I try to start it by giving it the path, which works, and even service status works
Code:
root@bazarr ~$ /usr/local/etc/rc.d/bazarr start /usr/local/etc/rc.d/bazarr: DEBUG: pid file (/usr/local/bazarr/bazarr.pid): not readable. /usr/local/etc/rc.d/bazarr: DEBUG: checkyesno: bazarr_enable is set to YES. /usr/local/etc/rc.d/bazarr: DEBUG: run_rc_command: start_precmd: bazarr_precmd Starting bazarr. /usr/local/etc/rc.d/bazarr: DEBUG: run_rc_command: doit: limits -C daemon su -m bazarr -c 'sh -c "/usr/sbin/daemon -f -p /usr/local/bazarr/bazarr.pid /usr/local/bin/python3.9 /usr/local/share/bazarr/bin/bazarr.py --no-update -c /usr/local/bazarr"' root@bazarr ~$ service bazarr status /usr/local/etc/rc.d/bazarr: DEBUG: checkyesno: bazarr_enable is set to YES. bazarr is running as pid 10012.
Now that it is running it responds to service status and stop:
Code:
root@bazarr ~$ service bazarr status /usr/local/etc/rc.d/bazarr: DEBUG: checkyesno: bazarr_enable is set to YES. bazarr is running as pid 10012. root@bazarr ~$ service bazarr stop Stopping bazarr. /usr/local/etc/rc.d/bazarr: DEBUG: run_rc_command: doit: su -m bazarr -c 'sh -c "kill -TERM 10012"' Waiting for PIDS: 10012. root@bazarr ~$ service bazarr status /usr/local/etc/rc.d/bazarr: DEBUG: pid file (/usr/local/bazarr/bazarr.pid): not readable. /usr/local/etc/rc.d/bazarr: DEBUG: checkyesno: bazarr_enable is set to YES. bazarr is not running.
But it is not able to start it again:
Code:
root@bazarr ~$ service bazarr start /usr/local/etc/rc.d/bazarr: DEBUG: pid file (/usr/local/bazarr/bazarr.pid): not readable. /usr/local/etc/rc.d/bazarr: DEBUG: checkyesno: bazarr_enable is set to YES. /usr/local/etc/rc.d/bazarr: DEBUG: run_rc_command: start_precmd: bazarr_precmd Starting bazarr. /usr/local/etc/rc.d/bazarr: DEBUG: run_rc_command: doit: limits -C daemon su -m bazarr -c 'sh -c "/usr/sbin/daemon -f -p /usr/local/bazarr/bazarr.pid /usr/local/bin/python3.9 /usr/local/share/bazarr/bin/bazarr.py --no-update -c /usr/local/bazarr"' root@bazarr ~$ service bazarr status /usr/local/etc/rc.d/bazarr: DEBUG: pid file (/usr/local/bazarr/bazarr.pid): not readable. /usr/local/etc/rc.d/bazarr: DEBUG: checkyesno: bazarr_enable is set to YES. bazarr is not running.
Here is the rc.d file
Code:
#!/bin/sh # # Author: Michiel van Baak <michiel@vanbaak.eu> # # $FreeBSD: $ # # PROVIDE: bazarr # REQUIRE: LOGIN # KEYWORD: shutdown # Add the following lines to /etc/rc.conf to enable bazarr: # bazarr_enable: Set to NO by default. Set it to YES to enable it. # bazarr_user: The user account bazarr daemon runs as what # you want it to be. # bazarr_datadir: Directory where bazarr user data lives. # Default: /usr/local/bazarr . /etc/rc.subr name=bazarr rcvar=bazarr_enable load_rc_config ${name} : ${bazarr_enable:=NO} : ${bazarr_user:=bazarr} : ${bazarr_datadir:="/usr/local/bazarr"} pidfile="${bazarr_datadir}/bazarr.pid" procname="/usr/local/bin/python3.9" command="/usr/sbin/daemon" command_args="-f -p ${pidfile} ${procname} /usr/local/share/bazarr/bin/bazarr.py --no-update -c ${bazarr_datadir}" start_precmd=bazarr_precmd bazarr_precmd() { if [ ! -d ${bazarr_datadir} ]; then install -d -o ${bazarr_user} ${bazarr_datadir} fi } run_rc_command "$1"
And here is sanity checking the paths:
Code:
root@bazarr ~$ ls -l /usr/local/bin/python3.9 -r-xr-xr-x 1 root wheel 5200 Feb 18 02:10 /usr/local/bin/python3.9 root@bazarr ~$ ls -l /usr/local/share/bazarr/bin total 24 drwxr-xr-x 2 root wheel 4 Mar 27 13:04 __pycache__ drwxr-xr-x 10 root wheel 15 Mar 27 13:04 bazarr -rw-r--r-- 1 root wheel 3661 Dec 5 03:32 bazarr.py drwxr-xr-x 3 root wheel 3 Mar 27 13:04 frontend drwxr-xr-x 99 root wheel 115 Mar 27 13:05 libs -rw-r--r-- 1 root wheel 61 Dec 5 03:32 requirements.txt -rw-r--r-- 1 root wheel 7 Dec 5 03:32 VERSION root@bazarr ~$ ls -l /usr/local/bazarr total 4 drwxr-xr-x 2 bazarr wheel 2 Mar 27 13:07 backup -rw------- 1 bazarr wheel 5 Mar 27 13:27 bazarr.pid drwxr-xr-x 2 bazarr wheel 2 Mar 27 13:07 cache drwxr-xr-x 2 bazarr wheel 4 Mar 27 13:07 config drwxr-xr-x 2 bazarr wheel 5 Mar 27 13:27 db drwxr-xr-x 2 bazarr wheel 3 Mar 27 13:07 log drwxr-xr-x 2 bazarr wheel 2 Mar 27 13:07 restore
Checking /var/log/messages for the jail I cannot see any relevant messages either. This makes me a bit lost, and I really have no idea where to go from here. Anyone see anything obvious that I might have overlooked?
Edit: Forgot to mention that restarting the iocage does not autostart the service either, and I can't find any log messages (also don't know where to look, other then /var/log/messages) to give me an idea why it doesn't start.
Edit2: Here is the /var/log/messages when restarting the iocage
Code:
Mar 27 13:56:13 bazarr syslogd: kernel boot file is /boot/kernel/kernel Mar 27 13:56:13 bazarr root[12106]: /etc/rc: DEBUG: run_rc_command: doit: pkg_start Mar 27 13:56:13 bazarr root[12113]: /etc/rc: DEBUG: checkyesno: bsnmpd_enable is set to NO. Mar 27 13:56:13 bazarr root[12118]: /etc/rc: DEBUG: run_rc_command: doit: pwcheck_start Mar 27 13:56:13 bazarr root[12124]: /etc/rc: DEBUG: checkyesno: rpcbind_enable is set to NO. Mar 27 13:56:13 bazarr root[12129]: /etc/rc: DEBUG: run_rc_command: doit: nisdomain_start Mar 27 13:56:13 bazarr root[12134]: /etc/rc: DEBUG: checkyesno: nis_server_enable is set to NO. Mar 27 13:56:13 bazarr root[12139]: /etc/rc: DEBUG: checkyesno: nis_ypldap_enable is set to NO. Mar 27 13:56:13 bazarr root[12144]: /etc/rc: DEBUG: checkyesno: nis_ypxfrd_enable is set to NO. Mar 27 13:56:13 bazarr root[12149]: /etc/rc: DEBUG: checkyesno: rpc_ypupdated_enable is set to NO. Mar 27 13:56:13 bazarr root[12154]: /etc/rc: DEBUG: checkyesno: nis_client_enable is set to NO. Mar 27 13:56:13 bazarr root[12159]: /etc/rc: DEBUG: checkyesno: nis_ypset_enable is set to NO. Mar 27 13:56:13 bazarr root[12164]: /etc/rc: DEBUG: checkyesno: keyserv_enable is set to NO. Mar 27 13:56:13 bazarr root[12169]: /etc/rc: DEBUG: checkyesno: nis_yppasswdd_enable is set to NO. Mar 27 13:56:13 bazarr root[12175]: /etc/rc: DEBUG: checkyesno: rtadvd_enable is set to NO. Mar 27 13:56:13 bazarr root[12180]: /etc/rc: DEBUG: run_rc_command: doit: local_start Mar 27 13:56:13 bazarr root[12185]: /etc/rc: DEBUG: checkyesno: lpd_enable is set to NO. Mar 27 13:56:13 bazarr root[12196]: /etc/rc: DEBUG: checkyesno: nscd_enable is set to NO. Mar 27 13:56:13 bazarr root[12201]: /etc/rc: DEBUG: checkyesno: rarpd_enable is set to NO. Mar 27 13:56:13 bazarr root[12206]: /etc/rc: DEBUG: checkyesno: rwhod_enable is set to NO. Mar 27 13:56:13 bazarr root[12211]: /etc/rc: DEBUG: run_rc_command: doit: utx boot Mar 27 13:56:13 bazarr root[12217]: /etc/rc: DEBUG: checkyesno: ftpproxy_enable is set to NO. Mar 27 13:56:13 bazarr root[12223]: /etc/rc: DEBUG: run_rc_command: doit: msgs_start Mar 27 13:56:13 bazarr root[12229]: /etc/rc: DEBUG: checkyesno: bazarr_enable is set to YES. Mar 27 13:56:13 bazarr root[12233]: /etc/rc: DEBUG: run_rc_command: start_precmd: bazarr_precmd Mar 27 13:56:13 bazarr root[12237]: /etc/rc: DEBUG: checkyesno: rc_startmsgs is set to YES. Mar 27 13:56:13 bazarr root[12241]: /etc/rc: DEBUG: run_rc_command: doit: limits -C daemon su -m bazarr -c 'sh -c "/usr/sbin/daemon -f -p /usr/local/bazarr/bazarr.pid /usr/local/bin/python3.9 /usr/local/share/bazarr/bin/bazarr.py --no-update -c /usr/local/bazarr"' Mar 27 13:56:13 bazarr root[12251]: /etc/rc: DEBUG: checkyesno: inetd_enable is set to NO. Mar 27 13:56:13 bazarr root[12256]: /etc/rc: DEBUG: checkyesno: ftpd_enable is set to NO. Mar 27 13:56:13 bazarr root[12261]: /etc/rc: DEBUG: checkyesno: cron_dst is set to YES. Mar 27 13:56:13 bazarr root[12265]: /etc/rc: DEBUG: checkyesno: cron_enable is set to YES. Mar 27 13:56:13 bazarr root[12269]: /etc/rc: DEBUG: checkyesno: rc_startmsgs is set to YES. Mar 27 13:56:13 bazarr root[12273]: /etc/rc: DEBUG: run_rc_command: doit: limits -C daemon /usr/sbin/cron -J 15 -s Mar 27 13:56:13 bazarr root[12280]: /etc/rc: DEBUG: checkyesno: sendmail_enable is set to NO. Mar 27 13:56:13 bazarr root[12284]: /etc/rc: DEBUG: checkyesno: sendmail_submit_enable is set to NO. Mar 27 13:56:13 bazarr root[12288]: /etc/rc: DEBUG: checkyesno: sendmail_enable is set to NO. Mar 27 13:56:13 bazarr root[12292]: /etc/rc: DEBUG: checkyesno: sendmail_submit_enable is set to NO. Mar 27 13:56:13 bazarr root[12296]: /etc/rc: DEBUG: checkyesno: sendmail_outbound_enable is set to NO. Mar 27 13:56:13 bazarr root[12300]: /etc/rc: DEBUG: checkyesno: sendmail_msp_queue_enable is set to NO. Mar 27 13:56:13 bazarr root[12305]: /etc/rc: DEBUG: checkyesno: sshd_enable is set to NO. Mar 27 13:56:13 bazarr root[12310]: /etc/rc: DEBUG: run_rc_command: doit: /etc/rc.d/sysctl lastload Mar 27 13:56:13 bazarr root[12319]: /etc/rc.d/sysctl: DEBUG: run_rc_command: doit: sysctl_start last Mar 27 13:56:13 bazarr root[12325]: /etc/rc: DEBUG: checkyesno: jail_enable is set to NO. Mar 27 13:56:13 bazarr root[12330]: /etc/rc: DEBUG: checkyesno: kern_securelevel_enable is set to NO. (END)
Last edited: