How To Install mod_bandwidth



Learn Web Hosting Help and Information on mps-web-hosting.com. How To Install mod_bandwidth article will help answer your questions on Web Hosting Help and Information.We at mps-web-hosting.com specialize in Web Hosting Help and Information. Web Hosting Help and Information at mps-web-hosting.com provides the most up to date news and articles. If you have questions please do not hesitate to contact us.

What is Mod_Bandwidth? (What is mod bandwidth?)

'Mod_bandwidth' (mod bandwidth) is a module for the Apache webserver that enable the setting of server-wide or per connection bandwidth limits, based on the directory, size of files and remote IP/domain.

For Apache 1.3x. ONLY! This how-to is not compatible with old versions of apache, including but not limited to 1.3beta

How to install mod_bandwidth

1. Login to your server via SSH as root.

2. Type: mkdir /root/mod_bw

3. Type: cd /root/mod_bw

4. Type: wget ftp://ftp.cohprog.com/pub/apache/mod...od_bandwidth.c

5. Type: /usr/local/apache/bin/apxs -c /root/mod_bw/mod_bandwidth.c -o /usr/local/apache/libexec/mod_bandwidth.so

6. Type: mkdir /usr/local/apache/bw_limit

7. Type: mkdir /usr/local/apache/bw_limit/link

8. Type: mkdir /usr/local/apache/bw_limit/master

9. Type: pico -w /etc/httpd/conf/httpd.conf

10. Locate the following Line: LoadModule rewrite_module libexec/mod_rewrite.so

11. Before the above line add this: LoadModule bandwidth_module libexec/mod_bandwidth.so

12. Now locate this line: AddModule mod_env.c

13. Before the above line add this: AddModule mod_bandwidth.c

14. Now locate this line: # Document types.

15. Before the above line add this: BandWidthDataDir '/usr/local/apache/bw_limit' BandWidthModule On

16. To enable mod_bandwidth on a virtual host locate the virtual host entry for the specified domain/acount you wish to limit. Just before the line add the following: BandWidthModule On BandWidth all 512

The 512 can be replaced with whatever rate you wish to limit the acount too.

17. Save the file and exit. CTRL-X then Y then enter.

18. Type: service httpd restart

19. Type: cd /usr/sbin

20. Type: wget ftp://ftp.cohprog.com/pub/apache/module/cleanlink.pl

What is cleanlink? Cleanlink is a deamon that is used to clean links created by mod_bandwidth when they aren't removed properly by the server. (When a httpd process doesn't terminate the usual way.)

21. Type: chmod 755 cleanlink.pl

22. Type: pico -w cleanlink.pl

23. Change $LINKDIR to the following: $LINKDIR='/usr/local/apache/bw_limit/link';

24. Save the file and exit. CTRL-X then Y then enter.

25. Type: perl cleanlink.pl

26. Type: pico -w /etc/rc.d/rc.local

27. Scroll down to the very end of the file and add the following: # The following line Launches CleanLink for Mod_Bandwidth perl /usr/sbin/cleanlink.pl

28. Save the file and exit. CTRL-X then Y then enter.

mod_bandwidth has many options. If you wish to modify mod_bandwidth and enable more options please visit the documentation available by the programmer here: http://www.cohprog.com/v3/bandwidth/doc-en.html

Original: http://www.ukwebmasterforums.com/t4907-how-to-install-modbandwidth.html

Web Hosting UK (http://www.session9.co.uk/ )

Webmaster Forums ( http://www.ukwebmasterforums.com/ )

Web Hosting Affiliate ( http://www.session9.co.uk/web-hosting-affiliate/ )

Domain Reseller ( http://www.domainvendor.co.uk/ )




Bird Flu - Help Protecting Your Family. - New eBook provides help for the developing pandemic. No installation and you turn the pages like a book on your monitor.
Secrets Of A Professional Installer. - Car stereo installation guide from a pro! Over 150 pgs!

CleverDot offers everything from domain name registration to several well priced hosting plans. There’s pretty much something for every one, but let’s see what their Pro Plan has to offer. This plan is priced at $14.95 per month, but if you purchase a year’s worth of hosting, you get two months free. A surprising 10 gigs [...]


Article Index: | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31


More Articles:


1. Provide A Good Home For Your Website By Terry McDermott
Selecting a web hosting company is like sending one of your children off to college. You may have complete confidence in your son or daughter’s abilities but unless they are placed in the proper environment they will not have the opportunity to thrive. Likewise, no matter how sophisticated or impressive the website you have designed may be, if you do not place the site where it can perform optimally you will likely be disappointed in the results.Selecting web hosting is not simply finding a pl…

2. Virtual hosting the affordable hosting solution for reseller web hosting companies
Virtual Hosting is the perfect solution for those who have outgrown shared hosting but don't have the budget to go for dedicated server hosting. Virtual hosting offers affordable hosting plans and solutions for affordable domain hosting. Virtual hosting is known by different names such as VPS Server, VPS Root, VPS Server, VDS, Virtual Dedicated Server, and Virtual Shared Server. Virtual hosting provides more control than the shared hosting but helps one to save money on net working and adminis…

3. The 2 Sides of Reseller Web Hosting By Rodney Ringler
In the first case the customer is really looking for a large shared hosting plan that allows multiple domains. More frequently in the industry you see the term “Multi-Domain account” to refer to these plans. These customers can be webmasters with a network of websites, web designers, or a company that wants separate websites for their different brands. Most people doing business on the internet have more then 1 website. Hosting companies have recently taken notice to this and started offering …

4. Webhosting Reseller Programs - Look Before You Leap!
So, you're considering reselling and you need the straight scoop on it? There are so many hosting companies, all claiming to be the best deal, and all telling you that you'll make more money reselling their services. Who's to trust? Which is best? Hopefully you have questions about the business itself. How does this all work? How do I set my prices? How do I market the product? What works? What doesn't? Who is my competition? My name is Larry Dozier, and I am part owner of a primary web presence…