Jump to content

Recommended Posts

I suppose this is a luxury problem, it show increasing visitors BUT!

 

My site is messed up...

 

Warning: mysql_connect() [function.mysql-connect]: Too many connections

 

MySQL Error : Connection Error

Error Number: 0

etc..

 

What can I do to stop this?

 

Use mysql_close()?

 

It doesnt seem to get better, in fact non of the site appears when I add that in the last script that is being executed...

 

Help is appreciated!

Link to comment
https://forums.phpfreaks.com/topic/410-too-many-connections/
Share on other sites

I don\'t know how to get direct access to the server. I do everything through ftp and phpmyadmin.

 

How do I access httpd.conf? Is there anything I can change in phpmyadmin?

 

I have mysql_close(); under every page now but occasionally the error still shows up.

 

When I do \"SHOW PROCESSLIST \" as a query in phpmyadmin I get a list of 16 sleeping threads. Some for as long as 23000 + seconds.

Can I kill all them without harm?

 

Now Im closing all connections none should stay sleeping should they?

Link to comment
https://forums.phpfreaks.com/topic/410-too-many-connections/#findComment-1371
Share on other sites

http://www.mysql.com/documentation/mysql/b...any_connections

 

GRANT priv_type [(column_list)] [, priv_type [(column_list)] ...]

   ON {tbl_name | * | *.* | db_name.*}

   TO user_name [iDENTIFIED BY [PASSWORD] \'password\']

       [, user_name [iDENTIFIED BY \'password\'] ...]

   [REQUIRE

       NONE |

    [{SSL| X509}]

[CIPHER cipher [AND]]

[iSSUER issuer [AND]]

[sUBJECT subject]]

   [WITH [GRANT OPTION | MAX_QUERIES_PER_HOUR # |

                         MAX_UPDATES_PER_HOUR # |

                         MAX_CONNECTIONS_PER_HOUR #]]

Link to comment
https://forums.phpfreaks.com/topic/410-too-many-connections/#findComment-1399
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.