[mythtv-users] Unable to connect to the master backend at 192.168.1.100:6543 (16.04 & 0.28)

HP-mini blm-ubunet at slingshot.co.nz
Sat Apr 16 23:41:14 UTC 2016


On Sat, 2016-04-16 at 15:41 -0700, Fred Hamilton wrote:
> On Sat, Apr 16, 2016 at 2:35 PM, Mike Perkins
> <mikep at randomtraveller.org.uk> wrote:
>         On 16/04/16 19:10, Mike Perkins wrote:
>                 Localhost means "this computer". If you supply that
>                 address to the backend, it won't know where to
>                 send anything other than itself.
>                 
>                 For any mythtv setup that uses more than a single
>                 machine that is both back and front end, you
>                 /must/ give every device an IP address and supply that
>                 address to mythtv through setup. That is the
>                 only way that the backend knows where everything is.
>                 
>         Meh. I meant "If the frontend supplies that address to the
>         backend, the backend won't know where to send anything other
>         than itself."
> 
> 
> Thanks.  I understand localhost = this computer = 127.0.0.1 (usually).
> My frontend and backend are on the same machine.  So I believe that
> means they could use either localhost or 192.168.1.100 or some
> combination to talk to each other.  In fact, my frontend is
> using localhost and my backend (at least as far as
> mythtv-setup/General is concerned) is set to 192.168.1.100, and they
> are working perfectly well together.
> 
> 
> My problem is that mythtv-status and mythweb want to access the
> database via 192.168.1.100:6543, and the connection gets rejected.  I
> see two possible solutions:
> 
> 
> 1) Change a setting / config file somewhere so they instead ask for
> 127.0.0.1:6543, or 
> 2) Change a setting / config file somewhere so that port 6543 is happy
> communicating via 192.168.1.100 (I believe this is the preferred
> solution if I ever want to use a remote front end.)
> 
> 
> So far I haven't been able to get either 1 or 2 to work.  My latest
> discovery is this:
> 
> 
> $ sudo netstat -tnlp | grep :3306
> 
> tcp6       0      0 :::3306                 :::*
> LISTEN      2209/mysqld     
> 
> 
> $ sudo netstat -tnlp | grep :6543
> tcp        0      0 127.0.0.1:6543      0.0.0.0:*       LISTEN
>  2550/mythbackend
> tcp6      0      0 ::1:6543                 :::*
>  LISTEN      2550/mythbackend
> 
> 
> Which is a reminder that port 6543 belongs to mythbackend, not mysq.
> I'd like to change the 127.0.0.1:6543 in the second to last line
> to 192.168.1.100:6543.  But I'm not sure where I do that.  The IP
> addresses in mythtv-setup/General are already set to 192.168.1.100.
> So I think it's a field I need to change in the database (hostname?),
> but I don't know how to do that yet - looking into it now.  But that
> doesn't sound completely right either, since this database is a copy
> of the database on my old machine (with the same 192.168.1.100 IP
> address) where mythweb and mythtv-status worked fine.
> 
> 
> Am I on the right track?
> _______________________________________________
I think so..

MythWeb (hosted by apache) accesses database thru a mysql server.
Lots of the mythweb features are thru' direct API to BE.

An interconnected collection of mythtv BEs & FEs etc has only one dB &
one dB server. Doesn't have to be on the MBE but easier if it is.
The BE & FE have to bootstrap their dB connection info from config.xml.

To allow remote FEs etc you have to setup mysql server to listen on the
real IP address of the computer it's running on (& set permissions on
"users" &/or IP ranges that can access mythconverg schema).
Clearly "localhost" is not workable for this scenario.

IIUC Recent mysql installations appear to be either be behaving
different or just thrashing the existing setup file (should be putting
custom setting in /etc/mysql/conf.d/mythtv.cnf or similar).

There were some recent changes (0.27+fixes?) affecting name resolving to
IP addresses, this impacted some people's MBE address setup (settings
via mythtv-setup). I think "names" are not valid.




More information about the mythtv-users mailing list