Hoi,
I've found a few issues with the loadbalancer plugin - notably in the
binary API. See https://gerrit.fd.io/r/c/vpp/+/45428
1) When creating two VIPs using the following Python snippet::
api_reply = vpp.api.lb_add_del_vip(pfx="10.0.0.2/32", port=80)
print(api_reply)
api_reply = vpp.api.lb_add_del_vip(pfx="2001:db8::2/128", port=80)
print(api_reply)
api_reply = vpp.api.lb_vip_dump()
print(api_reply)
The API call returns an invalid VIP object:
lb_add_del_vip_reply(_0=340, context=3, retval=0)
lb_add_del_vip_reply(_0=340, context=4, retval=0)
[lb_vip_details(_0=348, context=5,
vip=vl_api_lb_vip_t(pfx=*IPv4Interface('0.0.0.0/32'),*
protocol=<vl_api_ip_proto_t.IP_API_PROTO_HOPOPT: 0>, port=80),
encap=<vl_api_lb_encap_type_t.LB_API_ENCAP_TYPE_GRE6: 1>,
dscp=<vl_api_ip_dscp_t.IP_API_DSCP_CS0: 0>,
srv_type=<vl_api_lb_srv_type_t.LB_API_SRV_TYPE_CLUSTERIP: 0>,
target_port=0, flow_table_length=0), lb_vip_details(_0=348, context=5,
vip=vl_api_lb_vip_t(pfx=IPv6Interface('2001:db8::2/128'),
protocol=<vl_api_ip_proto_t.IP_API_PROTO_HOPOPT: 0>, port=80),
encap=<vl_api_lb_encap_type_t.LB_API_ENCAP_TYPE_GRE6: 1>,
dscp=<vl_api_ip_dscp_t.IP_API_DSCP_CS0: 0>,
srv_type=<vl_api_lb_srv_type_t.LB_API_SRV_TYPE_CLUSTERIP: 0>,
target_port=0, flow_table_length=0)]
2) When creating a VIP on the CLI with a specific encap, the
lb_vip_dump() returns the raw value of htonl(vip->type) even though
there is an API enum lb_encap_type.
3) When deleting an AS or VIP, the garbage collector only runs on
subsequent CLI input, so cleanups will never occur when using only the
binary API
4) You can set LB global config (like ip4-src-address and
ip6-src-address) via lb_conf() API, but there is no lb_conf_get() API.
5) CLI 'show lb vips' without 'verbose' returns nothing due to a parsing
error.
Please take a look.
groet,
Pim
--
Pim van Pelt<[email protected]>
PBVP1-RIPEhttps://ipng.ch/
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#26935): https://lists.fd.io/g/vpp-dev/message/26935
Mute This Topic: https://lists.fd.io/mt/118704457/21656
Group Owner: [email protected]
Unsubscribe: https://lists.fd.io/g/vpp-dev/leave/14379924/21656/631435203/xyzzy
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-