[CONTROLLER-133] Problem removing flows Created: 23/Jan/14  Updated: 25/Jul/23  Resolved: 05/May/15

Status: Resolved
Project: controller
Component/s: adsal
Affects Version/s: None
Fix Version/s: None

Type: Bug
Reporter: Heikki Mahkonen Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: Windows
Platform: PC


External issue ID: 355

 Description   

This is how I tested:
1. Run ODL
2. Run Mininet: sudo mn --topo single,3 --controller
'remote,ip=192.168.56.1' --switch ovsk,protocols=OpenFlow13
3. Add flows

osgi> addMDFlow openflow:1 f4

ovs> sudo ovs-ofctl -OOpenFLow13 dump-flows s1
OFPST_FLOW reply (OF1.3) (xid=0x2):
cookie=0xa, duration=10.071s, table=2, n_packets=0, n_bytes=0,
send_flow_rem
priority=2,ip,dl_src=00:00:00:00:00:00/ff:ff:ff:00:00:00,dl_dst=ff:ff:00:00:
00:00/ff:ff:00:00:00:00 actions=drop

osgi> addMDFlow openflow:1 f5

ovs> sudo ovs-ofctl -OOpenFLow13 dump-flows s1
OFPST_FLOW reply (OF1.3) (xid=0x2):
cookie=0xa, duration=0.757s, table=2, n_packets=0, n_bytes=0, send_flow_rem
priority=2,ip,nw_dst=10.0.0.0/24 actions=drop
cookie=0xa, duration=37.356s, table=2, n_packets=0, n_bytes=0,
send_flow_rem
priority=2,ip,dl_src=00:00:00:00:00:00/ff:ff:ff:00:00:00,dl_dst=ff:ff:00:00:
00:00/ff:ff:00:00:00:00 actions=drop

Everything is OK! Then:

4. Remove flows
osgi> removeMDFlow openflow:1 f4
2014-01-23 11:05:20.198 PST [md-sal-binding-notification-2] ERROR
o.o.c.sal.binding.impl.NotifyTask - Unhandled exception thrown by listener:
org.opendaylight.controller.sal.compatibility.FlowProgrammerAdapter$$Broker$
ListenerInvoker@5c7bf2e2
java.lang.NullPointerException: null
at
org.opendaylight.controller.sal.compatibility.NodeMapping.toADNode(NodeMappi
ng.java:274) ~[na:na]
at
org.opendaylight.controller.sal.compatibility.FlowProgrammerAdapter.onFlowRe
moved(FlowProgrammerAdapter.java:201) ~[na:na]
at
org.opendaylight.controller.sal.compatibility.FlowProgrammerAdapter$$Broker$
ListenerInvoker.onNotification(FlowProgrammerAdapter$$Broker$ListenerInvoker
.java) ~[na:na]
at
org.opendaylight.controller.sal.binding.impl.NotifyTask.call(NotifyTask.java
:59) ~[na:na]
at
java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
~[na:1.7.0_25]
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
~[na:1.7.0_25]
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:11
45) ~[na:1.7.0_25]
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:6
15) ~[na:1.7.0_25]
at java.lang.Thread.run(Thread.java:724) ~[na:1.7.0_25]
Status of Flow Data Loaded Transaction: COMMITED

ovs> sudo ovs-ofctl -OOpenFLow13 dump-flows s1
OFPST_FLOW reply (OF1.3) (xid=0x2):
cookie=0xa, duration=79.276s, table=2, n_packets=0, n_bytes=0,
send_flow_rem priority=2,ip,nw_dst=10.0.0.0/24 actions=drop

osgi> removeMDFlow openflow:1 f5
osgi> Status of Flow Data Loaded Transaction: COMMITED

Flow still in switch.

sudo ovs-ofctl -OOpenFLow13 dump-flows s1:
OFPST_FLOW reply (OF1.3) (xid=0x2):
cookie=0xa, duration=138.365s, table=2, n_packets=0, n_bytes=0,
send_flow_rem priority=2,ip,nw_dst=10.0.0.0/24 actions=drop



 Comments   
Comment by sunny malhotra [ 29/Jan/14 ]

I tried to reproduce the problem scenario.
Bug Seems to be resolved.

Please verify the steps followed :

1.Run ODL
2.2. Run Mininet: sudo mn --topo single,3 --controller
'remote,ip=192.168.56.1' --switch ovsk,protocols=OpenFlow13
3. Add flows

osgi> addMDFlow openflow:1 f4

sudo ovs-ofctl -protocols=OpenFLow13 dump-flows s1
NXST_FLOW reply (xid=0x4):
cookie=0xa, duration=11.991s, table=0, n_packets=0, n_bytes=0, priority=2,ip,dl_src=00:00:00:00:23:ae,dl_dst=ff:ff:ff:ff:ff:ff actions=drop

osgi> addMDFlow openflow:1 f5

sudo ovs-ofctl -protocols=OpenFLow13 dump-flows s1
NXST_FLOW reply (xid=0x4):
cookie=0xa, duration=96.518s, table=0, n_packets=0, n_bytes=0, priority=2,ip,dl_src=00:00:00:00:23:ae,dl_dst=ff:ff:ff:ff:ff:ff actions=drop
cookie=0xa, duration=5.613s, table=0, n_packets=0, n_bytes=0, priority=2,ip,nw_dst=10.0.0.0/24 actions=drop

4. Remove flows :

osgi> removeMDFlow openflow:1 f4
osgi> Status of Flow Data Loaded Transaction: COMMITED
sudo ovs-ofctl -protocols=OpenFLow13 dump-flows s1
cookie=0xa, duration=121.496s, table=0, n_packets=0, n_bytes=0, priority=2,ip,nw_dst=10.0.0.0/24 actions=drop

osgi> removeMDFlow openflow:1 f5
osgi> Status of Flow Data Loaded Transaction: COMMITED
sudo ovs-ofctl -protocols=OpenFLow13 dump-flows s1
NXST_FLOW reply (xid=0x4):

Comment by Heikki Mahkonen [ 29/Jan/14 ]

This was fixed in openflowplugin/test-provider/src/main/java/org/opendaylight/openflowplugin/test/OpenflowpluginTestCommandProvider.java. Deleting flow from FRM now works.

Comment by Carol Sanders [ 05/May/15 ]

This bug is part of the project to Move all ADSAL associated component bugs to ADSAL.

Generated at Wed Feb 07 19:52:16 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.