max_user_connections

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    php|uber.leet Forum Index // General
View previous topic :: View next topic  
Author Message
bolli



Joined: 29 Jan 2011
Posts: 1

PostPosted: Sat Jan 29, 2011 2:35 pm    Post subject: max_user_connections Reply with quote
When trying to login after installing the extension and modifying the localsettings.php file, i get the following error:


Quote:

PHP Error Message

Warning: mysql_connect() [function.mysql-connect]: User a2071025_admin already has more than 'max_user_connections' active connections in /home/a2071025/public_html/aeacademy/extensions/Auth_phpBB.php on line 444

Free Web Hosting
Unexpected non-MediaWiki exception encountered, of type "Exception"
exception 'Exception' with message 'There was a problem when connecting to the phpBB database.<br />Check your Host, Username, and Password settings.<br /><br />MySQL Error Number: 0<br />MySQL Error Message: <br /><br />' in /home/a2071025/public_html/aeacademy/extensions/Auth_phpBB.php:699
Stack trace:
#0 /home/a2071025/public_html/aeacademy/extensions/Auth_phpBB.php(450): Auth_phpBB->mySQLError('There was a pro...')
#1 /home/a2071025/public_html/aeacademy/extensions/Auth_phpBB.php(321): Auth_phpBB->connect()
#2 /home/a2071025/public_html/aeacademy/includes/User.php(2801): Auth_phpBB->authenticate('[REMOVED]', '[REMOVED]')
#3 /home/a2071025/public_html/aeacademy/includes/specials/SpecialUserlogin.php(508): User->checkPassword('[REMOVED]')
#4 /home/a2071025/public_html/aeacademy/includes/specials/SpecialUserlogin.php(611): LoginForm->authenticateUserData()
#5 /home/a2071025/public_html/aeacademy/includes/specials/SpecialUserlogin.php(118): LoginForm->processLogin()
#6 /home/a2071025/public_html/aeacademy/includes/specials/SpecialUserlogin.php(17): LoginForm->execute()
#7 /home/a2071025/public_html/aeacademy/includes/SpecialPage.php(791): wfSpecialUserlogin(NULL, Object(SpecialPage))
#8 /home/a2071025/public_html/aeacademy/includes/SpecialPage.php(559): SpecialPage->execute('wfSpecialUserlo...', NULL, Object(SpecialPage))
#9 /home/a2071025/public_html/aeacademy/includes/Wiki.php(254): SpecialPage::executePath(NULL)
#10 /home/a2071025/public_html/aeacademy/includes/Wiki.php(64): MediaWiki->handleSpecialCases(Object(Title))
#11 /home/a2071025/public_html/aeacademy/index.php(117): MediaWiki->performRequestForTitle(Object(Title), Object(OutputPage), Object(WebRequest))
#12 {main}


I am the admin with the same password and user for both the forums and the wiki.

However another phpbb board administrator cannot log in at all and gets told:
Quote:

Login error

There is no user by the name "[removed]". Usernames are case sensitive. Check your spelling, or create a new account.


I have spoken to somebody from the hosting company and he says that there is no problem with it their end as lots of people have implemented phpbb and mediawiki seperately... tho he hasn't heard of anybody integrating the two

Any help would be gratefully accepted Very Happy

Bolli
aeglobalskies.herobo.com
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Mon Jan 31, 2011 2:05 pm    Post subject: Reply with quote
'max_user_connections' is a mysql error thrown when "The maximum number of simultaneous connections permitted to any given MySQL user account."is exceeded. This error is due to a limitation of your environment.

I am not sure why your other admin is getting an error. Make sure you are using version of MW and phpBB that are supported. Follow the instructions for installation.
Back to top
View user's profile Send private message
merlointhesky



Joined: 27 Feb 2012
Posts: 3

PostPosted: Mon Feb 27, 2012 6:26 am    Post subject: max_user_connections how i fixed it Reply with quote
i had the same error and i believe it might come from the fact that i'm running phpbb3 and mediawiki (1.18.1) integrated with an environment i've set for my website.

After smashing my head against various attempts to make the extension think it was already connected, i found the solution in changing the line 444 from
Code:
$fresMySQLConnection = mysql_connect($GLOBALS['wgDBserver'], $GLOBALS['wgDBuser'], $GLOBALS['wgDBpassword'], true);


to

Code:
$fresMySQLConnection = mysql_pconnect($GLOBALS['wgDBserver'], $GLOBALS['wgDBuser'], $GLOBALS['wgDBpassword'], true);


which means we are not trying anymore to open a new connection if php finds an open connection with similar credentials.
I hope the author of the plugin can confirm this could help you and maybe other users.

Regards,
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Mon Feb 27, 2012 11:43 am    Post subject: Reply with quote
Thanks merlointhesky, I hope that change helps others too.

I looked into 'mysql_pconnect' and it will work if your environment supports it. It's not the best option for my environment but I am glad it is working for you.
Back to top
View user's profile Send private message
merlointhesky



Joined: 27 Feb 2012
Posts: 3

PostPosted: Wed Feb 29, 2012 2:23 am    Post subject: Reply with quote
the problem is i'm using an hosted solution which i can't control totally, for example increasing the number of connections allowed.

On the other hand, having the mysql hosted also on a 3rd server, having pconnect might increase the response.
Back to top
View user's profile Send private message
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    php|uber.leet Forum Index // General All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
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 vote in polls in this forum

alexisBlue v1.2 // Theme Created By: Andrew Charron and Web Hosting Bluebook
Powered by phpBB © 2001, 2002 phpBB Group