optional TLVs are empty even with "enableTx=on"
dusane opened this issue · 4 comments
lldpad v 1.1.0
If I use following :
lldptool set-lldp -i $lldp_intf adminStatus=rxtx
lldptool -T -i $lldp_intf -V sysName enableTx=yes
lldptool -T -i $lldp_intf -V portDesc enableTx=yes
lldptool -T -i $lldp_intf -V sysDesc enableTx=yes
lldptool -T -i $lldp_intf -V sysCap enableTx=yes
lldptool -T -i $lldp_intf -V mngAddr enableTx=yes
I don't get following optional TLVs for interface $lldp_intf
"System Name TLV, System Description TLV, System Capabilities TLV"
The only change that helps getting these optional TLVs is to using "enableTx=no" for mngAddr.
( If I set it "enableTx=no" for any other TLV its not helping ).
Shouldnt "enableTx =yes" enable the specific TLV ?
Has anyone seen this ? Is this a known issue ?
The workaround for this issue is to use "lldptool -T -i $lldp_intf -V mngAddr enableTx=no"
What do the debug logs say?
EDIT:
Whoops, hit the enter too soon. I am surprised that disabling mngAddr TLV would allow this to print. That tells me something isn't returning correctly from the basman_get_manaddr_sub(...) for ipv4, ipv6, and 802 information. Can you tell what kind of device you're using?
Hrrm... can you try with the following patch?
diff --git a/lldp_basman.c b/lldp_basman.c
index 25e7d9e..cb0c50c 100644
--- a/lldp_basman.c
+++ b/lldp_basman.c
@@ -515,7 +515,7 @@ static int basman_bld_manaddr_tlv(struct basman_data *bd,
if (rc) {
rc = basman_get_manaddr_sub(bd, agent, MANADDR_IPV6);
if (rc)
- basman_get_manaddr_sub(bd, agent, MANADDR_ALL802);
+ rc = basman_get_manaddr_sub(bd, agent, MANADDR_ALL802);
}
out_err:
return rc;
This could be the issue.
The patch works ! Thanks