Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 Programming Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 07-31-2007, 11:08 PM
foopy foopy is offline
 
Join Date: Jan 2006
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Possible to restrict forum access during heavy traffic?

Is it possible to restrict forum access by usergroup during server heavy load times? Any help appreciated.
Reply With Quote
  #2  
Old 08-01-2007, 10:32 AM
CyberRanger's Avatar
CyberRanger CyberRanger is offline
 
Join Date: Mar 2004
Posts: 1,319
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It would be possible but you'd need to tweak some vb code. If you are running a *nix type server (like Linux), there is an option under vbulletin options -> Server Settings and Optimization Options called *NIX Server Load Limit.

Once you set this, it is evaluated in global.php around line 811.

PHP Code:
// check to see if server is too busy. this is checked at the end of session.php
if ($servertoobusy AND !($vbulletin->userinfo['permissions']['adminpermissions'] & $vbulletin->bf_ugp_adminpermissions['cancontrolpanel']) AND THIS_SCRIPT != 'login')
{
        
$vbulletin->options['useforumjump'] = 0;
        eval(
standard_error(fetch_error('toobusy')));

You could change the if condition to allow the groups you want.
Reply With Quote
  #3  
Old 08-01-2007, 11:50 AM
foopy foopy is offline
 
Join Date: Jan 2006
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you so much for that info.

I understand the concept of editing the if condition, however not really being a coder I don't know exactly what to change. Would you consider giving me that info in detail? During heavy load times I want only admins, mods/supermods and one usergroup named premium members to have access.

Thanks again for taking the time to help.
Reply With Quote
  #4  
Old 05-23-2008, 06:02 AM
Chuck Holton Chuck Holton is offline
 
Join Date: Feb 2008
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CyberRanger View Post
It would be possible but you'd need to tweak some vb code. If you are running a *nix type server (like Linux), there is an option under vbulletin options -> Server Settings and Optimization Options called *NIX Server Load Limit.

Once you set this, it is evaluated in global.php around line 811.

PHP Code:
// check to see if server is too busy. this is checked at the end of session.php
if ($servertoobusy AND !($vbulletin->userinfo['permissions']['adminpermissions'] & $vbulletin->bf_ugp_adminpermissions['cancontrolpanel']) AND THIS_SCRIPT != 'login')
{
        
$vbulletin->options['useforumjump'] = 0;
        eval(
standard_error(fetch_error('toobusy')));

You could change the if condition to allow the groups you want.
Is there a way to implement the above just tell "guests" things are too busy during high loads - allowing registered users to carry on?
Reply With Quote
  #5  
Old 11-09-2009, 04:31 AM
AURFSCAN AURFSCAN is offline
 
Join Date: Dec 2007
Posts: 328
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CyberRanger View Post
It would be possible but you'd need to tweak some vb code. If you are running a *nix type server (like Linux), there is an option under vbulletin options -> Server Settings and Optimization Options called *NIX Server Load Limit.

Once you set this, it is evaluated in global.php around line 811.

PHP Code:
// check to see if server is too busy. this is checked at the end of session.php
if ($servertoobusy AND !($vbulletin->userinfo['permissions']['adminpermissions'] & $vbulletin->bf_ugp_adminpermissions['cancontrolpanel']) AND THIS_SCRIPT != 'login')
{
        
$vbulletin->options['useforumjump'] = 0;
        eval(
standard_error(fetch_error('toobusy')));

You could change the if condition to allow the groups you want.

Hi everyone, I know this is an old post but I need to do this temporarily.

restrict usergroup 1, 2, 22

How do I rewrite the IF statement and also will this work on 3.7.3

thanks for any help and replies

regards
darren
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 03:27 PM.


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.03729 seconds
  • Memory Usage 2,221KB
  • 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
  • (3)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)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
  • (5)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