Two questions about mod_bandwidth

pkilam

Verified User
Joined
Oct 27, 2004
Messages
115
After reading the doc on the mod_bandwidth site, i have the following two questions on mod_bandwidth config.

1. If I put the following on the virtual host block:

bandwidth all 10000

Does the limit 10K/s represent the total bandwidth allowed for that particualr virtual host (ie. the combined bandwidth from all remote acess host)

or

Does the limit 10K/s represent the bandwidth allowed between that particular virtual host and anyone of the remote access host?


2. For the statement

MaxConnection 10

Does it limit the combined total number of connections allowed from all remote host

or

does it limit the number of connections allowed from anyone of the remote host

sorry for my poor english.
thanks in advance
 
pkilam said:
After reading the doc on the mod_bandwidth site, i have the following two questions on mod_bandwidth config.

1. If I put the following on the virtual host block:

bandwidth all 10000

Does the limit 10K/s represent the total bandwidth allowed for that particualr virtual host (ie. the combined bandwidth from all remote acess host)

or

Does the limit 10K/s represent the bandwidth allowed between that particular virtual host and anyone of the remote access host?

Your first statement is correct. The "Bandwidth all" directive is the total bandwidth allowed for the directory and subdirectories, to be shared by all connections.

That's why there are the MinBandwidth and LargeFileLimit directives, so that things don't slow to a trickle when there are many connections.

2. For the statement

MaxConnection 10

Does it limit the combined total number of connections allowed from all remote host

or

does it limit the number of connections allowed from anyone of the remote host

As far as I can tell, MaxConnection is the total connections allowed, irrespective of client. So if one client started 10 connections, no one else would be able to get to that directory. Be careful with this one or you could start turning away users. If you put this at the root level of your website, then you could be locking people out.

Note: These are both "per directory" directives. I recommend that you apply them to specific directories where you may have a bandwidth problem, not to your apache document root directory.
 
Last edited:
Back
Top