Search This Blog

Bookmark and Share

Friday, October 23, 2009

Delay pools are stupid

Delay pools are stupid; why can't I download something at full speed when the network is used only by me?

Unfortunately, you can't do much about it.

The only thing you can do is to use cron and reconfigure it, for example, at 1.00 am, so that Squid won't use delay pools, then reconfigure it again, let's say at 7.30 am, to use delay pools.

To do this, create two separate config files, called for example squid.conf-day and squid.conf-night, and put them into /opt/squid/etc/.

squid.conf-day would be the exact copy of a config we created earlier

squid.conf-night, on the contrary, would not have any delay pool lines, so all you have to do is to comment them out.

Next thing you have to do is to set up /etc/crontab entries correctly.

Edit /etc/crontab and put the following lines there:

#SQUID - night and day config change
01 9 * * * root /bin/cp -f /opt/squid/etc/squid.conf-day /opt/squid/etc/squid.conf; /opt/squid/bin/squid -k reconfigure
59 23 * * * root /bin/cp -f /opt/squid/etc/squid.conf-night /opt/squid/etc/squid.conf; /opt/squid/bin/squid -k reconfigure

Article Source http://www.faqs.org/docs/Linux-HOWTO/Bandwidth-Limiting-HOWTO.html

0 comments:

Post a Comment