Bandwidth Shaping requests coming from a web server
Hi.
I would like to write a apache module which limits the speed we send out the response based on some internal algorithm (like a cookie, or a line in the request header, or some random number ;-)).
Ideally I would like a method to tell the kernel
use queue 'XYZ' for this socket I just opened, and then just use the normal sendfile/write requests to send it out
Is this possible?
also .. any tips on how to this on a BSD box?
Thanks in advance
Ian Holsman
Quoted 5 lines · Ian Holsman
Hi.
I would like to write a apache module which limits the speed we send out the response based on some internal algorithm (like a cookie, or a line in the request header, or some random number ;-)).
I don't know if Apache can do this sort of thing itself, but Squid certainly
can (the phrase it uses for that is "delay pools"). Since you want to do
this for a server whcih you run, rather than your clients accessing external servers, you want Squid in Accelerator Mode rather than Proxying Mode.
See http://www.squid-cache.org for more info.
Quoted 1 line
also .. any tips on how to this on a BSD box?
You can certainly run Squid under BSD (and you certainly can't run netfilter under BSD).
Regards,
Antony.
Signature · 6 lines
There's no such thing as bad weather - only the wrong clothes.
- Billy Connolly
Please reply to the list;
please don't CC me.yes.. fowarding it via squid is an option. I was hoping to use netfilters queues and features. similiar to what netnice.org can do on freebsd
Quoted 34 lines · Antony Stone
Quoted 5 lines · Ian Holsman
Hi.
I would like to write a apache module which limits the speed we send out the response based on some internal algorithm (like a cookie, or a line in the request header, or some random number ;-)).
I don't know if Apache can do this sort of thing itself, but Squid certainly
can (the phrase it uses for that is "delay pools"). Since you want to do
this for a server whcih you run, rather than your clients accessing external servers, you want Squid in Accelerator Mode rather than Proxying Mode.See http://www.squid-cache.org for more info.
Quoted 1 line
also .. any tips on how to this on a BSD box?
You can certainly run Squid under BSD (and you certainly can't run netfilter under BSD).
Regards,
Antony.
--
There's no such thing as bad weather - only the wrong clothes.- Billy Connolly
Please reply to the list;
please don't CC me.