Azmawee 127.0.0.1

"Mauiwagen. Das Server." – pub 4096R/712DAA69

Squid delay pool (bandwidth limit)

This is a sample of ACL config for using squid to limit a bandwidth of downloaded files and videos, such as youtube. The config are pretty much self-explain, if you have any question, please toss it in the comment section for discussion.

# — Squid delay pool config start —
# Define boss IP for unlimited bandwidth
acl boss src 192.168.1.245/32
# Caching youtube domain
acl youtube dstdomain -i .youtube.com
# Define file extension for download limit
acl big-file url_regex -i ftp .exe .flv .mp3 .mp4 .mkv .3gp .avi .mpeg .mpe .mpg .iso .mov .zip .rar
cache allow youtube
cache allow big-file
# create 2 set of delay pools
delay_pools 2
# First pool class 2, for boss pc with unlimited bandwidth, no limit
delay_class 1 2
delay_parameters 1 -1/-1 -1/-1
delay_access 1 allow bos
# Second pool, for others that will have downloaded limits
delay_class 2 2
# — notes. –
# limit 29kbps (29000 bps), 29000/150000 = whole network, 29000/120000 = single IP
# “29000/150000″ means, after a downloaded files exceed 150000 bytes,
# they will continue to download at 29000 bytes/s.
delay_parameters 2 29000/150000 29000/120000
delay_access 2 allow big-file
# — Squid delay pool config end —

, , , , , , , , , , ,

4 Responses to “Squid delay pool (bandwidth limit)”

  • joselito says:

    Hi blogger will this delay pool work on psfense squid by adding it on custom option of the squid?
    And will it throttle the youtube downloader (YTD) software? TIA

       0 likes

  • joselito says:

    hi blogger anyway i did test it in pfsense+squid it works and it even limit the YTD software, but the problem is that the youtube site is limited too. how to exclude the youtube site?

       0 likes

  • says:

    Hi, yes, it should be working in pfsense as well. I think you will have to create additional acl’s to exclude the youtube website. Put the new acl list of youtube servers ip, and add it into the first pool class 2, same like as the bos pc.

       0 likes

  • Aloun says:

    Hi, I just want to limit general bandwidth not for the specific file. How can I configure Squid delay pool?

       0 likes

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Azmawee 127.0.0.1
MaUi^ - pub 4096R/712DAA69
Fingerprint 8BF7 D0AF CA45 5313 A3BF ACFB B90B 66C7 712D AA69
Website Security Test
0110010101100001011100110111010001100101011100100010000001100101011001110110011100100000011011100110111100101110001000000011000000110110