1

I am creating the ryu app to push and pop mpls labels. Here is the flow entries at ovs (version 2.3.1) switch s1:

root@ubuntu:~# sudo ovs-ofctl -O  OpenFlow14 dump-flows s1
OFPST_FLOW reply (OF1.4) (xid=0x2):
 cookie=0x0, duration=190.991s, table=0, n_packets=123, n_bytes=21852, priority=0 actions=CONTROLLER:65535
 cookie=0x0, duration=190.991s, table=0, n_packets=0, n_bytes=0, priority=10,mpls,in_port=2,mpls_label=80 actions=pop_mpls:0x0800,output:1
 cookie=0x0, duration=190.991s, table=0, n_packets=152, n_bytes=14896, priority=10,ip,in_port=1 actions=push_mpls:0x8847,set_field:80->mpls_label,output:2

Anyone knows why Packets are not forwarded even the flow entry is matched. cause if i open the wireshark and see s1-eth2 to check for mpls headers then no packet with mpls header or ethertype = 0x8847 is detected.

Only packets i see at s1-eth2 are ICMPv6(router solicitation message) ,DHCP and MDNS. any of them aren't related to ping i am sending from host 1 to h2. My topology : h1-s1-s2-h2

Do my code has bugs or it is the bug in ovs or openflow_v1.4 ryu?

Thanks.

Soner Gönül
  • 97,193
  • 102
  • 206
  • 364
Vishlesh Patel
  • 168
  • 1
  • 1
  • 12
  • 1
    When you sniff s1-eth1 (or wherever h1 is connecting to s1), are there packets coming in with mpls label 80? You can also see what flows are being triggered using `ovs-dpctl-top` – nik May 05 '15 at 22:37
  • yes, h1 connected to s1 as h1-s1-s2-h2. h1 sends ping message to s1 eth1. I programmed s1 to tag mpls label and send it to eth2, but No packets are coming out from s1-eth2 with mpls label 80. I will give `ovs-dpctl-top` a try – Vishlesh Patel May 06 '15 at 23:19
  • 1
    Could you post your code? – Ehsan Ab Jul 08 '15 at 17:20

3 Answers3

0

There were few MPLS fixed pushed in branch 2.4, Can you try it on master or branch 2.4?

Abhishek
  • 275
  • 7
  • 18
0

Do you process the ARP requests and ARP replys?

Two ways to process the ARP packets:

  1. keep your flow tables unchanged, the ARP packets are forwarded to the controller. Let the controller processes the ARP.
  2. change the flow table.

add the last one

root@ubuntu:~# sudo ovs-ofctl -O  OpenFlow14 dump-flows s1
OFPST_FLOW reply (OF1.4) (xid=0x2):
cookie=0x0, duration=190.991s, table=0, n_packets=123, n_bytes=21852, priority=0 actions=CONTROLLER:65535
cookie=0x0, duration=190.991s, table=0, n_packets=0, n_bytes=0, priority=10,mpls,in_port=2,mpls_label=80 actions=pop_mpls:0x0800,output:1
cookie=0x0, duration=190.991s, table=0, n_packets=152, n_bytes=14896, priority=10,ip,in_port=1 actions=push_mpls:0x8847,set_field:80->mpls_label,output:2
cookie=0x0, duration=190.991s, table=0, n_packets=152, n_bytes=14896, priority=10,arp,in_port=1 actions=push_mpls:0x8847,set_field:80->mpls_label,output:2
emj306
  • 1
  • 2
0

Works for upto 2 labels in the stack in OvS 2.5.1. Perhaps error is in Ryu app. Can you post the code?

MPLS header stacks are limited to size 3. Pushing more than 3 MPLS headers on a packet results in the packet not being forwarded in Open vSwitch.

sudo mn --topo single,2 --switch ovsk
mininet> h1 ping h2

Installed a minimal set of flow entries on s1:

sudo ovs-ofctl -O OpenFlow13 add-flow s1 in_port=1,actions=push_mpls:0x8847,push_mpls:0x8847,push_mpls:0x8847,push_mpls:0x8847,output:2
sudo ovs-ofctl -O OpenFlow13 add-flow s1 in_port=2,actions=push_mpls:0x8847,push_mpls:0x8847,push_mpls:0x8847,push_mpls:0x8847,output:1

Flow entries are correctly matched. sudo ovs-ofctl -O OpenFlow13 dump-flows s1 | grep -o "n_packets=\w*" Yet no packets leave s1 confirmed by sudo tcpdump -ni s1-eth2

sinhayash
  • 2,693
  • 4
  • 19
  • 51