[mythtv-users] Cannot Connect To Backend

Jay Foster jayf0ster at roadrunner.com
Fri Nov 28 23:03:20 UTC 2014


On 11/28/2014 02:42 PM, Jay Foster wrote:
> On 11/28/2014 01:45 PM, Hika van den Hoven wrote:
>> Hoi Jay,
>>
>> Friday, November 28, 2014, 10:48:45 PM, you wrote:
>>
>>> On 11/28/2014 01:06 PM, Hika van den Hoven wrote:
>>>> Hoi Jay,
>>>>
>>>> Friday, November 28, 2014, 9:44:59 PM, you wrote:
>>>>
>>>>> On 11/28/2014 10:53 AM, Jay Foster       wrote:
>>>>
>>>>
>>>>> On       11/28/2014 10:42 AM, Bill Meek wrote:
>>>>>
>>>>> On 11/28/2014 12:25 PM, Jay Foster wrote:
>>>>>            ...
>>>>>            > On my BE system, I have a /etc/mysql/conf.d directory.
>>>>> There is a mythtv.cnf file there:
>>>>>
>>>>>
>>>>>              [mysqld]
>>>>>              #bind-address=0.0.0.0
>>>>>              max_connections=100
>>>>>
>>>>>              Should I edit this file?  Should I add a new file?  
>>>>> What should I put in there?
>>>>>
>>>>>
>>>>>            Yes, no and:
>>>>>
>>>>>            Uncomment the bind-address line. I *think* you have to
>>>>>            restart mysql, but haven't changed mine in ages.
>>>>>
>>>>>
>>>>> Do I still need to do the
>>>>>
>>>>>              $ mysql -u root mythconverg
>>>>>              mysql> grant all on mythconverg.* to
>>>>> mythtv@"192.168.200.%"           identified by "mythtv";
>>>>>              mysql> flush privileges;
>>>>>
>>>>>
>>>>>            Maybe, you can do:
>>>>>
>>>>>                SHOW GRANTS FOR mythtv;
>>>>>
>>>>>            to see what's there now. You're looking for something 
>>>>> similar to         this:
>>>>>
>>>>>                GRANT USAGE ON mythconverg.* TO 'mythtv'@'%'
>>>>> IDENTIFIED BY         PASSWORD
>>>>> '*CC8F35F587CA5A556B4132C2407E556D92172FFC'
>>>>>
>>>>>
>>>>>          Thanks.
>>>>>
>>>>>          I first changed the bind-address to 192.168.200.11, but then
>>>>> changed it back to 0.0.0.0 (INADDR_ANY).
>>>>>          I restarted mysql and the new FE  successfully connected 
>>>>> to the       BE.
>>>>>
>>>>>          NOTE: I tried the:
>>>>>          mysql -u root mythconverg
>>>>>          ERROR 1045 (28000): Access denied for user
>>>>> 'root'@'localhost'       (using password: NO)
>>>>>          jay at mythbox:/etc/mysql$ sudo mysql -u root mythconverg
>>>>>          ERROR 1045 (28000): Access denied for user
>>>>> 'root'@'localhost'       (using password: NO)
>>>>>
>>>>>          but got errors, so I'm glad that I did not need that.
>>>>>          Jay
>>>>>          _______________________________________________
>>>>>          mythtv-users mailing list
>>>>>     mythtv-users at mythtv.org
>>>>>     http://lists.mythtv.org/mailman/listinfo/mythtv-users
>>>>>     http://wiki.mythtv.org/Mailing_List_etiquette
>>>>>          MythTV Forums: https://forum.mythtv.org
>>>>>
>>>>>
>>>>>        Arrg.  I spoke too soon.  Now mythweb no longer works.  I 
>>>>> now get
>>>>>
>>>>>
>>>>> Fatal Error
>>>>>        !!NoTrans: Can't connect to MySQL server on '127.0.0.1' 
>>>>> (111)  [#2003]
>>>>>
>>>>>        when I try to use mythweb.
>>>>>
>>>>>        Jay
>>>>>
>>>>
>>>>
>>>> What does: mysql -u<your mysqluser> -hlocalhost -p<your 
>>>> mysqlpassword> mythconverg
>>>> give?
>>>> Tot mails,
>>>>     Hika                            mailto:hikavdh at gmail.com
>>>>
>>>> "Zonder hoop kun je niet leven
>>>> Zonder leven is er geen hoop
>>>> Het eeuwige dilemma
>>>> Zeker als je hoop moet vernietigen om te kunnen overleven!"
>>>>
>>>> De lerende Mens
>>>>
>>>> _______________________________________________
>>>> mythtv-users mailing list
>>>> mythtv-users at mythtv.org
>>>> http://lists.mythtv.org/mailman/listinfo/mythtv-users
>>>> http://wiki.mythtv.org/Mailing_List_etiquette
>>>> MythTV Forums: https://forum.mythtv.org
>>>>
>>> Reading table information for completion of table and column names
>>> You can turn off this feature to get a quicker startup with -A
>>
>>> Welcome to the MySQL monitor.  Commands end with ; or \g.
>>> Your MySQL connection id is 193
>>> Server version: 5.5.40-0ubuntu0.14.04.1 (Ubuntu)
>>
>>> Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights 
>>> reserved.
>>
>>> Oracle is a registered trademark of Oracle Corporation and/or its
>>> affiliates. Other names may be trademarks of their respective
>>> owners.
>>
>>> Type 'help;' or '\h' for help. Type '\c' to clear the current input
>>> statement.
>>
>> mysql>>
>>
>>> Jay
>>> _______________________________________________
>>
>> This means mysql listens to localhost (or 127.0.0.1). So the problem
>> is in mythweb or apache. You implied mythweb worked before. So the
>> only reason I can think of is that apache/mythweb hasn't incorporated
>> the changes. So I suggest restarting apache/mythweb or beter (if
>> you're not recording) the backend machine.
>>
>> Tot mails,
>>    Hika                            mailto:hikavdh at gmail.com
>>
>> "Zonder hoop kun je niet leven
>> Zonder leven is er geen hoop
>> Het eeuwige dilemma
>> Zeker als je hoop moet vernietigen om te kunnen overleven!"
>>
>> De lerende Mens
>>
>> _______________________________________________
>> mythtv-users mailing list
>> mythtv-users at mythtv.org
>> http://lists.mythtv.org/mailman/listinfo/mythtv-users
>> http://wiki.mythtv.org/Mailing_List_etiquette
>> MythTV Forums: https://forum.mythtv.org
>>
> When I try
> mysql -umythtv -h127.0.0.1 -pZUF0nOq0 mythconverg
>
> I get
>
> ERROR 2003 (HY000): Can't connect to MySQL server on '127.0.0.1' (111)
>
> When I use 'localhost', it works.  My /etc/hosts files has
> 127.0.0.1    localhost
>
> Jay
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://lists.mythtv.org/mailman/listinfo/mythtv-users
> http://wiki.mythtv.org/Mailing_List_etiquette
> MythTV Forums: https://forum.mythtv.org
>
Ahh, I think I fixed it.  When I edited the /etc/mysql/conf.d/mythtv.cnf 
file, I 'meant' to uncomment out the bind-address 0.0.0.0 entry.  I did, 
but I also added a bind-address 192.168.200.11 after it (which I meant 
to comment out).  Both were not commented, so mysql was binding to 
192.168.200.11 instead of INADDR_ANY.  This made it accessible only by 
that address.  Using 0.0.0.0 makes it work properly for any interface, 
which is what I thought I had done.  My bad.
Jay



More information about the mythtv-users mailing list