![]() |
Database error persistant since 3 years! Please help
Hi,
I have a frequent database error on my board. I changed my host about a year ago to upgrade the php version which I thought it was the reason of this error, I contacted the current host so many times for this, I'm trying myself to optimize and repair my tables, and the server goes away every time I try this, I've failed to learn how to deal with mysql and ssh tools, and failed also to get benefit of the related posts here in vBulletin.org! I'm ready to do whatever I have to for having a professional maintenance for my database, cause I'm totally desperate of doing this myself by using the available tools and references here in vBulletin :( Any kind of help? |
What is the db error?
|
If your error is a MySQL has gone away error, do you have your own server? Because if you don't have access to change server variables, then the only thing you can do is complain to the host.
|
Quote:
The error experienced on loading forum pages is: The database has encountered a problem. Please try the following: * Load the page again by clicking the Refresh button in your web browser. Etc.. While fixing the issue via phpMyAdmin, the most common error I get is (The server cannot be found), i.e the page that appears when you have no internet connection. Sometimes on optimizing or repairing (post) table in particular, an error appears (the server has gone away, no pma_comment is found on this database) and the error number is #2006. Thanks, Boofo! :) --------------- Added [DATE]1288833955[/DATE] at [TIME]1288833955[/TIME] --------------- Quote:
I have a web host. Not a server of my own. I did contact the host so many times for that, and the most recent reply I got was the following: "Dear Ehab, I am sorry to hear that you were experiencing issues with issues on your site. Although I unable to directly replicate any errors, I have scanned your site through the malware scanner and verified that the site is clean of any malware. I have also updated the custom php.ini file to your hosting package and configured your site to create its sessions on your hosting package?s my_root/tmp folder to allow it process your database queries more efficiently. " The forum was working properly for few days after I received this message, and then I started to get the same database error once again. Sorry for the long reply, and thanks in advance, Lynne :) |
When you get the database error, view the page source for that page and you will see the actual database error near the bottom of that page. It will have some information like this:
Code:
The actual mysql query/code/problem.... |
Quote:
Hi, This is not the type of errors I meant. The error page you describe, with an internal window in it, was happening a long time ago on my board, and disappeared right after transfering host, and upgrading the php version from 4 to 5. The error I'm currently experiencing reads as I described: "The database has encountered a problem. Please try the following: * Load the page again by clicking the Refresh button in your web browser. * contact the administrator of www.mysite.com * Try to refresh the page.......etc." without any additional infromation near the bottom of the error page, such as the table name, the I.P, etc. I hope I made myself more clear. Thanks Lynne! |
You will have to view the source of the page to see the error then.
|
The error appears when I try to load the forum home page, and in other instances the homepage loads correctly, but the threads and subforums is showing the same error.
The text of the only error I get is exactly as follows: "Database error The database has encountered a problem. -------------------------------------------------------------------------------- Please try the following: Load the page again by clicking the Refresh button in your web browser. Open the www.mysite.org home page, then try to open another page. Click the Back button to try another link. The www.mysite.org forum technical staff have been notified of the error, though you may contact them if the problem persists. We apologise for any inconvenience." And I apologize also for any inconvenience :) But I'm really fed up with that frequent error that may last for hours. Thanks for your time, guys, and as I said I hope I can find an actual professional reliable solution to make my database tables work more effeciently. |
When you get the page that says:
"Database error The database has encountered a problem. etc..." Then view the page source and you will see what the actual error is. Follow my instructions in post 5. |
Quote:
I apologise for not understanding. Here's the code I got: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <title> Database Error</title> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> <meta name="ROBOTS" content="NOINDEX,NOFOLLOW,NOARCHIVE" /> <style type="text/css"> <!-- body { background-color: white; color: black; } #container { width: 400px; } #message { width: 400px; color: black; background-color: #FFFFCC; } #bodytitle { font: 13pt/15pt verdana, arial, sans-serif; height: 35px; vertical-align: top; } .bodytext { font: 8pt/11pt verdana, arial, sans-serif; } a:link { font: 8pt/11pt verdana, arial, sans-serif; color: red; } a:visited { font: 8pt/11pt verdana, arial, sans-serif; color: #4e4e4e; } --> </style> </head> <body> <table cellpadding="3" cellspacing="5" id="container"> <tr> <td><img src="./image.php?type=dberror" alt="Database Error" width="48" height="48" /></td> <td id="bodytitle" width="100%">Database error</td> </tr> <tr> <td class="bodytext" colspan="2">The database has encountered a problem.</td> </tr> <tr> <td colspan="2"><hr /></td> </tr> <tr> <td class="bodytext" colspan="2"> Please try the following: <ul> <li>Load the page again by clicking the <a href="#" onclick="window.location = window.location;">Refresh</a> button in your web browser.</li> <li>Open the <a href="/">mysite.org</a> home page, then try to open another page.</li> <li>Click the <a href="javascript:history.back(1)">Back</a> button to try another link.</li> </ul> </td> </tr> <tr> <td class="bodytext" colspan="2">The mysite.org forum technical staff have been notified of the error, though you may <a href="mailto:webmaster@mysite.org">contact them</a> if the problem persists.</td> </tr> <tr> <td class="bodytext" colspan="2"> <br />We apologise for any inconvenience.</td> </tr> <!-- Database error in vBulletin : mysql_connect() [<a href='function.mysql-connect'>function.mysql-connect</a>]: User [my_database_name] already has more than 'max_user_connections' active connections /data/22/2/48/150/2048476/user/2244090/htdocs/vb/includes/class_core.php on line 311 MySQL Error : Error Number : Request Date : Thursday, November 4th 2010 @ 07:01:24 PM Error Date : Thursday, November 4th 2010 @ 07:01:24 PM Script : http://mysite.org/vb/ Referrer : IP Address : my_IP***.138 Username : Classname : vB_Database MySQL Version : --> Thanks for your time, Lynne! Regards |
This error:
Code:
User [my_database_name] already has more than 'max_user_connections' active connections The server has maxed out the number of MySQL connections it allows. You can try turning persistent connections off by adding this to your config.php: PHP Code:
|
Quote:
The code you provided ($config['MasterServer']['usepconnect'] = 0 ) is already there in my config.php Can I raise the limit myself? or should I contact the host for raising it. Is there any recommended value of that limit? Many thanks, guys! That was really helpful :) |
No, you cannot raise it yourself. Contact your host.
|
Quote:
I got this reply from my host: "Dear Ehab, I am sorry you are having issues with your website. The reason you are experiencing this error is because the limit of mysql connections is 10. There is no way to increase this limit, but the error is most likely caused by your connections not being closed. Ensure that your websites code is closing the database connections immediately after use. This will decrease the chance of this error occurring" Now do you see that the value (10) is so low that it may cause this frequent error? If so, I would change my host to another one which provides a higher limit. If you see that the value is sufficient, I would be grateful if you give me information on how to make sure that the forum codes is closing the database connections immediately after use. Thanks in advance! :) Ehab |
10?!?! Wow. I have heard of some hosts keeping it as low as 25, but never 10. Yes, that is low.
Try disabling your mods for a few days and see if you still have the same problem. |
Quote:
I've disabled the Chatbox mod for now, and I'm upgrading to a VPS hosting soon. I've been suffering for so long from the shared packages, and I think it's time to seek a little peace of mind. I hope this would be a solution. Thanks a lot for your time, guys. Sincerely, Ehab |
I have similar issues randomly once or twice a month.
I will keep an eye out for the source code next time it happens. :) Quote:
Quote:
Thanks --------------- Added [DATE]1289246952[/DATE] at [TIME]1289246952[/TIME] --------------- I got the error again.. here is what it said. Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> latest error code.. Code:
mysql_connect() [<a href='function.mysql-connect'>function.mysql-connect</a>]: Too many connections |
Quote:
|
Heres one I get:
Code:
Database error in vBulletin 4.1.0: |
"MySQL Server has gone away" is a server issue. See this: http://www.vbulletin.com/docs/html/t...mysql_goneaway and this: http://www.vbulletin.com/forum/showt...265#post310265
|
All times are GMT. The time now is 09:43 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|