Results 1 to 24 of 24
  1. #1
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508

    Limiting BW in Linux

    I need some help and am not sure if it is even possible. Is there a way to limit bandwidth on a Linux server?

    Thanks for any suggestions!
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  2. #2
    Join Date
    Nov 2001
    Location
    London
    Posts
    4,857
    I assume your looking to limit bandwidth per domain? If you're running Apache, there are a number of modules that acheive this (in different ways). Check out mod_bwlimited, mod_throttle and mod_limit.

    Matt
    Matthew Russell | Namecheap
    Twitter: @mattdrussell

    www.namecheap.com - hosting from a registrar DONE RIGHT!

  3. #3
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    As you can tell, I am not a Linux person I am helping out a friend and he is using webmin. Can someone point me in the right direction? I did not see any of these, mod_bwlimited, mod_throttle and mod_limit?

    Yes, it's for one domain/ip that we want to limit.

    THANKS!
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  4. #4
    Join Date
    Jul 2002
    Location
    Canada
    Posts
    248
    I know mod_throttle is located here: http://www.snert.com/Software/mod_throttle/

    Sorry, don't know about the others...
    Signature.

  5. #5
    Join Date
    Nov 2001
    Location
    London
    Posts
    4,857
    Details on mod_throttle can be found at http://www.bigrock.com/~mlovell/throttle/

    It's probably the best option for what you want to do...

    A quick search on TLDP also found this:
    http://tldp.org/HOWTO/Apache-Overview-HOWTO-5.html

    As a general rule, if you can do it on Windows, Linux can do it twice as good
    Matthew Russell | Namecheap
    Twitter: @mattdrussell

    www.namecheap.com - hosting from a registrar DONE RIGHT!

  6. #6
    If I remember correctly, I beleive Snert.com's mod_throttle succeeded Lovel's older mod_throttle.

    Brian

  7. #7
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    Ok, got mod_throttle installed, but am not sure how to set it up in httpd.conf. I tried what was listed, but kept getting an error. Ideas?

    Thanks!
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  8. #8
    Join Date
    Aug 2002
    Location
    Phoenix, AZ
    Posts
    3
    How about giving us the error?

  9. #9
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    Nevermind, got it working

    Thanks to all!!!!
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  10. #10
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    OK, I tought I had it working but I was wrong. I set-up the following policy in httpd.conf

    <IfModule mod_throttle.c>
    ThrottlePolicy Volume 1M 1m
    ThrottleRefresh 60

    <Location /throttle-status>
    SetHandler throttle-status
    </Location>

    <Location /throttle-client-ip>
    SetHandler throttle-client-ip
    </Location>

    <Location /throttle-me>
    SetHandler throttle-me
    </Location>

    <Location /~*/throttle-me>
    SetHandler throttle-me
    </Location>
    </IfModule>

    It is running because this is what I get on the status page:

    % - 14184
    Hits - 13302
    Refused - 0
    KBytes sent - 145250
    KBytes per hit - 10
    Delay (<=30) - 0
    Policy - Volume
    Limit - 1M
    Period - 1m
    Period Elapsed - 8.08
    Idle Time - 0

    Any ideas on where I am going wrong?
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  11. #11
    Join Date
    Jan 2002
    Location
    Kuwait
    Posts
    679
    As a side note, if you are giving your client a dedicated IP, you can have an IP level limit using iptables. This might be more accurate, because it can calculate HTTP, mail, FTP and any other application that binds to the users IP address.
    Ahmad Alhashemi
    PHP, Apache, C, Python, Perl, SQL
    18 related BrainBench certificates

  12. #12
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    Can you give me more info on how?
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  13. #13
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    Anyone?
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  14. #14
    Join Date
    Mar 2002
    Location
    St. Louis, MO
    Posts
    1,378
    Ahmad you talkin about how traffic should be classified? like
    Mark ALL packets as 0x03. This places all packets, by default, into the lowest priority queue.

    Mark ICMP packets as 0x00. Mark all packets that have a destination port 1024 or less as 0x01.... etc etc ? I remember reading something about this the other day

  15. #15
    Join Date
    Jan 2002
    Location
    Kuwait
    Posts
    679
    Sorry I didn't notice the replies.

    No, that was a different thing. What I'm talking about here is IP accounting, about which I don't know a lot.

    Try chapter 10 "IP Accounting" in "Linux Network Administrators Guide" (An oreilly book available online):

    http://www.oreilly.com/catalog/linag2/book/ch10.html
    Ahmad Alhashemi
    PHP, Apache, C, Python, Perl, SQL
    18 related BrainBench certificates

  16. #16
    Join Date
    Nov 2001
    Posts
    852
    I am also reminded of this thead:
    http://www.webhostingtalk.com/showth...ht=modthrottle

  17. #17
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    All these Linux experts and no one can solve my problem
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  18. #18
    Join Date
    Mar 2002
    Location
    St. Louis, MO
    Posts
    1,378
    I am no linux expert by anymeans, but searching the net
    this is what i came up with if you want to read it. Wish I could help more

    http://www.ibiblio.org/pub/Linux/doc...ing-HOWTO.html

  19. #19
    http://www.etinc.com

    Nice bandwidth control and accounting system. Can be installed on a server or as a network appliance.

    Just make sure you can follow directions and know how to recompile a kernel. The guy that runs the place can difficult to work with at times, even after you've paid for the product and an update subscription.
    Sincerely,
    Andrew Kinney
    CTO, Advantagecom Networks
    http://www.SimplyWebHosting.com

  20. #20
    Join Date
    Jan 2002
    Location
    Kuwait
    Posts
    679
    Originally posted by RackMy.com
    All these Linux experts and no one can solve my problem
    LOL.

    I know a couple of people that can answer ANY linux question. But haven't seen any of them for a while.

    I'm still learning Linux.
    Ahmad Alhashemi
    PHP, Apache, C, Python, Perl, SQL
    18 related BrainBench certificates

  21. #21
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    I am kind of shocked that no one can help. I quess if it's not a control panel option....
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  22. #22
    Join Date
    Jan 2002
    Location
    Kuwait
    Posts
    679
    You can try forums dedicated to Linux. The situation will be completely different.
    Ahmad Alhashemi
    PHP, Apache, C, Python, Perl, SQL
    18 related BrainBench certificates

  23. #23
    Join Date
    Apr 2001
    Location
    St. Louis, MO
    Posts
    2,508
    Last call of help, anyone have any ideas? And I thought Linux was better that Windows (prod, poke, )
    Mike @ Xiolink.com
    http://www.xiolink.com 1-877-4-XIOLINK
    Advanced Managed Microsoft Hosting
    "Your data... always within reach"

  24. #24
    Join Date
    Jan 2002
    Location
    Kuwait
    Posts
    679
    Originally posted by RackMy.com
    ..
    And I thought Linux was better that Windows (prod, poke, )
    grrrr



    Ahmad Alhashemi
    PHP, Apache, C, Python, Perl, SQL
    18 related BrainBench certificates

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •