Too many connections error message - URGENT!
-
sioux
Too many connections error message - URGENT!
Hi,
A client has been building their website for a couple of days and it was working fine.
Today after logging into their admin panel, when trying to add a page this error message is appearing;
Warning: mysql_pconnect(): Too many connections in /home/aiaaust/public_html/lib/adodb/drivers/adodb-mysql.inc.php on line 366
and all pages on the site are 404'ing
I'm on the latest version of cmsms, apache server, mysql 4
http://www.allinfoaboutaustralia.com
I have no idea why.
Please help.
A client has been building their website for a couple of days and it was working fine.
Today after logging into their admin panel, when trying to add a page this error message is appearing;
Warning: mysql_pconnect(): Too many connections in /home/aiaaust/public_html/lib/adodb/drivers/adodb-mysql.inc.php on line 366
and all pages on the site are 404'ing
I'm on the latest version of cmsms, apache server, mysql 4
http://www.allinfoaboutaustralia.com
I have no idea why.
Please help.
Re: Too many connections error message - URGENT!
Set persistent_db_conn to false in config.php and see if that helps any.
-
sioux
Re: Too many connections error message - URGENT!
Hi Wishy,
No, no luck. I'm very concerned as I've now setup 20 sites and they're all experiencing the same problem. It's intermittent, and after either minutes or hours, the pages appear again, but in the meantime, they're losing money (and I'm losing my reputation!!)
I LOVE cmsmadesimple and hope it's something small I've overlooked, so I'm keeping my fingers crossed you have another suggestion.
Sites having this problem are:
www.allinfoaboutgolf.com
www.allinfoaboutlondon.com
www.allinfoaboutaustralia.com
and several others.
No, no luck. I'm very concerned as I've now setup 20 sites and they're all experiencing the same problem. It's intermittent, and after either minutes or hours, the pages appear again, but in the meantime, they're losing money (and I'm losing my reputation!!)
I LOVE cmsmadesimple and hope it's something small I've overlooked, so I'm keeping my fingers crossed you have another suggestion.
Sites having this problem are:
www.allinfoaboutgolf.com
www.allinfoaboutlondon.com
www.allinfoaboutaustralia.com
and several others.
Re: Too many connections error message - URGENT!
Something I've added in 0.12...
Add this to the very bottom of index.php (right above the ?>)
Also, turn persistent connections back on.
Add this to the very bottom of index.php (right above the ?>)
Code: Select all
if (isset($gCms->db))
{ $db =& $gCms->db;
if ($db->IsConnected())
$db->Close();
}
Re: Too many connections error message - URGENT!
If this doesn't work, PM any relevant information. A real IM would be best and I should be able to help you work through it this evening.
-
sioux
Re: Too many connections error message - URGENT!
Sites back up again since I asked everyone to stop adding data!
10.30pm UK time. Will check back tomorrow - thanks.
10.30pm UK time. Will check back tomorrow - thanks.
-
jelle
Re: Too many connections error message - URGENT!
hey, I think you have some other issues too:
i did a quick nmap of that server:
20/tcp closed ftp-data
21/tcp open ftp
22/tcp open ssh
25/tcp open smtp
53/tcp open domain
80/tcp open http
110/tcp open pop3
113/tcp closed auth
143/tcp open imap
443/tcp open https
465/tcp open smtps
993/tcp open imaps
995/tcp open pop3s
3306/tcp open mysql
6666/tcp open irc-serv
Why is mysql listening to the internet? How hard would a dos attack be if mysql had to churn through tousands of connections generated from a dictionary/cracklib? I am not saying this is happening (check your logfiles to find out), but it might be what you are experiencing.
i did a quick nmap of that server:
20/tcp closed ftp-data
21/tcp open ftp
22/tcp open ssh
25/tcp open smtp
53/tcp open domain
80/tcp open http
110/tcp open pop3
113/tcp closed auth
143/tcp open imap
443/tcp open https
465/tcp open smtps
993/tcp open imaps
995/tcp open pop3s
3306/tcp open mysql
6666/tcp open irc-serv
Why is mysql listening to the internet? How hard would a dos attack be if mysql had to churn through tousands of connections generated from a dictionary/cracklib? I am not saying this is happening (check your logfiles to find out), but it might be what you are experiencing.
Re: Too many connections error message - URGENT!
Yeah, that is very strange indeed. Even if it's not firewalled off, it should at least be sitting on only localhost by default.
-
sioux
Re: Too many connections error message - URGENT!
Thanks very much for your input; however as a complete dumbo on anything other than html, I have no idea what an nmap is, how you'd tell that sql is litening to the internet, or how to check and fix it!!!
However I'll do a Google search and try and find out.
Thanks again
However I'll do a Google search and try and find out.
Thanks again
-
jelle
Re: Too many connections error message - URGENT!
Well that is what nmap does: it probes a server (with some tpc magic) to see what ports on your computer are responding to requests. You could compare it to a robot that goes to your house and pressed all 1600 doorbells. Any response (a bell ringing or your father sticking out his head telling it to go away) is counted as an open port.
If you are not the admin of this box: take it up with him first before you do anything. If you are the admin for this box: please learn to drive before you take your car on a public road.
I had another look at those suspect ports: mysql allows me connect, but then trhows me out because my hostip is not allowed to connect. That seems correct to me, although I would put that in the firewall so the rest of the world would not even see the open port.
The irc server is a bit suspect: nobody except me was logged in, which leads me to think it is not used at all. Also the copyright statement (can be fake) from 1999 smells a bit fishy. Anyway, if it is not in use, don't open that door to the public or hackers.
If you are not the admin of this box: take it up with him first before you do anything. If you are the admin for this box: please learn to drive before you take your car on a public road.
I had another look at those suspect ports: mysql allows me connect, but then trhows me out because my hostip is not allowed to connect. That seems correct to me, although I would put that in the firewall so the rest of the world would not even see the open port.
The irc server is a bit suspect: nobody except me was logged in, which leads me to think it is not used at all. Also the copyright statement (can be fake) from 1999 smells a bit fishy. Anyway, if it is not in use, don't open that door to the public or hackers.
-
sioux
Re: Too many connections error message - URGENT!
Thanks Jelle,
I agrre with what you say except that if you are given the car and told you can drive - that's what you do. You don't know what you don't know - until someone tells you. That's how I learn best anyway.
I agrre with what you say except that if you are given the car and told you can drive - that's what you do. You don't know what you don't know - until someone tells you. That's how I learn best anyway.
-
jelle
Re: Too many connections error message - URGENT!
Except that in this dimenstion you wont just stall the engine or drive into a handy tree; other will take you car from you and use it to drive over pedestrians GTA style 
It is fine if you still need to learn a lot (who doesn't?) But the deep of the internet is not the best place to learn to swim.
but to get back to the learning: figure out where mysql logs it's stuff (esp authentication errors) and trawl trough those. On a linux box you might find them in /var/log/mysql*
Next figure out who will get upset if you cut ouside acces to mysql: netstat might give some of that info on linux.
It is fine if you still need to learn a lot (who doesn't?) But the deep of the internet is not the best place to learn to swim.
but to get back to the learning: figure out where mysql logs it's stuff (esp authentication errors) and trawl trough those. On a linux box you might find them in /var/log/mysql*
Next figure out who will get upset if you cut ouside acces to mysql: netstat might give some of that info on linux.

