[mythtvnz] IPAddress change

Stephen Worthington stephen_agent at jsw.gen.nz
Thu Sep 21 10:39:34 BST 2017


On Thu, 21 Sep 2017 19:30:33 +1200, you wrote:

>I've had to change the IPAddress onp my mythtv box due to switching
>Internet providers and getting a new router on a different address
>range.
>
>I changed the IP Address in the front end and back end settings and general
>
>I also found the old address in /etc/mythtv/mysql.txt and changed it there.
>
>However my frontend still wont connect and my myth web displays an
>error showing it is still trying to use MySQL on the old address:
>
>Fatal Error
>!!NoTrans: Can't connect to MySQL server on '192.168.178.26' (4) [#2003]
>
>How do I convince mythtv to use the new address?

The mysql.txt file is generally no longer used unless you are running
an ancient MythTV version.  You need to change the address in the new
config.xml file (in /etc/mythtv and /home/mythtv/.mythtv and
/home/<frontend user>/.mythtv).

This SQL query will show you if you have the database settings right
(for up to 0.28, I think it changes in v29):

MariaDB [mythconverg]> select * from settings where value like
'%serverip';
+-----------------+----------+----------+
| value           | data     | hostname |
+-----------------+----------+----------+
| MasterServerIP  | 10.0.2.4 | NULL     |
| BackendServerIP | 10.0.2.4 | mypvr    |
+-----------------+----------+----------+
2 rows in set (0.00 sec)

This command will show if you have the correct MySQL settings:

  netstat -npa | grep mysql

It should show one line like this:

tcp        0      0 0.0.0.0:3306            0.0.0.0:* LISTEN
3057/mysqld

and possibly many others with more specific IP addresses.  The 0.0.0.0
address means it will automatically bind to and respond on any IP
address on any interface.

This command will show what mythbackend is binding:

  netstat -npa | grep mythbackend

There should be one or more LISTEN lines like this (only with your IP
address):

tcp        0      0 10.0.2.4:6543           0.0.0.0:* LISTEN
17014/mythbackend

and one or more of these:

tcp        0      0 127.0.0.1:6543          0.0.0.0:* LISTEN
17014/mythbackend



More information about the mythtvnz mailing list