Date: Wed, 6 Jul 2011 11:25:06 -0400 From: Calomel Org <infallibilismindefeasibility@calomel.org> To: freebsd-pf@freebsd.org, misc@openbsd.org Subject: pf ALTQ bandwidth limited to a 32bit value (4294Mb) Message-ID: <20110706152506.GA26334@calomel.org>
next in thread | raw e-mail | index | archive | help
ALTQ using hfsc is limited to a maximum parent bandwidth of 4294Mb. This value is 2^32 or 4,294,967,296 bits. If you set the bandwidth any higher, altq will flip back to zero. This "bug" was found when trying to test 10 gigabit and 40 gigabit bandwidth models. These tests were done on OpenBSD 32bit and 64bit as well as FreeBSD 32bit and 64bit. If anyone else can verify this independently and agree with the results I would be happy to register it as a bug. How to replicate: A quick test is setting the bandwidth to 4294Mb and doing a pfctl -sq to check altq. altq on $ExtIf bandwidth 4294Mb hfsc queue { ack, web} queue root_em0 on em0 bandwidth 4.29Gb priority 0 {ack, web} Now set the bandwidth to 4295Mb and notice altq has flip to zero and add the 32.70Kb difference. altq on $ExtIf bandwidth 4295Mb hfsc queue { ack, web } queue root_em0 on em0 bandwidth 32.70Kb priority 0 {ack, web} Again, we can set the bandwidth to a multiple of two(2) to 8589Mb. The bandwidth value flips to zero once and the result is 4.29Gb. altq on $ExtIf bandwidth 8589Mb hfsc queue { ack, web} queue root_em0 on em0 bandwidth 4.29Gb priority 0 {ack, web} If we add one more megabit to 8590Mb the value flips twice and we are left with 65.41Kb. altq on $ExtIf bandwidth 8590Mb hfsc queue { ack, web} queue root_em0 on em0 bandwidth 65.41Kb priority 0 {ack, web} Thanks. -- Calomel @ https://calomel.org Open Source Research and Reference
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110706152506.GA26334>