Ticket: CM-12302
Reviewed By: Daniel, Roopa, Nikhil G
Testing Done: ifupdown2 smoke test
With this pretty straight forward, we introduce a new Attribute in nlmanager,
so that we have single check and no code redundancy for ifname length. This
also prevent loosing time sending a netlink packet for an known error.
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
Ticket: None
Reviewed By: Roopa, Nikhil G, Daniel
Testing Done: ifupdown2 smokes
The message logged and the exception raised by nlmanager, when receiving
an NLMSG_ERROR packet from the kernel, wasn't super explicit plus if the
error wasn't a netlink related failure we didn't provide any information
Now we use strerror with the provided error code to generate a nice msg.
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
Ticket: None
Reviewed By: Roopa, Nikhil G, Daniel
Testing Done: ifupdown2 smoke
We used to have these checks in the old rtnetlink python library.
They were missing in python-nlmanager this was a big regression for
ifupdown2.
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
Ticket: CM-11735
Reviewed By: Roopa, Daniel
Testing Done: creating a vxlan with ifupdown then checking the dstport with
ip -d link show $vlxanName
When creating a vxlan nlmanager didn't re-order/byte swap the dstport value
to little endian
46354 instead of 4789
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
+ adding one byte attribute class for protodown operations.
Ticket: CM-11581
Reviewed By: CCR-4721
Testing Done: Smoke + custom interface file with clag bond that requires protodown.
- nlmanager will now throw an exception if a user is trying to use the default
attribute class when in fact he should use a more specific attribute class.
- The protodown implementation needed to use a one byte attribute to set the protodown state
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
Ticket: CM-7360
Reviewed By: CCR-4721
Testing Done: smoke / testifreload / Tested on amd64 platform (by Sam)
For now, we use a mirror copy of nlmanager sources to make sure we don't
depend on it as an external package
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>