Networking Forums

Networking Forums > Computer Networking > Linux Networking > What tools do I need to limit bandwidth usage?

Reply
Thread Tools Display Modes

What tools do I need to limit bandwidth usage?

 
 
George Adams
Guest
Posts: n/a

 
      02-12-2004, 07:19 PM
Our church has a Gentoo Linux server with a number of audio files
(sermons mostly) that are available both for streaming (RealAudio) or
downloading. However, since people who download multiple files tend
to kill the bandwidth for RealAudio listeners, I'd really like to put
some rules like this in place:

1) SSH connections (i.e. me connecting remotely) get all the bandwidth
they can consume.

2) RealAudio streaming clients get all the bandwidth left after #1
that they can consume.

3) Web downloaders get all the bandwidth left after #1 and #2 that
they can consume.

3a) No single web downloader can download more than N files at a time.

So ideally, if no-one is using the server and User A wants to download
3 files, then they can have all the server's bandwidth. If User B and
User C connect to stream RealAudio sermons, however, then they will
get as much bandwidth as they need to get a good connection, and User
A will be given ONLY whatever bandwidth is left. And ideally User A
will not be able to download more than, say, 3 files simultaneously.

I can see I have my work cut out for me, so before I dive in too
deeply, I'd like to figure out which area to focus my efforts on.
I've seen tutorials on bandwidth limiting with Squid and CBQ
(http://www.linuxforum.com/linux-bandwidth-limit/), advanced Linux
routing and traffic control
(http://en.tldp.org/HOWTO/Adv-Routing-HOWTO/), mod_bandwidth for
Apache2 (http://www.cohprog.com/mod_bandwidth.html), and at the moment
I'm not sure where to even start. (I'll give an example - in the
Squid tutorial, the author hints that it's possible to use Squid to
limit downloading traffic over port 80 to, say, 75% of available
bandwidth, but it's NOT possible to increase that to 100% if no one
else is using the bandwidth. So maybe Squid isn't the right tool
after all...?)

I would appreciate anyone who can point me in the right direction and
help me get started. Thank you!
 
Reply With Quote
 
 
 
 
Pete Houston
Guest
Posts: n/a

 
      02-18-2004, 04:11 PM
In article <(E-Mail Removed) >,
George Adams wrote:
> So ideally, if no-one is using the server and User A wants to download
> 3 files, then they can have all the server's bandwidth. If User B and
> User C connect to stream RealAudio sermons, however, then they will
> get as much bandwidth as they need to get a good connection, and User
> A will be given ONLY whatever bandwidth is left. And ideally User A
> will not be able to download more than, say, 3 files simultaneously.


There are two separate issues here, George. The first is the allocation
of bandwidth to the various types of service and the borrowing of spare
bandwidth between them. This is all covered in the LARTC (Linux Advanced
Routing and Traffic Control) Howto, which is at tldp.org and elsewhere.
You will probably want to look at tcng as well, which will help to save
you from the arcane syntax as far as possible (see
http://linux-ip.net/articles/htb-and-tcng.html for an example).
Do think about joining the LARTC mailing list as well, lots of good
stuff on there.

The second issue (limiting any one user to N simultaneous downloads) is
application specific. It can be done in Apache (for example), but you
will have to decide what constitutes a user and what constitutes a
download. If the only resource which you are trying to protect is your
bandwidth (as opposed to the server memory or CPU), then just limit the
bandwidth as above and it won't matter to you how many downloads are in
progress if they all proceed at a snail's pace.

HTH,

Pete
--
Openstrike - improving business through open source
http://www.openstrike.co.uk/
 
Reply With Quote
Reply

Thread Tools
Display Modes

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
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Limit Broadband DSL usage at home shyamvk@gmail.com Broadband 31 03-10-2007 09:50 AM
BT Broadband Basic Usage over the limit Madsharpei Broadband 1 10-10-2005 05:58 PM
How to automatically limit GPRS-usage to urgent matters only ? Jan Wireless Networks 3 02-22-2005 07:45 PM
Q: Limit client's bandwith-usage of router/gateway? Tom H. Lautenbacher Linux Networking 6 06-03-2004 03:41 PM
Quality of Service: how to limit W2K3 (RAS) VPN bandwidth usage Sander van Beek Windows Networking 0 05-28-2004 08:22 PM



1 2 3 4 5 6 7 8 9 10 11