Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
  #1  
Old 06-12-2008, 09:10 PM
JetSkiing JetSkiing is offline
 
Join Date: Apr 2008
Location: The West Coast (of FL)
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default My board keeps maxing CPU usage

Our board keeps getting long queries (30-300 secs) that slows the whole server to a crawl (including our other no-forum sites) due to CPU usage. Currently using VB 3.5.1 with SQL 5.0 on a (2) CoreDuo, 8Gb ram server. Could it be SQL injections, DDoS attacks or coding issues. Any ideas on what types of queries are causing these problems? Our server host has provided the PHP code on the long queries but can't see anything unusual in them.

Info: We have 20000+ members and 1+ million posts.
Reply With Quote
  #2  
Old 06-12-2008, 09:34 PM
Opserty Opserty is offline
 
Join Date: Apr 2007
Posts: 4,103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

vBulletin in its normal format should run just fine, so it is probably to do with your modifications. Just disable them all and see which is causing the problems.

Theres not much else really we can do... disable any options in the vBulletin Options which aren't recommended for large boards (typically given in the option description)
Reply With Quote
  #3  
Old 06-13-2008, 10:09 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Normal vBulletin queries should not run for that long - it is probably caused by one of your modifications, as Opserty has said.
Reply With Quote
  #4  
Old 06-13-2008, 04:27 PM
JetSkiing JetSkiing is offline
 
Join Date: Apr 2008
Location: The West Coast (of FL)
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is it possible that the long searches are caused by an SQL injection or DDOS attack, or is this rather unlikely? I've read that Vbulletin can be vulnerable, what I don't know is whether it is common. Have you guys ever heard of such attacks on Vbulletin? The other night I found a whole forum on how to attack Vbulletin. Nevertheless, from what you guys are saying it's most likely a modification that is unstable on a forum our size, right?"
Reply With Quote
  #5  
Old 06-13-2008, 04:32 PM
Opserty Opserty is offline
 
Join Date: Apr 2007
Posts: 4,103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It might it might not be... like I said there isn't much we can do. Find out which queries are taking long if they are from modifications then disable those modifications. It could be a modification, just test and find out for yourself. We aren't going to offer you unsuitable advice, we are here to help you.

Both vBulletin.com and .org are fairly large sites and they don't have large load times so it is something specific to your board. (vBulletin runs all these modifications too so...)

It might be some kind of attack but I doubt it. If your host is any good they should be able to analyse any stats they have and tell you what is going on. But if it is just queries it means there is something up with the MySQL or some SQL Queries.
Reply With Quote
  #6  
Old 06-13-2008, 06:11 PM
MixMakers MixMakers is offline
 
Join Date: Apr 2005
Posts: 110
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Opserty View Post
It might it might not be... like I said there isn't much we can do. Find out which queries are taking long if they are from modifications then disable those modifications. It could be a modification, just test and find out for yourself. We aren't going to offer you unsuitable advice, we are here to help you.

Both vBulletin.com and .org are fairly large sites and they don't have large load times so it is something specific to your board. (vBulletin runs all these modifications too so...)

It might be some kind of attack but I doubt it. If your host is any good they should be able to analyse any stats they have and tell you what is going on. But if it is just queries it means there is something up with the MySQL or some SQL Queries.
How can you find that out?
Reply With Quote
  #7  
Old 06-13-2008, 09:34 PM
JetSkiing JetSkiing is offline
 
Join Date: Apr 2008
Location: The West Coast (of FL)
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

One of the long queries was:
"# Query_time: 281 Lock_time: 0 Rows_sent: 100 Rows_examined: 477587
SELECT thread.threadid, thread.title,
thread.postusername, thread.dateline,
forum.forumid,
forum.title AS forumtitle,
post.pagetext AS preview

FROM vb_thread AS thread
INNER JOIN vb_forum AS forum ON(forum.forumid = thread.forumid)
LEFT JOIN vb_post AS post ON (post.postid = thread.firstpostid)

WHERE 1=1
AND thread.forumid IN(8,27,44,25,41,48,58,86,99,49,7,39,45,4,11,71,64 ,12,26,72,3,59,34,18,42,21,100,101,16,17,15,19,14, 9,62,91,84,83,46,93,80,90,66,96,1
03,70,47,89,88,38,37,98,61,76,92,85,75,102,43,79,6 3,73,82,40,94,55,69,56,57,33,68,81,6,77,65,13,22,2 3,54,29)
AND thread.visible = 1
AND post.visible = 1
AND open <> 10"

--------------- Added [DATE]1213396545[/DATE] at [TIME]1213396545[/TIME] ---------------

Our current hacks are:

Arcade
Automatic Welcome
Force Profile Update
Last 15 Searches
Left Column
Links and Download Manager
Members who have visited the forum
Miserable Users
Multiple Login Detector
phpAdsnew Intergration
Super Private Message
vBShout
Welcome Headers
VBAdvanced 1.x

we also had two searches available - one from the top and a window in the left column.
Reply With Quote
  #8  
Old 06-14-2008, 06:47 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm willing to say that it might be a vBAdvanced module.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07: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
  • Page Generation 0.11223 seconds
  • Memory Usage 2,216KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (8)post_thanks_box
  • (8)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (8)post_thanks_postbit_info
  • (8)postbit
  • (8)postbit_onlinestatus
  • (8)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete