I am trying to set up flow classification on an L3 interace.
Commands used:
classify table mask l3 ip4 dst buckets 2
classify session hit-next 0 table-index 0 match l3 ip4 dst 3.0.0.0
set flow classify interface FortyGigabitEthernet8/0/0 ip4-table 0
I can see that the feature is enabled on the interface using show interface
features.
I send a packet to dip 3.0.0.0
Packet trace shows the classification is indeed performed:
------------------- Start of thread 1 vpp_wk_0 -------------------
Packet 1
00:37:15:796517: dpdk-input
FortyGigabitEthernet8/0/0 rx queue 0
buffer 0x100c0f7: current data 14, length 46, free-list 0, clone-count 0,
totlen-nifb 0, trace 0x0
PKT MBUF: port 0, nb_segs 1, pkt_len 60
buf_len 2176, data_len 60, ol_flags 0x0, data_off 128, phys_addr 0x236ffcc0
packet_type 0x0
IP4: 7c:fe:90:20:e6:74 -> ec:0d:9a:3d:70:7a
TCP: 16.0.0.1 -> 3.0.0.0
tos 0x00, ttl 127, length 46, checksum 0x23f8
fragment id 0x04d2
00:37:15:796545: ip4-input
TCP: 16.0.0.1 -> 3.0.0.0
tos 0x00, ttl 127, length 46, checksum 0x23f8
fragment id 0x04d2
00:37:15:796559: ip4-flow-classify
FLOW_CLASSIFY: sw_if_index 1 next 1 table 0 offset 192
00:37:15:796569: ip4-lookup
fib 0 dpo-idx 18 flow hash: 0x00000000
TCP: 16.0.0.1 -> 3.0.0.0
tos 0x00, ttl 127, length 46, checksum 0x23f8
fragment id 0x04d2
00:37:15:796582: ip4-load-balance
fib 0 dpo-idx 18 flow hash: 0x00000000
TCP: 16.0.0.1 -> 3.0.0.0
tos 0x00, ttl 127, length 46, checksum 0x23f8
fragment id 0x04d2
00:37:15:796586: ip4-rewrite
tx_sw_if_index 2 dpo-idx 3 : ipv4 via 2.2.2.5 FortyGigabitEthernet8/0/1:
248a07a1fc6dec0d9a3d707b0800 flow hash:
00000000: 248a07a1fc6dec0d9a3d707b08004500002e04d200007e0624f8100000010300
00000020: 0000040104010001f7fa0000000052c00400b3e3000000aa00000000
00:37:15:796595: FortyGigabitEthernet8/0/1-output
FortyGigabitEthernet8/0/1
IP4: ec:0d:9a:3d:70:7b -> 24:8a:07:a1:fc:6d
TCP: 16.0.0.1 -> 3.0.0.0
tos 0x00, ttl 126, length 46, checksum 0x24f8
fragment id 0x04d2
00:37:15:796603: FortyGigabitEthernet8/0/1-tx
FortyGigabitEthernet8/0/1 tx queue 1
buffer 0x100c0f7: current data 0, length 60, free-list 0, clone-count 0,
totlen-nifb 0, trace 0x0
IP4: ec:0d:9a:3d:70:7b -> 24:8a:07:a1:fc:6d
TCP: 16.0.0.1 -> 3.0.0.0
tos 0x00, ttl 126, length 46, checksum 0x24f8
fragment id 0x04d2
I was expecting the hit-next 0 to indicate that the next node on a hit is node
0 which according to the show vlib graph is ip4 drop.
However, the packet continues to the lookup....
How do I know if the session was hit correctly? Does offset 192 indicate a hit?
How is the hit-next interpreted? Is this indeed according to the next-node
indices of the ip4-flow-classify graph node?
Thanks,
Eyal
_______________________________________________
vpp-dev mailing list
[email protected]
https://lists.fd.io/mailman/listinfo/vpp-dev