Hi Marek, I don’t see anything wrong with the construction of the request.
Can you please show me the HC logs of the message sent and also sh ip fib index 2 10.10.2.3/32 detail this API is used a lot in the unit-tests so I have some confidence that works under normal circumstances regards, neale From: "Marek Gradzki -X (mgradzki - PANTHEON TECHNOLOGIES at Cisco)" <mgrad...@cisco.com> Date: Friday, 18 August 2017 at 06:00 To: Andrej Mak <andrej....@pantheon.tech>, "vpp-dev@lists.fd.io" <vpp-dev@lists.fd.io> Cc: "Neale Ranns (nranns)" <nra...@cisco.com> Subject: RE: Set up MPLS via jvpp Hi, So I was wrong. I haven’t noticed next_hop_n_out_labels is u8… Neal: any idea why labels are not added? Regards, Marek From: Marek Gradzki -X (mgradzki - PANTHEON TECHNOLOGIES at Cisco) Sent: 17 sierpnia 2017 12:17 To: 'Andrej Mak' <andrej....@pantheon.tech>; vpp-dev@lists.fd.io Cc: Neale Ranns (nranns) <nra...@cisco.com> Subject: RE: Set up MPLS via jvpp Hi, I think it is a bug in the C handler of the ip_add_del_route message. Byte order for next_hop_n_out_labels is not flipped. Please check if this fixes the issue: https://gerrit.fd.io/r/#/c/8080/ Regards, Marek From: vpp-dev-boun...@lists.fd.io<mailto:vpp-dev-boun...@lists.fd.io> [mailto:vpp-dev-boun...@lists.fd.io] On Behalf Of Andrej Mak Sent: 17 sierpnia 2017 11:03 To: vpp-dev@lists.fd.io<mailto:vpp-dev@lists.fd.io> Subject: [vpp-dev] Set up MPLS via jvpp Hi all, I would like to set mpls via java api, but I have some problems with it. I want to do java calls equal to this ip route add 10.10.2.3/32 table 1 via 10.10.1.2 host-veth out-label 1003 which creates this entry in show ip fib index 1 10.10.2.3/32 unicast-ip4-chain [@0]: dpo-load-balance: [proto:ip4 index:27 buckets:1 uRPF:19 to:[0:0]] [0] [@10]: mpls-label:[1]:[1003:255:0:eos] [@1]: arp-mpls: via 10.10.1.2 host-veth11 so I create DTO, which sets fields matching parameters in CLI command: IpAddDelRoute addRoute = new IpAddDelRoute(); addRoute.isAdd = 1; addRoute.tableId = 2; final Ipv4Prefix prefix = new Ipv4Prefix((„10.10.2.3/32“); addRoute.dstAddress = Ipv4Translator.INSTANCE.ipv4AddressPrefixToArray(prefix); addRoute.dstAddressLength = Ipv4Translator.INSTANCE.extractPrefix(prefix); addRoute.nextHopAddress = Ipv4Translator.INSTANCE.ipv4AddressNoZoneToArray(„10.10.1.2“); addRoute.nextHopSwIfIndex = 1; int[] labels = new int[1]; labels[0] = 1003; addRoute.nextHopNOutLabels = (byte) labels.length; addRoute.nextHopOutLabelStack = labels; api.ipAddDelRoute(addRoute).toCompletableFuture().get() but show ip fib index 2 shows different result 10.10.2.3/32 unicast-ip4-chain [@0]: dpo-load-balance: [proto:ip4 index:44 buckets:1 uRPF:44 to:[0:0]] [0] [@3]: arp-ipv4: via 10.10.1.2 host-veth11 Is it a bug, or am I doing something wrong? Another question I’d like to ask is whether is it possible to create MPLS local-label via jvpp. I could’t find local label API in mpls.api file. Thanks Andrej Andrej Mak Software Developer PANTHEON technologies s.r.o. Janka Kráľa 9, 974 01 Banská Bystrica Slovakia Tel / +421 220 665 111 MAIL / andrej....@pantheon.tech<mailto:andrej....@pantheon.tech> WEB / https://pantheon.tech
_______________________________________________ vpp-dev mailing list vpp-dev@lists.fd.io https://lists.fd.io/mailman/listinfo/vpp-dev