PDA

View Full Version : database error


hunter22375
05-19-2008, 08:42 PM
Can anyone tell me what these means or how to fix them?

Invalid SQL:

SELECT text, languageid, special
FROM vb_phrase AS phrase
LEFT JOIN vb_phrasetype USING (fieldname)
WHERE phrase.fieldname = 'error'
AND varname = 'registeremail' AND languageid IN (-1, 0, 1);

MySQL Error : MySQL server has gone away
Error Number : 2006
Request Date : Friday, May 16th 2008 @ 10:15:38 PM
Error Date : Friday, May 16th 2008 @ 10:15:49 PM
Script : http://thesourcecheck.com/forum/register.php?do=addmember
Referrer : http://thesourcecheck.com/forum/register.php?do=addmember
IP Address : XX.XX.XX.XX
Username : XXXXXXX
Classname : vB_Database
MySQL Version :

Database error in vBulletin 3.7.0:

Invalid SQL: UPDATE vb_datastore SET data = data - 1, data = IF(data < 0, 0, data) WHERE title = 'mailqueue';MySQL Error : MySQL server has gone away
Error Number : 2006
Request Date : Friday, May 16th 2008 @ 10:31:21 PM
Error Date : Friday, May 16th 2008 @ 10:31:36 PMScript : http://www.thesourcecheck.com/forum/index.php
Referrer : http://www.thesourcecheck.com/forum/private.php
IP Address : XX.XX.XXX
Username : XXXXXX
Classname : vB_Database
MySQL Version :

Thanks in advance.

Guest210212002
05-19-2008, 08:53 PM
Your MySQL server is timing out.

http://dev.mysql.com/doc/refman/5.0/en/gone-away.html

Lynne
05-19-2008, 08:53 PM
This is a server issue. See this: http://www.vbulletin.com/docs/html/troubleshoot_mysql_goneaway

hunter22375
05-19-2008, 08:57 PM
OK...timing out isn't necessarily a bad thing then? In other words, if you log back in or post something....the timer starts again? Also, will anything be harmed if I don't adjust the time out?

--------------- Added 1211234469 at 1211234469 ---------------

Also, note, everything on my board seems to be working just fine.

Jase2
05-19-2008, 09:20 PM
MySQL server has gone away

Have you read the link Lynne gave you?

Lynne
05-19-2008, 09:23 PM
OK...timing out isn't necessarily a bad thing then? In other words, if you log back in or post something....the timer starts again? Also, will anything be harmed if I don't adjust the time out?
Well, I guess it could be considered 'not a bad thing' if you don't mind your users getting errors. Most users though, I would think, would find it frustrating to be on a site and keep getting database errors. And, it has nothing to do with you being logged in or anything. It's a mysql thing.

Guest210212002
05-20-2008, 12:43 AM
OK...timing out isn't necessarily a bad thing then? In other words, if you log back in or post something....the timer starts again? Also, will anything be harmed if I don't adjust the time out?


That's not how it works unfortunately. A timeout means, in this case, that the request sent to your database server didn't get a response in an amount of time specified by your server, so it dropped the query.

In laymans terms, it's like knocking on a door, waiting for someone to answer, and after awhile nobody comes, and then you leave.

hunter22375
05-20-2008, 01:32 AM
OK...I understand....I read the link and it said the default time is 8 hrs....how much more should I set the time for then? Also, I have only received 2 of these errors....is it possible the server was just doen during those requests?

falconKing
05-20-2008, 03:50 AM
I have only received 2 of these errors

Lucky you, I receive 40+ different errors (see below e.g.) a day, althu, I have spoken to my host who increased the time period. But the problem remained :(

Database error in vBulletin 3.7.0:
Invalid SQL:
UPDATE vb_session
SET lastactivity = 1211229636, location = '/vb/attachment.php?attachmentid=95', inthread = 1955, incalendar = 0, badlocation = 0
WHERE sessionhash = '4043033dca101c8026e4b53fd01c9227';
MySQL Error : MySQL server has gone away
Error Number : 2006

Request Date : Monday, May 19th 2008 @ 09:40:36 PM
Error Date : Monday, May 19th 2008 @ 09:41:54 PM
Script : http://xxxxxxxx.com/vb/attachment.php?attachmentid=95
Referrer :
IP Address : 66.249.65.244

- Hide quoted text -
Username : admin
Classname : vB_Database_MySQLi
MySQL Version :

Guest210212002
05-20-2008, 10:18 AM
It's more likely a resource issue. How busy is your site when you get this error? You're probably just running out of CPU/Memory.

--------------- Added 1211282339 at 1211282339 ---------------

Also, edit the username and IP out of your first post - for security reasons. :)

hunter22375
05-20-2008, 12:35 PM
Thanks man...I never would have thought of that. My site is very new and only gets like 20-30 UV/day. I just thought of something else...when I installed VB..and had to edit the config.php file, I remember there was a part that sais "only change if VB tells you to"...and it had to do with MySQL and forcing something. First, I know its vaugue but I can't remember what it was exactly, but do you think that has something to do with it?

Lynne
05-20-2008, 01:54 PM
falconKing, are all of yours related to the attachment.php file? I had to steadily increase my wait_timeout due to attachment issues. 420 seemed to be the magic number for my site.

Hunter, yes, the default may be 8 hours, however your host may have it set at something else.

hunter22375
05-20-2008, 03:24 PM
I just contacted them...we'll see what happens. I bet they try to make me upgrade. LOL

--------------- Added 1211316541 at 1211316541 ---------------

Check this out.....I just got a response from my host:

"While your account is hosted on a shared hosting server, you are sharing your resources with the other users on the very same server.

Please kindly note that modifying the wait_timeout parameter will endanger the server overall performance. If you wish different wait_timeout parameter to be set for you, you need to consider upgrading of your hosting plan to VPS one"

What should I make of this?

steve71
06-27-2008, 11:41 AM
// ****** MASTER DATABASE PERSISTENT CONNECTIONS ******
// This option allows you to turn persistent connections to MySQL on or off.
// The difference in performance is negligible for all but the largest boards.
// If you are unsure what this should be, leave it off. (0 = off; 1 = on)
$config['MasterServer']['usepconnect'] = 0;

This is the config.php part that you were referring. I was told to leave it at 0 as I am getting the exact same issue right now with the mysql timing out. I get clusters of downtime lasting a few minutes at a time..I'm sure you are getting similar.

You can ignore it for now, and you can stop the e-mail notification if you'd really like to pretend it isn't happening. ;)

Otherwise you will have to consider trying a different host (lunarpages.com maybe) or move to a dedicated server. You might also want to consider removing any load heavy mods if you have any installed.

https://vborg.vbsupport.ru/showthread.php?t=113591&highlight=post+timer

hope that helps.