Solved No Live TV Playback, Channel Unavailable
#16
I set IP to 192.168.1.123 in mythtv.pvr settings and it displays an error: "No response from MythTV Backend" when I restart.

Kodi log is here: http://pastebin.com/A3sDe3Ch
Reply
#17
(2016-08-28, 23:12)kchmon Wrote: I set IP to 192.168.1.123 in mythtv.pvr settings and it displays an error: "No response from MythTV Backend" when I restart.

Kodi log is here: http://pastebin.com/A3sDe3Ch

OK, I think I have found part of what is causing your problem. I just setup a new install of mythtv 0.28/fixes, together with Kodi 16.1 and pvr.mythtv addon using Mythbuntu 16.04. Everything works fine when I use a static IP on the PC, this is not the same as a Router reservation. I switched to using a Router reservation to set the IP and mythbackend appears to work with mythfrontend , but mythbackend is not listening on the IP address, it only listens on local addresses. The problem is that mythtvbackend is starting before networking has been fully established, this is most common with SSD, but I have seen it with spinning drives as well.

This can easily be confirmed by running netstat in terminal, do after a reboot

Router Reservation :
Code:
sudo netstat -nlp | grep 6543
tcp        0      0 127.0.0.1:6543          0.0.0.0:*               LISTEN      1816/mythbackend
tcp6       0      0 ::1:6543                :::*                    LISTEN      1816/mythbackend

sudo netstat -nlp | grep 6544
tcp        0      0 127.0.0.1:6544          0.0.0.0:*               LISTEN      1816/mythbackend
tcp6       0      0 ::1:6544                :::*                    LISTEN      1816/mythbackend

Edit
If you get similar output to the above, you can do (this stops and starts mythtv-backend)
sudo systemctl stop mythtv-backend.service
followed by
sudo systemctl start mythtv-backend.service

and then repeat the netstat command, this time you should also see the external IP

Static IP

Code:
sudo netstat -nlp | grep 6543
tcp        0      0 192.168.0.28:6543       0.0.0.0:*               LISTEN      3386/mythbackend
tcp        0      0 127.0.0.1:6543          0.0.0.0:*               LISTEN      3386/mythbackend
tcp6       0      0 fe80::ef95:9034:d7:6543 :::*                    LISTEN      3386/mythbackend
tcp6       0      0 ::1:6543                :::*                    LISTEN      3386/mythbackend

sudo netstat -nlp | grep 6544
tcp        0      0 192.168.0.28:6544       0.0.0.0:*               LISTEN      3386/mythbackend
tcp        0      0 127.0.0.1:6544          0.0.0.0:*               LISTEN      3386/mythbackend
tcp6       0      0 fe80::ef95:9034:d7:6544 :::*                    LISTEN      3386/mythbackend
tcp6       0      0 ::1:6544                :::*                    LISTEN      3386/mythbackend

The easiest way (in my view, there are other options like modifying systemd mythtv-backend.service file, but this may get overwritten when mythtv is updated) is to use a static IP on the PC (keep the resevation on the Router) and adjust the file /etc/network/interfaces to have a Static IP

Here is an example /etc/network/interfaces file:

Code:
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
auto enp2s0
iface enp2s0  inet static
address 192.168.0.28
netmask 255.255.255.0
gateway 192.168.0.2
network 192.168.0.0
broadcast 192.168.0.255
dns-nameservers 192.168.0.2

You will need to adjust the file to suit your network, the lines needing adjustment are:

auto enp2s0
iface enp2s0 inet static
address 192.168.0.28
gateway 192.168.0.2
dns-nameservers 192.168.0.2


Mike
Reply
#18
Mike, Thank you for taking the time to replicate my problem! Output from the two (2) netstat commands look the same as you show above. Also, I tried using mythtv.pvr after restarting the mythtvbackend.service and it WORKS! So yes, this seems like the right track.

As expected, configuring a static IP has fixed the problem.

Is there a way to simply delay starting the mythtvbackend.service for 30 seconds at startup?
Reply
#19
@kchmon

I don't know of any simple method of delaying mythbackend startup without changing the systemd mythtv-backend.service file, which means any changes are lost when mythtv is updated.

Maybe someone else has some ideas?

I have always used /etc/network/interfaces when I need a static IP. I just assign static IP outside of Router DHCP range, so when I change Routers I don't have to concern myself with setting up the Reservation.

Mike
Reply
#20
Again, many thanks for your help. It wasn't even a problem with myth.pvr.
Reply
#21
Just for completeness on the mythbackend startup issue before network is fully up and therefore not allowing remote or even local connections using a real IP Address which affects both mythtv frontend and Kodi using pvr.mythtv addon where the mythtv backend is running under Mythbuntu/Ubuntu 16.04.

This has been recently discussed on a mythtv thread:
http://www.gossamer-threads.com/lists/my...ers/602276

Here is the solution I used (it is similar to that in the mythtv thread but is slightly easier to setup, no creation of directory and file, it uses systemd built-in functionality). This change should continue to work when mythtv is updated.

In a terminal on the machine running mythtv backend:

sudo systemctl enable NetworkManager-wait-online.service
sudo systemctl edit mythtv-backend.service

Then paste the following 2 lines
[Unit]
After=NetworkManager-wait-online.service

Then exit from the edit screen (it uses nano by default, so Ctrl+x, then y, then Return key)

Now reboot the system (sudo reboot)

Mike
Reply
#22
Wow, that works perfectly. I went back to DHCP lease, and everything is working great.

I was going to try a solution like this I read about on the MythTV forum this weekend. Thanks for the followup!

Now I just need to figure out how to stop the screen from going black and unresponsive when I turn on my TV in Xubuntu 16.04 and I'll be all set.
Reply
#23
For screen going black and unresponsive try solution here (it is actually graphics independent and affects 16.04)
https://bugs.launchpad.net/ubuntu/+sourc...omments/22
Reply
#24
I don't mean to hijack my own thread with extraneous info, but I spent some time looking up this issue and found lots of different "fixes". The fix in the link you gave works temporarily until the next reboot. I have "xfsettingsd" unchecked from startup applications, but it still runs after reboot.

I didn't have this issue using Lubuntu. I think I may go back to it. I'm also getting screen tearing in Kodi on Xubuntu.
Reply

Logout Mark Read Team Forum Stats Members Help
No Live TV Playback, Channel Unavailable0