The server loses connection to the DB constantly
Alright, I have a fairly hefty server and am running Zero and a MySQL 5.5 DB server on it. These are actually separate entities as XenServer is installed and these are guest VMs. This is so when I begin working on One and Two, I have all of my databases in one spot as would be done in the professional world. This means that the MaNGOS server process is communicating via IP address to the other VM to do SQL queries. I am seeing a TON of "ERROR:SQL ERROR: Lost connection to MySQL server during query" on the server's console output. It gets so bad at times (usually after ten or so hours) that characters no longer save and strange things happen.
What I have done thus far is verified that there is zero packet-loss between the VMs, increased the MySQL server's maximum connections from the default of 100 to 1024, tried using MySQL 5.5, MariaDB 5.5, and MariaDB 10.1, and enabled IPv4 syn cookies on both servers. The only thing which helped was increasing the max connections from 100 to 1024. This allowed the server to run for one hour and ten minutes before the errors returned. I am currently rebooting the server and waiting to see if it takes another hour to screw up again. If it does, I will double the connections to 2048. If that doubles my time, we can assume that the server is creating way too many connections over time and not closing them for some reason.
A side-effect of this troubleshooting was fixing a problem I have had since the AHBot was merged into the core. Since it was merged it would NOT sell me any items. It would buy my items, but had nothing for me to buy. As soon as I increased the connections the AHBot began working. This leads me to believe that during the merge something did not like being part of the core and may be creating connections but not closing them. After the test I am running now I will be disabling the AHBot and seeing if the SQL errors disappear. If they do, I will begin looking at the bot code.
Recommended Comments
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now