[bug?] bug in the htb netlink messages ?
Fabrice HOBAYA
fabrice.hobaya at toulouse.viveris.com
Tue Feb 21 05:12:32 EST 2012
Hi all,
I'm using the libnl 3.2.3 for rtnl_htb functions, here is my problem:
When I set the rate (and ceil) of a branch of the htb
(rtnl_htb_set_rate(...) and rtnl_htb_set_ceil), the real observed rate
is 16 times bigger whereas the get functions (rtnl_htb_get_rate(...) and
rtnl_htb_get_ceil(...)) and the nl_object_dump function (result at the
end of the mail) return the right set rate and ceil.
For example when I set rate and ceil to 15kbits/sec, the observed rate
is 240kbits/sec (the parent has the same settings).
When I tried to debug with NLCB=debug, the request message for the
setting of the htb is well acknowledged (error message with code 0) but
seems to have a wrong total length (see below). The second attribute
[ATTR 02] of the request is not readable without a documentation, so I
can not continue debugging without help.
For information I've used a tc script (on the same system), and
everything has worked normally.
Could someone gives me any idea on that ? Thanks in advance.
Best Regards,
Fabrice.
-- Debug: Sent Message:
-------------------------- BEGIN NETLINK MESSAGE
---------------------------
[HEADER] 16 octets
.nlmsg_len = 2152 (*instead of 16+20+4+2104 = 2144 ???*)
.nlmsg_type = 40 <route/class::new>
.nlmsg_flags = 1029 <REQUEST,ACK,ATOMIC>
.nlmsg_seq = 1329809071
.nlmsg_pid = 5947
[PAYLOAD] 20 octets
00 00 00 00 09 00 00 00 01 00 01 00 00 00 01 00 00 00
..................
00 00 ..
[ATTR 01] 4 octets
68 74 62 00 htb.
[ATTR 02] 2104 octets
30 00 01 [...]
--------------------------- END NETLINK MESSAGE
---------------------------
-- Debug: Received Message:
-------------------------- BEGIN NETLINK MESSAGE
---------------------------
[HEADER] 16 octets
.nlmsg_len = 36
.nlmsg_type = 2 <ERROR>
.nlmsg_flags = 0 <>
.nlmsg_seq = 1329809071
.nlmsg_pid = 5947
[ERRORMSG] 20 octets
.error = 0 "Success"
[ORIGINAL MESSAGE] 16 octets
.nlmsg_len = 16
.nlmsg_type = 40 <0x28>
.nlmsg_flags = 1029 <REQUEST,ACK,ATOMIC>
.nlmsg_seq = 1329809071
.nlmsg_pid = 5947
--------------------------- END NETLINK MESSAGE
---------------------------
*
nl_dump_object(...) =>* class htb dev (null) id 1:2 parent 1:1 rate
1.83KiB/s (15Kbit) log 2147483648 ceil 1.83KiB/s (15Kbit) log 2147483648
prio 0
--
Fabrice HOBAYA
PhD - Ingénieur d'études Viveris Technologies
1 Avenue de l'Europe - Parc technologique du Canal -
Bat C - 1er étage - 31400 Toulouse - France
fabrice.hobaya at toulouse.viveris.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.infradead.org/pipermail/libnl/attachments/20120221/154b6a2f/attachment.html>
More information about the libnl
mailing list