The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to config mod_bw for apache2 ?

Discussion in 'EasyApache' started by natong, Oct 11, 2008.

  1. natong

    natong Well-Known Member

    Joined:
    May 17, 2008
    Messages:
    85
    Likes Received:
    0
    Trophy Points:
    6
    I tried

    Code:
    /scripts/setbwlimit --domain=mydo.com --limit=1024000
    It created 4 files:
    Code:
    /usr/local/apache/conf/userdata/std/1/tid/mydo.com/cp_bw_all_limit.conf
    
    /usr/local/apache/conf/userdata/std/2/tid/mydo.com/cp_bw_all_limit.conf
    
    /usr/local/apache/conf/userdata/ssl/1/tid/mydo.com/cp_bw_all_limit.conf
    
    /usr/local/apache/conf/userdata/ssl/2/tid/mydo.com/cp_bw_all_limit.conf
    
    I tried to add
    Code:
    <IfModule mod_bw.c>
    BandWidthModule On
    BandWidth all 3072000
    MaxConnection all 20
    LargeFileLimit .zip 200000 2048000
    LargeFileLimit .mpg 200000 2048000
    LargeFileLimit .mp3 200000 2048000
    </IfModule>
    
    but when run
    Code:
    /scripts/ensure_vhost_includes --user=tid
    
    It switch back to default
    Code:
    <IfModule mod_bw.c>
      BandWidthModule On
      BandWidth all 3072000
    </IfModule>
    
     
  2. natong

    natong Well-Known Member

    Joined:
    May 17, 2008
    Messages:
    85
    Likes Received:
    0
    Trophy Points:
    6
    To unuse this module, don't forget to set to 0 (zero).

    /scripts/setbwlimit --domain=mydo.com --limit=0

    Otherwise it will stuck on you.

    You can check template files at /var/cpanel/userdata/<user>/*.*

    Looking the keyword : cp_bw_all_limit
     
  3. natong

    natong Well-Known Member

    Joined:
    May 17, 2008
    Messages:
    85
    Likes Received:
    0
    Trophy Points:
    6
    This module is useless. Try install by get the source code. Don't install by enable it in cpanel easyapache script.

    or use mod_cband instead.
     
Loading...

Share This Page