Cactiusers.org


It is currently Mon May 21, 2012 5:13 pm




Post new topic Reply to topic  [ 5 posts ] 
 Warning: mysql_pconnect(): Too many connections 
Author Message
New User

Joined: Sat Nov 25, 2006 3:49 pm
Posts: 7
Post Warning: mysql_pconnect(): Too many connections
After fixing the mysqld.log issue yesterday i left the server running and came in this morning to find the following error.

Quote:
Warning: mysql_pconnect(): Too many connections in /var/www/html/lib/adodb/drivers/adodb-mysql.inc.php on line 355


Any help would be most appreciated. Thank you.


Wed Nov 29, 2006 3:24 pm
New User

Joined: Sat Nov 25, 2006 3:49 pm
Posts: 7
Post mysqld.log issue is back.
After digging a bit further I have found additional error messages such as
Quote:
Warning: mysql_pconnect(): Lost connection to MySQL server during query in /var/www/html/lib/adodb/drivers/adodb-mysql.inc.php on line 355
Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/lib/adodb/drivers/adodb-mysql.inc.php:355) in /var/www/html/include/auth.php on line 31
Warning: Unknown(): write failed: No space left on device (28) in Unknown on line 0
Warning: Unknown(): Failed to write session data (files). Please verify that the current setting of session.save_path is correct (/var/lib/php/session) in Unknown on line 0



I ran the command
Quote:
du -a -h
on /var/log shows that the mysqld.log is again at 15GB after only a day of running.


Wed Nov 29, 2006 3:51 pm
Site Admin

Joined: Thu Nov 11, 2004 11:12 am
Posts: 2007
Post 
The best place to start would be to figure out what exactly is in mysqld.log, so that you can figure out what is filling it up. Run "tail -f /var/log/mysqld.log" to see the last bit of the file.

Maybe you have it set to log every SQL command, which would be a good way to kill any server.


Fri Dec 01, 2006 7:31 pm
New User

Joined: Sat Nov 25, 2006 3:49 pm
Posts: 7
Post 
jimmy wrote:
The best place to start would be to figure out what exactly is in mysqld.log, so that you can figure out what is filling it up. Run "tail -f /var/log/mysqld.log" to see the last bit of the file.

Maybe you have it set to log every SQL command, which would be a good way to kill any server.


Here is what I found using tail
Quote:
061203 1:28:26 [ERROR] /usr/libexec/mysqld: Can't open file: 'syslog_incoming.MYI' (errno: 145)
061203 1:28:26 [ERROR] /usr/libexec/mysqld: Can't find file: 'mac_track_temp_ports.MYI' (errno: 2)


Figuring that the files were somehow removed I searched for them and found the following
Quote:
[root@localhost log]# locate mac_track_temp_ports.MYI
/var/lib/mysql/cacti/mac_track_temp_ports.MYI
[root@localhost log]# locate syslog_incoming.MYI
/var/lib/mysql/syslog/syslog_incoming.MYI


Sun Dec 03, 2006 2:50 am
New User

Joined: Sat Nov 25, 2006 3:49 pm
Posts: 7
Post 
After some research on forums.cacti.net I came across a post that mentioned one of the errors that I was getting and it led me in the direction of checking the mysql db's for errors and then repairing them. I ran the following commands
Quote:
mysqlcheck --auto-repair --databases syslog
mysqlcheck --auto-repair --databases cacti

the mysqlcheck on the syslog db fixed the error I was getting with that and the mysqlcheck on cacti db fixed a few errors but i was still getting errors related to mactrack. I then imported mactrack.sql,stopped and started mysqld and the error messages no longer appeared in mysqld.log. Here is the command i used for importing the mactrack table:
Quote:
mysql cacti < /var/www/html/plugins/mactrack/mactrack.sql


Thank you again Jimmy for taking the time to give me some pointers it is very much appreciated.


Sun Dec 03, 2006 4:56 am
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for: