Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 07-19-2005, 07:46 PM
edbri871 edbri871 is offline
 
Join Date: Apr 2005
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Speedup IP Searching?

Is there a way to speedup searching in the admincp by IP address?

I was looking to remove some from the database, but realized they are part of the posts table. :ermm:

The board has over 1,000,000 posts, and over 90,000 members altho a lot of those might be pruned soon.

Some ideas for improving the IP search in admincp would be great, or if I could be pointed to some mods for speeding it up that would be great too.
Reply With Quote
  #2  
Old 07-19-2005, 07:59 PM
tamarian tamarian is offline
 
Join Date: Oct 2001
Location: Canada
Posts: 1,205
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Easy. If you have a lot of disk space, add an index to your post table on the ip address field. It will run real fast. Big board generally need this.
Reply With Quote
  #3  
Old 07-19-2005, 08:27 PM
edbri871 edbri871 is offline
 
Join Date: Apr 2005
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for the reply.

Can you let me know a bit more about what this is going to do? How does it speed it up, and why will I need more disc space (i'll have to ask the board owner about that one)?
Reply With Quote
  #4  
Old 07-19-2005, 11:24 PM
tamarian tamarian is offline
 
Join Date: Oct 2001
Location: Canada
Posts: 1,205
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by edbri871
Thanks for the reply.

Can you let me know a bit more about what this is going to do? How does it speed it up, and why will I need more disc space (i'll have to ask the board owner about that one)?
Well, the post table is huge, usually the biggest in your vB database. If there is no index on the IP field, the query will have to search the entire post table, without an index. If you add an index by IP address, it will know where to look for, as they are already mapped. This will speed the IP search significantly. Without an IP index, your search will be slower as the post table gets bigger.

The disk space is required whenever you add an index, since the index will need to be stored on the hard disk. It will take a percentage of the size of the post table, so it's not too big (not bigger than the actual post table)
Reply With Quote
  #5  
Old 07-19-2005, 11:36 PM
edbri871 edbri871 is offline
 
Join Date: Apr 2005
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OK Thanks a lot for your help.

I will go ahead and try this, then post back with the results.

It worked! Thanks a lot for the help!
Reply With Quote
  #6  
Old 07-21-2005, 03:03 PM
beano33 beano33 is offline
 
Join Date: Feb 2003
Posts: 124
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by edbri871
OK Thanks a lot for your help.

I will go ahead and try this, then post back with the results.

It worked! Thanks a lot for the help!
I could really use this too. Can you tell us exactly what you did? Thanks!
Reply With Quote
  #7  
Old 07-21-2005, 03:54 PM
tamarian tamarian is offline
 
Join Date: Oct 2001
Location: Canada
Posts: 1,205
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by beano33
I could really use this too. Can you tell us exactly what you did? Thanks!
To add an index on ip adresses in the post table, you can do it in a couple of ways.

1. If you have phpMyAdmin, just scroll and click on the post table, which will show the table's fields. Then on the ipaddress field, click the index button.

2. Or, from the admin panel MySQL tool, enter this query:
ALTER TABLE 'post' ADD INDEX ( `ipaddress` )
(add the table prefix to 'post' if you use one.
Reply With Quote
  #8  
Old 07-21-2005, 05:40 PM
beano33 beano33 is offline
 
Join Date: Feb 2003
Posts: 124
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks, it works great.
Reply With Quote
  #9  
Old 02-27-2006, 07:58 PM
beano33 beano33 is offline
 
Join Date: Feb 2003
Posts: 124
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is there a similar way to add an index to the table that's searched for users online? It would be nice to have it on without killing the server.
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 10:08 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.04526 seconds
  • Memory Usage 2,234KB
  • Queries Executed 11 (?)
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
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (9)postbit
  • (9)postbit_onlinestatus
  • (9)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_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