View Single Post
  #15 (permalink)  
Old 26-04-2007, 23:49
247h's Avatar
247h 247h is offline
Premium Member
 
Join Date: Nov 2006
Location: Buckingham UK
Posts: 264
Send a message via AIM to 247h Send a message via MSN to 247h Send a message via Yahoo to 247h
Default

Thanks Shane — I'm a bit further forward but your tutorial is still lacking some detail and I'll stay here for the benefit of any others (rather than submitting a ticket)! You wrote:
Quote:
Now it's installed!
Now how to use it......?
Find the line:
What you omitted to say was which file needs to be edited and I presume it's
/user/local/apache/conf/httpd.conf ?

The description then becomes a little disjointed but between you and Mark, you indicated that at the closure of each domain's 'VirtualHost' entry (that you wish to throttle), you insert this code:
Code:
< IfModule mod_throttle.c >
ThrottlePolicy Volume 1G 1d
< /IfModule >
< Location /throttle-me >
SetHandler throttle-me
< /Location >
and here's a complete VirtualHost example in the way I understood this:
Code:
<virtualhost 87.117.***.***="">< VirtualHost 87.117.***.*** >
ServerAlias domain.com
ServerAdmin webmaster@domain.com
DocumentRoot /home/accountname/public_html
BytesLog domlogs/domain.com-bytes_log
User accountname
Group accountname
ServerName www.domain.com

User accountname
Group accountname
CustomLog /usr/local/apache/domlogs/domain.com combined
ScriptAlias /cgi-bin/ /home/accountname/public_html/cgi-bin/

< IfModule mod_throttle.c >
 ThrottlePolicy Volume 1G 1d
 < /IfModule >
 < Location /throttle-me >
 SetHandler throttle-me
 < /Location ></virtualhost>
< /VirtualHost >
I presume the 'ThrottlePolicy Volume' values shown here, '1G 1d', represents 1GB/day — would you please list the other abbreviations that may be used?

Now, the part that prevented me from completion was this, because you weren't clear about *where* the extra parameters should be entered. You wrote:
Code:
Now, also go to the very first virtual host entry, and add these lines:

Quote:
< Location /throttle-status >
SetHandler throttle-status
< /Location >
Using the first entry example from my own server's httpd.conf can I presume the extra parameters go at the end? Viz:
Code:
< VirtualHost 87.117.***.*** >
BytesLog domlogs/hostname.domain.com-bytes_log
ServerName hostname.domain.com
DocumentRoot /usr/local/apache/htdocs
< Location /throttle-status >
SetHandler throttle-status
< /Location >
< /VirtualHost >
OK, I'm reluctant to experiment with my httpd.conf until I receive confirmation of these final steps, but that is the end of my questions regarding mod_throttle, however ...

Going off at a tangent again, can I say that in writing the above message I discovered other unexpected problems with vBulletin — first, the Code tags are surely supposed to allow anyone to enter ANY and ALL code expressions and display them without any formatting issues — not so here! In order to display them here, every one of those open/close expressions has to have white space added after the opening bracket and before the closing bracket, or when you preview/submit the message, the expression is discarded from the output! This problem applies equally to a Quote window (as you discovered, Mark, but that's to be expected). Additionally, each Code window when displayed has an excess of white space at the end (those shown above are not due to me adding extra carriage returns).

This would be a complete nonsense for such a leading forum software and as I said earlier I have little current experience of using vBulletin these days, I no longer know whether this is/was typical or not — so I went to check elsewhere and the bad news, for you, is that this doesn't happen in another vBulletin forum I tried!!

There is one obvious visual difference — your forum's Code window is formatted in Verdana, just like the rest of the message; I'd say it is more typical that a Code window is formatted in Courier, or raw text (whichever) so is it that you have made a change and introduced this problem unwittingly? I suggest that in Courier, the chevrons would be represented in source code by their code form of '& l t ;' and '& g t ;' (yes I had to add white space to allow them to be displayed)!

Late edit: I was just re-reading my post and switched to the Proweb Fluid skin, only to find that Code window contents are then displayed in Courier, but still with the same problem! :eek: Sorry for any confusion — I think what I mean is that this forum's Code window contents seem to be displayed in HTML, not in unformatted text (as in the other vBulletin forum I tried).
__________________
Gadge

Too many nice toys — too little time to play with 'em!

Last edited by 247h; 21-10-2007 at 14:25. Reason: repair emdashes changed by database update to utf-8
Reply With Quote