Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > General > General Hosting/Server Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Move main site tables into vB DB Details »»
Move main site tables into vB DB
Version: , by JohnGaf JohnGaf is offline
Developer Last Online: Apr 2008 Show Printable Version Email this Page

Version: Unknown Rating:
Released: 01-03-2008 Last Update: Never Installs: 0
 
No support by the author.

Hi there,

We have a large vBulletin forum and a custom CMS for our main pages which is currently in two different databases. The main page database has around 20 tables in it.

Was just snooping around on phpMyAdmin earlier and looking at the different query types and saw that "change db" was 34.84% of the queries.

Was just thinking that if I move all the tables to the same database as vB (and perhaps just add a prefix to get more of a system) we would save 1/3 of the queries, which would help a lot on the mySQL server which is already struggling.

Could anyone think of disadvantages by doing it this way?

Quick SQL stats:
Quote:
This MySQL server has been running for 1 days, 1 hours, 4 minutes and 12 seconds. It started up on Jan 02, 2008 at 09:00 PM.

Query statistics: Since its startup, 21,645,953 queries have been sent to the server.

Average queries pr second: 239

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #2  
Old 01-03-2008, 08:41 PM
SEOvB's Avatar
SEOvB SEOvB is offline
 
Join Date: May 2007
Location: Indianapolis
Posts: 2,451
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You can always test it out, see if the mySQL server load drops and if it does then good move.

If not you can always just move them back and chalk it up as a learning experience
Reply With Quote
  #3  
Old 01-03-2008, 08:53 PM
JohnGaf JohnGaf is offline
 
Join Date: Jun 2007
Posts: 7
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yeah, but I was thinking more in the lines if vB (or some operations from the Control Panel) could do something to the "unknown" tables that don't have anything to do with vB.
Reply With Quote
  #4  
Old 01-04-2008, 02:21 AM
SEOvB's Avatar
SEOvB SEOvB is offline
 
Join Date: May 2007
Location: Indianapolis
Posts: 2,451
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Not unless you've got tables named the same on your CMS as vbulletin uses, but that can be fixed by using prefixes such as CMS_tablename and vb3_tablename or the such
Reply With Quote
  #5  
Old 01-04-2008, 05:41 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I doubt merging the databases would make any difference (maybe even negative). Change DB is a very inexpensive operation and will anyways need to be done once for each connection. I don't know how your custom application is written, but it will create a connection to a database anyways, this connection must select a database to operate on and i doubt your application will re-use the vB connection even if they are both in the same database.
Reply With Quote
Reply


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 12:49 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04996 seconds
  • Memory Usage 2,234KB
  • Queries Executed 20 (?)
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)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (5)post_thanks_box
  • (5)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (5)post_thanks_postbit_info
  • (4)postbit
  • (5)postbit_onlinestatus
  • (5)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