Official Mumble VoIP Forums

Issue with phpBB3 authenticator

Ice/DBus, Web-Interfaces, Management tools

Sometimes users are getting "Wrong Password for User" when trying to connect to the mumble server running with the phpBB3 authenticator despite actually having the right password. In the phpBB3 authenticator's log the following message is displayed for that time:

Code: Select all

2010-05-21 02:31:26,090 ERROR Database operational error 2006: MySQL server has gone away
2010-05-21 02:31:26,090 DEBUG Invalidate connection to database for thread 1158166848
Whats "MySQL server has gone away" suppose to mean and how can the problem be solved? This issue normally occurs for the first person to login after no-one else has logged into the mumble server for about 30mins or so.


Funnily enough I actually encounted this when I was writing a PHP script that was designed to run in the background for a long time, crunching it's way through some data from a job queue. I found that if I attempted to run a query on what PHP thought to be an active MySQL server after not doing anything with the MySQL connection for quite some time because there was nothing in the job queue I'd get the same error. Seems that, understandably, MySQL closes the connection after a timeout period (It is actually defined by wait_timeout which is set to 1000 seconds on my server) and I simply fixed this by simply using a PHP function that allowed me to ping the connection to see if it was active or not (If not, reconnect) before running any queries. However, what appears to happen in the phpBB3 authenticator is that it just encounters this same problem and decides it can't authenticate the user. Since I don't know any Python can it be fixed (Since I'd go ahead and say it is a bug like I considered the same issue I was having with my script a bug in my script) so that the script does not try a run a query on a inactive MySQL connection or at least attempt to reconnect in some way rather than just giving up on authenticating the user until next time it gets an authentication request?
Yeah. You are right. The script isn't handling the connection timeout gracefully. The script does actually reconnect but the current operation will fail anyway. I'll fix this once I find the time. Sorry for the inconvenience.
I pushed an update that should solve the issues. It is completely untested though (I don't have a test environment for the authenticator right now) so please report back whether this actually works.
Many thanks, that seems to have fixed the issue.