backend service fails right away

Have a MythTV related problem? Ask for help from other MythTV users here.

Moderator: Forum Moderators

Post Reply
Jeff42
Newcomer
Posts: 9
Joined: Sun Sep 22, 2019 12:46 am
Canada

backend service fails right away

Post by Jeff42 » Tue Oct 01, 2019 5:31 pm

£Start the mythtv-backend
sudo systemctl stop mythtv-backend
mythtv-setup
sudo systemctl daemon-reload
sudo systemctl start mythtv-backend
systemctl status mythtv-backend
* mythtv-backend.service - MythTV Backend
Loaded: loaded (/lib/systemd/system/mythtv-backend.service; enabled; vendor p
Active: active (running) since Tue 2019-10-01 18:17:28 BST; 502ms ago
Docs: https://www.mythtv.org/wiki/Mythbackend
Main PID: 1671 (mythbackend)
Tasks: 1 (limit: 2200)
Memory: 3.5M
CGroup: /system.slice/mythtv-backend.service
`-1671 /usr/bin/mythbackend --quiet --syslog local7

Oct 01 18:17:28 raspberrypi systemd[1]: Started MythTV Backend.

So far so good, so I try the mythtv frontend to see if I get a channel but it cant find the backend. so I check its status and its stopped and tried to restart too quickly?

then goes
pi@raspberrypi:~ $ systemctl status mythtv-backend
* mythtv-backend.service - MythTV Backend
Loaded: loaded (/lib/systemd/system/mythtv-backend.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2019-10-01 18:23:29 BST; 1min 16s ago
Docs: https://www.mythtv.org/wiki/Mythbackend
Process: 3962 ExecStart=/usr/bin/mythbackend --quiet --syslog local7 $ADDITIONAL_ARGS (code=exited, status=138)
Main PID: 3962 (code=exited, status=138)

Oct 01 18:23:28 raspberrypi systemd[1]: mythtv-backend.service: Failed with result 'exit-code'.
Oct 01 18:23:29 raspberrypi systemd[1]: mythtv-backend.service: Service RestartSec=1s expired, scheduling restart.
Oct 01 18:23:29 raspberrypi systemd[1]: mythtv-backend.service: Scheduled restart job, restart counter is at 10.
Oct 01 18:23:29 raspberrypi systemd[1]: Stopped MythTV Backend.
Oct 01 18:23:29 raspberrypi systemd[1]: mythtv-backend.service: Start request repeated too quickly.
Oct 01 18:23:29 raspberrypi systemd[1]: mythtv-backend.service: Failed with result 'exit-code'.
Oct 01 18:23:29 raspberrypi systemd[1]: Failed to start MythTV Backend.

MikeB2013
Senior
Posts: 427
Joined: Mon Jul 25, 2016 4:16 pm
Great Britain

Re: backend service fails right away

Post by MikeB2013 » Tue Oct 01, 2019 5:56 pm

You need to check the mythbackend log (/var/log/mythtv/mythbackend.log) the last few lines may give a clue as to why it is restarting.
Restarting too many times usually means something is wrong after using mythtv-setup, although it can also be due to network problems.

Mike

blm-ubunet
Junior
Posts: 88
Joined: Sun Jun 15, 2014 1:08 am
Cambodia

Re: backend service fails right away

Post by blm-ubunet » Tue Oct 01, 2019 7:22 pm

I could be completely wrong but..
From personal experience syslog-ging is not compatible with systemd without a lot of extra plumbing..
Without that plumbing, the backend appears to run for sometime & until all server interfaces lock.

Also I believe you need mythtv compiled with systemd support for all to work nicely.

There's a systemd service file example on mythtv wiki but that was not reliable either. There was some discussion in mythtv IRC that revealed some configuration that has worked well for over 6 months. I'll post it here later.

https://irc.mythtv.org/ircLog/channel/4/2019-01-23
--systemd-journal --quiet

Jeff42
Newcomer
Posts: 9
Joined: Sun Sep 22, 2019 12:46 am
Canada

Re: backend service fails right away

Post by Jeff42 » Tue Oct 01, 2019 10:19 pm

it would appear the storage directory I specified wasnt writable. I had to chmod to do so.

it is now running thanks both for the tips. Later tonight maybe I'll try to configure it with my hd home run tuner. So far typing freqs at it doesnt seem to work for getting a channel in there. Is there a handy guide for doing the mythtv-setup program?

Post Reply