We’ve recently have been getting mysql lost connection errors while trying to save documents. The hosting platform is Mediatemple’s Grid Service. We just recently started to see this happen - never before in the last 1.5yrs of hosting with them and with about 20 modx driven sites.
Any idea what is causing this? Support seems to think that modx is opening up too many connections to mysql dbs and exceeding the limit on the Grid Service. I don’t really buy that but figured I might post here and see if anyone else is experiencing this and/or if anyone has a solution.
-
MODX Staff
- 10,725 Posts
What kind of connection limit it is applied? i.e. How many connections to the db can you have?
-
MODX Staff
- 10,725 Posts
Alright, so if you have multiple sites on the service and you have 50 users hitting a front-end page on one of those sites, and 1 or 2 users hitting a manager page at the same time, you are going to run out of simultaneous connections. Now, what kind of traffic level are you getting? Is that kind of load possible?
Latest comment back from the support folks:
"As Ian noted, the connection limit is just one variable and may not be the cause of your issue. The query using the modx_active_users table may be improperly indexed or possibly uses multiple joins to execute the statement. This could also cause the connection error. I would certainly advise posting the error to the developers of Modx to find out what your options are. You can also get some better troubleshooting tools with a MySQL container as well."
Any ideas?
This site has the latest version installed 0.9.6.2
Well here is the latest from support:
"As Ian noted, the connection limit is just one variable and may not be the cause of your issue. The query using the modx_active_users table may be improperly indexed or possibly uses multiple joins to execute the statement. This could also cause the connection error. I would certainly advise posting the error to the developers of Modx to find out what your options are. You can also get some better troubleshooting tools with a MySQL container as well."
Now this is in relation to a site that isn’t even live yet and is the only site hosted under this account. Again, this is also with the latest version of MODx 0.9.6.2. Has anything changed between 0.9.6.p2 and the latest that would’ve increased sql connections, indexing changed etc. etc.?