Sites time out, "mysql server has gone away"
Permalink
I have several production web sites which show the following behaviour. When calling them a couple of days after last logging in on them, the first request to any Concrete5 URL takes several minutes. Sometimes, it will crash with the following message:
Fatal error: Uncaught exception 'ADODB_Exception' with message 'mysql error: [2006: MySQL server has gone away] in EXECUTE("SHOW TABLES") ' in ...adodb/adodb-exceptions.inc.php:78
(I didn't save the stack trace, will do so next time... although chances are this isn't really the root of the problem, but some previous action that takes ages.)
The sites are all with the same hosting company, on different servers. It's a superb company and I have had zero problems with them so far. Also, more importantly, other web applications on the same URL that also use mySQL work while Concrete5 comes crashing down.
It is possible that these problems occur only when you enter the site logged in - I haven't heard any complaints from others so far about the sites' performance. (Update: it's not just me. See the two requests made from an external service, one directly after the other.)
That, to me, is a strong suggestion that the problem is not specific to the web host, but to Concrete5. Could it be that C5 is trying to contact some sort of update server, and fails?
Is this a known behaviour? Can I do anything to help fix it? It's not reliable to reproduce, but it's frequent.
Fatal error: Uncaught exception 'ADODB_Exception' with message 'mysql error: [2006: MySQL server has gone away] in EXECUTE("SHOW TABLES") ' in ...adodb/adodb-exceptions.inc.php:78
(I didn't save the stack trace, will do so next time... although chances are this isn't really the root of the problem, but some previous action that takes ages.)
The sites are all with the same hosting company, on different servers. It's a superb company and I have had zero problems with them so far. Also, more importantly, other web applications on the same URL that also use mySQL work while Concrete5 comes crashing down.
It is possible that these problems occur only when you enter the site logged in - I haven't heard any complaints from others so far about the sites' performance. (Update: it's not just me. See the two requests made from an external service, one directly after the other.)
That, to me, is a strong suggestion that the problem is not specific to the web host, but to Concrete5. Could it be that C5 is trying to contact some sort of update server, and fails?
Is this a known behaviour? Can I do anything to help fix it? It's not reliable to reproduce, but it's frequent.
> What version of c5 are you running?
It's 5.6.0.2 - I'll check that out. Odd, I thought it was a more recent one. I'll definitely have to do that first.
> With the 'MySQL server has gone away' error, that's a common symptom when the host's mysql server is simply overloaded and is struggling to cope with demand. I've only ever seen this on older shared servers that were packed too full of sites.
I would agree, if not every other mySQL app were running fine, and I hadn't had any other problems with that host ever. But I'll update C5 first, thanks!
It's 5.6.0.2 - I'll check that out. Odd, I thought it was a more recent one. I'll definitely have to do that first.
> With the 'MySQL server has gone away' error, that's a common symptom when the host's mysql server is simply overloaded and is struggling to cope with demand. I've only ever seen this on older shared servers that were packed too full of sites.
I would agree, if not every other mySQL app were running fine, and I hadn't had any other problems with that host ever. But I'll update C5 first, thanks!
The most recent versions of concrete5 (>=5.6.1) have much better caching and therefore don't hit the database as hard. (this also might address your other question on the forums -http://www.concrete5.org/community/forums/customizing_c5/standard-c... )
With the 'MySQL server has gone away' error, that's a common symptom when the host's mysql server is simply overloaded and is struggling to cope with demand. I've only ever seen this on older shared servers that were packed too full of sites.
I'd suggest looking to upgrade concrete5 if you can, having a chat with the host and if that still doesn't fix things (and speeds), migrate the site elsewhere.