[mythtv-users] MySQL related BE deadlocks - collective wisdom needed

Michael T. Dean mtdean at thirdcontact.com
Tue Aug 30 13:59:58 UTC 2011

On 08/05/2011 09:16 AM, Jarod Wilson wrote:
> On Aug 5, 2011, at 12:15 AM, Michael T. Dean wrote:
>>> On 11-08-04 04:39 PM, Michael T. Dean wrote:
>>>> For those of you on
>>>> 0.24-fixes, I will try to create a backport patch and post it here for
>>>> testing later today.
>> I posted a lightly-tested backport on
>> http://code.mythtv.org/trac/ticket/9704 .

> I can still immediately reproduce the same deadlock I've been seeing 95% of
> the time when I start mythfrontend of late, even with the back-ported patch.
> 2011-08-05 09:13:49.857 MythCoreContext: Connecting to backend server: xxx.xxx.xxx.xxx:6543 (try 1 of 1)
> 2011-08-05 09:13:56.861 MythSocket(21f1ea0:50): readStringList: Error, timed out after 7000 ms.
> 2011-08-05 09:13:56.861 Protocol version check failure.
>                          The response to MYTH_PROTO_VERSION was empty.
>                          This happens when the backend is too busy to respond,
>                          or has deadlocked in due to bugs or hardware failure.
> 2011-08-05 09:13:56.861 Unable to determine master backend time zone settings.  If those settings differ from local settings, some functionality will fail.

Out of curiosity--especially for the 0.24-fixes users, but also for 
those using master--how do those of you who are experiencing DB issues 
have your database configured?

1) Is your mysqld server running on the same host as the master 
mythbackend server?
2) If so, what did you specify for the DBHostName on your master 
mythbackend server's config.xml/mysql.txt file(s)?

I'm starting to wonder if those of you who are seeing problems may have 
configured DBHostName to use a host name or routable IP address--which 
forces Qt-MySQL drivers to use a TCP/IP connection to the MySQL server 
using the network stack.  If, at some point, certain tools on certain 
distros detect a network issue, they will unconfigure the entire network 
(even removing the IP address from the NIC)--basically, they rip the 
entire network out from under all running applications.  For an 
application that requires a reliable connection to a database, this 
means Bad Things happen.

Because of this, I recommend a) running the mysqld server on the master 
backend host and b) using localhost for the DBHostName in the 
config.xml/mysql.txt for the master backend host, only.  Please see 
http://www.gossamer-threads.com/lists/mythtv/users/490328#490328 for 
information--and note that you can use localhost for /only/ the 
DBHostName in a multi-host setup (you cannot use localhost/ 
for the this backend/master backend "IP Address" settings).

If you've been having issues with MySQL disappearing on you, I'd 
appreciate your replying with answers to the 2 questions, above.  If you 
do have a system with mysqld running on the master mythbackend host, and 
it's not already, please try changing DBHostName to localhost to see if 
it improves stability (or fixes the issue for you).



More information about the mythtv-users mailing list