Squid delay pools delay_parameters bandwidth

bandwidthsquid

I can not understand the documentation about delay_parameters params in squid.

delay_pools 1
delay_class 1 4 
delay_parameters 1 -1/-1 -1/-1 -1/-1 600/8000

What is the difference between the first and second bandwidth (600 / 8000)? Why and when should I set diffent values?

Thanks

Best Answer

Numerators and denominators in the squid pool config have different meaning:

  • Numerator is the volume of the flow buffer (bucket) in bytes
  • Denominator is the max allowed flow rate in bytes per second

Think about the pool as a tank with two pipes. One pipe fills the tank while other drains it. Throughput of drain pipe defined by denominator. Numerator is the volume of the tank. When tank is big enough the drain can be flawless while income can be chaotic - because of other users activity.

Bigger numerator makes downstream smoother but laggy. Smaller numerator makes traffic shaping more accurate but downstream becomes wiggly.

Years ago I've used values like 65536/16000 but now I'm sure delay pools are not an appropriate tool for shaping at all. You have to use some packet queuing tools like ALTQ or, in my case, that was the IPFW/DUMMYNET from the FreeBSD. When I've introduced the packet queuing shaper all users have said "Wow!".