Jump to content

Recommended Posts

Posted

I'm working with a script of a 3rd party product that has no support and have run into an issue with MySql connections...they hit the max intermittently. This is the typical error message:

 

PHP Warning: mysql_pconnect() [<a href='function.mysql-pconnect'>function.mysql-pconnect</a>]: User xxxxx has already more than 'max_user_connections' active connections in /home/xxxxx/public_html/auction/includes/config.inc.php on line 113

 

According to the online docs mysql_pconnect() "Establishes a persistent connection to a MySQL server". I've only used mysql_connect(). The docs also say "mysql_close() will not close links established by mysql_pconnect()".

 

The docs also give this warning: "Using persistent connections can require a bit of tuning of your Apache and MySQL configurations to ensure that you do not exceed the number of connections allowed by MySQL."

 

Has anyone had experience with this issue?

Posted

change the connection from mysql_pconnect to mysql_connect (without the p) and then things should be much better. It's best not to use persistent connections

Posted

Thanks for the reply. That is what I was thinking, but I was alarmed at the prospects of a lot of code changes (someone else's code to boot). Oh well...thanks for the confirming opinion.

  • 1 month later...
Posted
change the connection from mysql_pconnect to mysql_connect (without the p) and then things should be much better. It's best not to use persistent connections

 

I am having the same issue....

 

How may I accomplish your suggestion? I use phpBB

 

Don

spyderchat.com

Join the conversation

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

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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...