Posts tagged module
Lighttpd – A lighter Web Server
Dec 26th
The first thing to do it get lighttpd installed with php and mysql working smoothly. Rather than reiterating the same content here is a convenient post:
http://www.howtoforge.com/lighttpd_mysql_php_debian_etch
Interesting options and various configuration for lighttpd can be found here:
http://redmine.lighttpd.net/projects/lighttpd/wiki/Docs:ConfigurationOptions
One insteresting, built in, option is throttling. Use connection.kbytes-per-second and you can effectivly limit users to particular data transmission rates. There is also a compression module, and a caching module. Much like apache these modules can be installed with apt-get. Issue:
sudo apt-cache search lighttpd
This will list various packages that can be installed. I know the apache modules are packaged as libapache2-mod-*.
With built in round robin and proxy modules this is an interesting package to investigate using.
Apache Mod – Cband
Aug 23rd
The Cband Apache module can be downloded from the official website here:
This module provides full bandwith limiting of all Apache VirtualHosts. First reference the newly added module with:
LoadModule cband_module /etc/apache2/mod_cband.so
You can put the module anywhere you want, just adjust the directory location accordingly. Now you can add a VirtualHost as usually, and add the addition cband configuration parameters to establish desired functionality.
<VirtualHost *>
ServerName www.bgevolution.com
ServerAdmin admin@bgevolution.com
DocumentRoot /home/user/bgevolution/
CBandSpeed 5000kb/s 24 16
CBandRemoteSpeed 2500 12 8
</VirtualHost>
The CbandSpeed parameter established a maximum bandwidth limit on the entire VirtualHost. The 24 refers to the maximum requests per second, and the 16 refers to the maximum sustained connections at any one time. The CbandRemoteSpeed parameter establish bandwidth throttling for any one specific website visitor. With this parameter you can limit each visitor specifically. Play around with the numbers, try and download something, and you will see in real time the effect your configuration has on the actual download speed.
