2015-08-31, 15:24
Question/issue in short:
I am using the Kodi (v.15.1) pvr.mythtv add-on (v.2.5.0) on my Samsung S4 (KitKat 4.4.2), and I can watch Live TV from my MythTV backend when I am at home on the WiFi (address 192.168.1.??).
When I am using the Samsung S4 on an 3G/4G connection (the phone then has its own external WAN address) then I get "Channel Unavailable" when I try to play Live TV with the Kodi pvr.mythtv add-on.
Why is it "Unavailable"? What am I doing wrong? (see details of my setup below)
I am running MythTV 0.27.5 backend on my HTPC, which is connected by USB to Haupphauge HD-PVR, which is connected by component to my STB. I have only configured one channel (HDPVR), and I just watch the channel the STB is on. (Will maybe deal with xmltv and IR channel change later.)
MythFrontend and the Kodi pvr.mythtv client work great for watching Live TV on the HTPC and on another computer in the house. Both those computers are on my LAN.
I have been pulling my hair over this for a long time now. MythTV is a more ambitious hobby than I anticipated, but I have learned a lot configuring it.
All help will be greatly appreciated!
*********************************
Details:
*******
Backend:
PC with i7-3770K
PC connected by USB to Haupphauge HD-PVR which is connected by component to STB
Ubuntu 14.04.3 LTS with Window Manager (gnome-session-flashback)
Static ip on LAN: 192.168.1.XX
Install mythtv with:
sudo add-apt-repository ppa:mythbuntu/0.27
sudo apt-get update
sudo apt-get install mythtv
The install says version mythtv (2:0.27.5+fixes.20150803.e2a11c9-0ubuntu0mythbuntu3)
After install, fix /etc/mythtv/config.xml
to have
<Host>192.168.1.XX</Host>
<UserName>mythtv</UserName>
<Password>mythtv</Password>
In /etc/mysql/my.cnf I put:
bind-address = 0.0.0.0
Also I fix mysql, create users, and fix passwords and grants, the end result of that is like so:
mysql> select user,host,password from mysql.user where user = 'mythtv';
+--------+--------------+-------------------------------------------+
| user | host | password |
+--------+--------------+-------------------------------------------+
| mythtv | % | *CC8F35F587CA5A556B4132C2407E556D92172FFC |
| mythtv | localhost | *CC8F35F587CA5A556B4132C2407E556D92172FFC |
| mythtv | 192.168.1.XX | *CC8F35F587CA5A556B4132C2407E556D92172FFC |
+--------+--------------+-------------------------------------------+
mysql> select password('mythtv');
+-------------------------------------------+
| password('mythtv') |
+-------------------------------------------+
| *CC8F35F587CA5A556B4132C2407E556D92172FFC |
+-------------------------------------------+
mysql> show grants for mythtv;
+----------------------------------------------------------------------------------------------------------------------------------+
| Grants for mythtv@% |
+----------------------------------------------------------------------------------------------------------------------------------+
| GRANT ALL PRIVILEGES ON *.* TO 'mythtv'@'%' IDENTIFIED BY PASSWORD '*CC8F35F587CA5A556B4132C2407E556D92172FFC' WITH GRANT OPTION |
| GRANT ALL PRIVILEGES ON `mythconverg`.* TO 'mythtv'@'%' |
+----------------------------------------------------------------------------------------------------------------------------------+
In MythTV Backend Setup, I set the Local Backend
IPv4 address: 192.168.1.XX
IPv6 address: ::1
Listen on Link-Local laddresses: checked
Port 6543 Status port 6544 Security pin: 0000
Master Backend IP address: 192.168.1.XX Port: 6543
I configure the HDPVR with no grabber and /bin/true in the channel change script.
Also, I do
sudo apt-get install mythbuntu-control-centre
And tick "Primary Backend role" within that.
And last but not least, I have "Single Port Forwarding" configured on my router (which has WAN address of YYY.YYY.YYY.YYY), so that
External port YYY.YYY.YYY.YYY:6543 forwards to my backend at 192.168.1.XX:6543
External port YYY.YYY.YYY.YYY:6544 forwards to my backend at 192.168.1.XX:6544
******
Client (Kodi 15.1 on Samsung S4):
pvr.mythtv (2.5.0) add-on settings:
MythTV Backend Hostname or IP: YYY.YYY.YYY.YYY (external wan address of the router)
MythTV Backend Port: 6543
MythTV Backend Port for API services: 6544
MythTV Security Pin for API services: 0000 (set as the same in "MythTV Backend Setup")
MythTV Backend Ethernet address (WOL): blank (also tried setting as 192.168.1.XX)
Enable Live TV: Checked
Allow Live TV to move scheduled shows: Checked
Conflict handling: Prefer Live TV when recording has later slot
******
Some things I have tried to solve the "Channel Unavailable" issue on remote IPs:
*put "skip-name-resolve" in my.cnf
*try bind-address = 192.168.1.XX
*Took out my old MacBook Pro out with a 3G modem. It is running OS X 10.6.8, Kodi 14.1, and MythTV PVR Client v. 1.11.2.
The Mac had exactly the same problem as the S4, LiveTV worked on the WiFi LAN, but not on the remote WAN using 3G.
****************************
LOGS
On the Android Kodi 15.1, I turned on "Enable debug logging".
In MythTV PVR Client v. 2.5.0, I turned on "Include more debug information in the log file".
Here is exactly the chain of events:
1. restarted the Master Backend PC at ~12:19:00 o'clock)
2. I start Kodi on S4 at ~12:28:04
3. I start Live TV stream at ~12:28:25 (using a more tolerant 10sec tuning delay)
4. The stream fails with "Channel unavailable at ~12:28:45
Here is the Kodi log from Android Samsung S4 (replaced external WAN router IP with YYY.YYY.YYY.YYY, and my backend LAN to 192.168.1.XX)
http://pastebin.com/Je00psHK
Here is the MythTV backend /var/log/mysql/error.log
(replaced my backend LAN to 192.168.1.XX)
("elite" is the hostname of the MythTV backend PC)
http://pastebin.com/8xMBgQJ9
Here is the MythTV backend /var/log/mythtv/mythbackend.log (replaced my backend LAN to 192.168.1.XX)
http://pastebin.com/WPuwLk02
I am using the Kodi (v.15.1) pvr.mythtv add-on (v.2.5.0) on my Samsung S4 (KitKat 4.4.2), and I can watch Live TV from my MythTV backend when I am at home on the WiFi (address 192.168.1.??).
When I am using the Samsung S4 on an 3G/4G connection (the phone then has its own external WAN address) then I get "Channel Unavailable" when I try to play Live TV with the Kodi pvr.mythtv add-on.
Why is it "Unavailable"? What am I doing wrong? (see details of my setup below)
I am running MythTV 0.27.5 backend on my HTPC, which is connected by USB to Haupphauge HD-PVR, which is connected by component to my STB. I have only configured one channel (HDPVR), and I just watch the channel the STB is on. (Will maybe deal with xmltv and IR channel change later.)
MythFrontend and the Kodi pvr.mythtv client work great for watching Live TV on the HTPC and on another computer in the house. Both those computers are on my LAN.
I have been pulling my hair over this for a long time now. MythTV is a more ambitious hobby than I anticipated, but I have learned a lot configuring it.
All help will be greatly appreciated!
*********************************
Details:
*******
Backend:
PC with i7-3770K
PC connected by USB to Haupphauge HD-PVR which is connected by component to STB
Ubuntu 14.04.3 LTS with Window Manager (gnome-session-flashback)
Static ip on LAN: 192.168.1.XX
Install mythtv with:
sudo add-apt-repository ppa:mythbuntu/0.27
sudo apt-get update
sudo apt-get install mythtv
The install says version mythtv (2:0.27.5+fixes.20150803.e2a11c9-0ubuntu0mythbuntu3)
After install, fix /etc/mythtv/config.xml
to have
<Host>192.168.1.XX</Host>
<UserName>mythtv</UserName>
<Password>mythtv</Password>
In /etc/mysql/my.cnf I put:
bind-address = 0.0.0.0
Also I fix mysql, create users, and fix passwords and grants, the end result of that is like so:
mysql> select user,host,password from mysql.user where user = 'mythtv';
+--------+--------------+-------------------------------------------+
| user | host | password |
+--------+--------------+-------------------------------------------+
| mythtv | % | *CC8F35F587CA5A556B4132C2407E556D92172FFC |
| mythtv | localhost | *CC8F35F587CA5A556B4132C2407E556D92172FFC |
| mythtv | 192.168.1.XX | *CC8F35F587CA5A556B4132C2407E556D92172FFC |
+--------+--------------+-------------------------------------------+
mysql> select password('mythtv');
+-------------------------------------------+
| password('mythtv') |
+-------------------------------------------+
| *CC8F35F587CA5A556B4132C2407E556D92172FFC |
+-------------------------------------------+
mysql> show grants for mythtv;
+----------------------------------------------------------------------------------------------------------------------------------+
| Grants for mythtv@% |
+----------------------------------------------------------------------------------------------------------------------------------+
| GRANT ALL PRIVILEGES ON *.* TO 'mythtv'@'%' IDENTIFIED BY PASSWORD '*CC8F35F587CA5A556B4132C2407E556D92172FFC' WITH GRANT OPTION |
| GRANT ALL PRIVILEGES ON `mythconverg`.* TO 'mythtv'@'%' |
+----------------------------------------------------------------------------------------------------------------------------------+
In MythTV Backend Setup, I set the Local Backend
IPv4 address: 192.168.1.XX
IPv6 address: ::1
Listen on Link-Local laddresses: checked
Port 6543 Status port 6544 Security pin: 0000
Master Backend IP address: 192.168.1.XX Port: 6543
I configure the HDPVR with no grabber and /bin/true in the channel change script.
Also, I do
sudo apt-get install mythbuntu-control-centre
And tick "Primary Backend role" within that.
And last but not least, I have "Single Port Forwarding" configured on my router (which has WAN address of YYY.YYY.YYY.YYY), so that
External port YYY.YYY.YYY.YYY:6543 forwards to my backend at 192.168.1.XX:6543
External port YYY.YYY.YYY.YYY:6544 forwards to my backend at 192.168.1.XX:6544
******
Client (Kodi 15.1 on Samsung S4):
pvr.mythtv (2.5.0) add-on settings:
MythTV Backend Hostname or IP: YYY.YYY.YYY.YYY (external wan address of the router)
MythTV Backend Port: 6543
MythTV Backend Port for API services: 6544
MythTV Security Pin for API services: 0000 (set as the same in "MythTV Backend Setup")
MythTV Backend Ethernet address (WOL): blank (also tried setting as 192.168.1.XX)
Enable Live TV: Checked
Allow Live TV to move scheduled shows: Checked
Conflict handling: Prefer Live TV when recording has later slot
******
Some things I have tried to solve the "Channel Unavailable" issue on remote IPs:
*put "skip-name-resolve" in my.cnf
*try bind-address = 192.168.1.XX
*Took out my old MacBook Pro out with a 3G modem. It is running OS X 10.6.8, Kodi 14.1, and MythTV PVR Client v. 1.11.2.
The Mac had exactly the same problem as the S4, LiveTV worked on the WiFi LAN, but not on the remote WAN using 3G.
****************************
LOGS
On the Android Kodi 15.1, I turned on "Enable debug logging".
In MythTV PVR Client v. 2.5.0, I turned on "Include more debug information in the log file".
Here is exactly the chain of events:
1. restarted the Master Backend PC at ~12:19:00 o'clock)
2. I start Kodi on S4 at ~12:28:04
3. I start Live TV stream at ~12:28:25 (using a more tolerant 10sec tuning delay)
4. The stream fails with "Channel unavailable at ~12:28:45
Here is the Kodi log from Android Samsung S4 (replaced external WAN router IP with YYY.YYY.YYY.YYY, and my backend LAN to 192.168.1.XX)
http://pastebin.com/Je00psHK
Here is the MythTV backend /var/log/mysql/error.log
(replaced my backend LAN to 192.168.1.XX)
("elite" is the hostname of the MythTV backend PC)
http://pastebin.com/8xMBgQJ9
Here is the MythTV backend /var/log/mythtv/mythbackend.log (replaced my backend LAN to 192.168.1.XX)
http://pastebin.com/WPuwLk02