The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Opened MySQL connections on vB 3.8.4
Hello there,
I have a problem in my vB installation which creates connections that won't close. Let me explain. I log in into phpmyadmin and run "show status like '%conn%';" and see 800.000 connections. After 1 minute, these connections may be 801.000, and so on. My host found an attack before some days and restarted MySQL, so this number started from 0 and now, after 6 days this number is 800.000+. My host told me that there are somewhere code lines that open a connection with MySQL and they never close it. I have about 5.000 php files in forum's installation and I have no idea how to check this. Sorry for my english. I wish I explained the situation properly. Thank you |
#2
|
||||
|
||||
There is nothing in default vBulletin that does that.
Its possible (but highly unlikely) you have some other software or addons. MySQL should close its own connections anyway if they are unused, sounds like your host has a very large value for "wait_timeout", it only needs to be about 120 - 180 for vbulletin, I've been using 180 for 10+ years, without any issues. |
#3
|
|||
|
|||
Hello Paul M,
Thank you for your reply. I don't think that is a server problem, although I can discuss it with my host. I have many addons installed, and I could disable all and enable one by one to see if the problem is still there. But I have about 15.000 people online all day, and this will make a problem to my users. If there is not any other way, I will try it, but as a last solution. Something that I forgot to say is that I am taking an error by email in default forum's email which refers to class_core.php on line 1206, but file seems to be fine. Error is here: Code:
mysqli_real_connect(): (HY000/2002): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) /var/www/html/includes/class_core.php on line 1206 |
#4
|
||||
|
||||
That message means php could not connect to the mysql server at all.
|
#5
|
|||
|
|||
Yes.. A colleague show me this email but didn't defined the date. It was under an SQL restart.. I am sorry.
Anyway, no solution until now for the connections. I wish I can find something, and I will post it here. Thank you again for your time. |
#6
|
||||
|
||||
You're probably reading it wrong. I'm not quite sure, but your post surely implies that. What I'm wondering: Your host really should know that...
Code:
show status like '%conn%'; Code:
Connections 4473207 Max_used_connections 33 Threads_connected 4 The connections currently open would show under "threads connected". See the example? That's over 4 million connections opened since last restart, but currently there's only 4 connections open. Of greater interest would probably be the all time high of connections open at the same time under "max_used_connections" - in this case 33. See: http://dev.mysql.com/doc/refman/5.7/...variables.html And yes, this server is running vB3. |
#7
|
|||
|
|||
Hello cellarius,
Thank you for your reply. The problem occurred when we made a SQL restart and connections increased to 65.000 in the first 30 minutes, when visitors where less than 1.000 that certain time. Anyway, my host informed me that there were some mass connections which where blocked. So there is no problem now. Instead of telling me this at the start of the problem, he talked to me about not closing sql inside my code. Everything is ok now. Thank you all! |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|