Re: [openflowplugin-dev] flow removal
On Tue, Oct 22, 2019 at 5:12 PM Asnake Ayele M. wrote: > > hello there, i am implementing reactive/proactve flow programming, hybrid > mode , and how to delete proactive flows from switch periodically based on > package counter or usage counter using internal services. > best regards, any hint appreciated. > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > > View/Reply Online (#8760): > https://lists.opendaylight.org/g/openflowplugin-dev/message/8760 > Mute This Topic: https://lists.opendaylight.org/mt/36449769/1964675 > Group Owner: openflowplugin-dev+ow...@lists.opendaylight.org > Unsubscribe: https://lists.opendaylight.org/g/openflowplugin-dev/unsub > [mra...@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- I have some code that I wrote for an earlier version of ODL (Nitrogen). That does all of the above but you'll have to sift through it to find the appropriate pieces. If you are looking for textbook style code snippets, they are going to be hard to find. Hope this helps: https://github.com/usnistgov/nist-mud/tree/master/sdnmud-aggregator/impl/src/main/java/gov/nist/antd/sdnmud/impl Ranga -- M. Ranganathan -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#8763): https://lists.opendaylight.org/g/openflowplugin-dev/message/8763 Mute This Topic: https://lists.opendaylight.org/mt/36449769/21656 Group Owner: openflowplugin-dev+ow...@lists.opendaylight.org Unsubscribe: https://lists.opendaylight.org/g/openflowplugin-dev/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [openflowplugin-dev] How to get flow stats from a java application?
I apologize for the volume of mails. I have the following when I list the features: feature:list | grep openflow odl-openflowplugin-app-forwardingrules-manager | 0.5.1 | | Started | odl-openflowplugin-app-forwardingrules-manager | OpenDaylight :: Openflow Plugin :: Application - odl-openflowplugin-nxm-extensions | 0.5.1 | | Started | odl-openflowplugin-nxm-extensions | OpenDaylight :: Openflow Plugin :: Nicira Extensi odl-openflowplugin-nsf-model| 0.5.1 | | Started | odl-openflowplugin-nsf-model | OpenDaylight :: OpenflowPlugin :: NSF :: Model odl-openflowplugin-app-config-pusher| 0.5.1 | | Started | odl-openflowplugin-app-config-pusher | OpenDaylight :: Openflow Plugin :: Application - odl-openflowplugin-southbound | 0.5.1 | | Started | openflowplugin-0.5.1 | OpenDaylight :: Openflow Plugin :: Li southbound odl-openflowjava-protocol | 0.5.1 | | Started | odl-openflowjava-0.5.1 | ODL :: openflowjava :: odl-openflowjava-protocol odl-openflowplugin-app-topology | 0.5.1 | | Started | odl-openflowplugin-app-topology | OpenDaylight :: Openflow Plugin :: Application - odl-openflowplugin-flow-services| 0.5.1 | | Started | odl-openflowplugin-flow-services | OpenDaylight :: Openflow Plugin :: Flow Services odl-openflowplugin-app-reconciliation-framework | 0.5.1 | | Started | odl-openflowplugin-app-reconciliation-framework | OpenDaylight :: Openflow Plugin :: Application - What am I missing? I looked around everywhere for clues but am quite stuck. Any help would be appreciated. Thank you in advance. Ranga On Mon, May 13, 2019 at 11:33 AM M. Ranganathan wrote: > Hello, > > I am trying to read flow statistics from a java opendaylight application > (run's as a karaf feature). I would appreciate some guidance on how to read > the flow statistics. I tried to install the opeflowplugin-services feature > as follows. > > > > org.opendaylight.openflowplugin > odl-openflowplugin-flow-services > xml > 0.5.1 > features > > > > My feature loads and runs. > > However the method > > > .getAggregateFlowStatisticsFromFlowTableForGivenMatch(flowStatsInputBuilder.build()) > .get().getResult(); > > Throws an exception : > > Error getting flow stats > java.util.concurrent.ExecutionException: > org.opendaylight.controller.md.sal.dom.api.DOMRpcImplementationNotAvailableException: > No implementation of RPC > AbsoluteSchemaPath{path=[(urn:opendaylight:flow:statistics?revision=2013-08-19)get-aggregate-flow-statistics-from-flow-table-for-given-match]} > available > at > com.google.common.util.concurrent.AbstractFuture.getDoneValue(AbstractFuture.java:503)[72:com.google.guava:22.0.0] > at > com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:462)[72:com.google.guava:22.0.0] > > > I am also seeing a lot of these exceptions : > > 019-05-13 11:03:58,390 | WARN | t-dispatcher-219 | > ConcurrentDOMDataBroker | 222 - > org.opendaylight.controller.sal-distributed-datastore - 1.6.1 | Tx: > DOM-1498 Error during phase CAN_COMMIT, starting Abort > TransactionCommitFailedException{message=Data did not pass validation., > errorList=[RpcError [message=Data did not pass validation., severity=ERROR, > errorType=APPLICATION, tag=operation-failed, applicationTag=null, > info=null, > cause=org.opendaylight.yangtools.yang.data.api.schema.tree.ModifiedNodeDoesNotExistException: > Node > /(urn:ietf:params:xml:ns:yang:ietf-interfaces?revision=2014-05-08)interfaces-state/interface > does not exist. Cannot apply modification to its children.]]} > at > org.opendaylight.controller.cluster.datastore.ShardDataTree.lambda$processNextPendingTransaction$0(ShardDataTree.java:740)[222:org.opendaylight.controller.sal-distributed-datastore:1.6.1] > at > org.opendaylight.controller.cluster.datastore.ShardDataTree.processNextPending(ShardDataTree.java:769)[222:org.opendaylight.controller.sal-distributed-datastore:1.6.1] > > I am stuck. Any help would be appreciated. Thank you. > > Ranga > > > > > -- > M. Ranganathan > > -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] How to get flow stats from a java application?
Hello, I am trying to read flow statistics from a java opendaylight application (run's as a karaf feature). I would appreciate some guidance on how to read the flow statistics. I tried to install the opeflowplugin-services feature as follows. org.opendaylight.openflowplugin odl-openflowplugin-flow-services xml 0.5.1 features My feature loads and runs. However the method .getAggregateFlowStatisticsFromFlowTableForGivenMatch(flowStatsInputBuilder.build()) .get().getResult(); Throws an exception : Error getting flow stats java.util.concurrent.ExecutionException: org.opendaylight.controller.md.sal.dom.api.DOMRpcImplementationNotAvailableException: No implementation of RPC AbsoluteSchemaPath{path=[(urn:opendaylight:flow:statistics?revision=2013-08-19)get-aggregate-flow-statistics-from-flow-table-for-given-match]} available at com.google.common.util.concurrent.AbstractFuture.getDoneValue(AbstractFuture.java:503)[72:com.google.guava:22.0.0] at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:462)[72:com.google.guava:22.0.0] I am also seeing a lot of these exceptions : 019-05-13 11:03:58,390 | WARN | t-dispatcher-219 | ConcurrentDOMDataBroker | 222 - org.opendaylight.controller.sal-distributed-datastore - 1.6.1 | Tx: DOM-1498 Error during phase CAN_COMMIT, starting Abort TransactionCommitFailedException{message=Data did not pass validation., errorList=[RpcError [message=Data did not pass validation., severity=ERROR, errorType=APPLICATION, tag=operation-failed, applicationTag=null, info=null, cause=org.opendaylight.yangtools.yang.data.api.schema.tree.ModifiedNodeDoesNotExistException: Node /(urn:ietf:params:xml:ns:yang:ietf-interfaces?revision=2014-05-08)interfaces-state/interface does not exist. Cannot apply modification to its children.]]} at org.opendaylight.controller.cluster.datastore.ShardDataTree.lambda$processNextPendingTransaction$0(ShardDataTree.java:740)[222:org.opendaylight.controller.sal-distributed-datastore:1.6.1] at org.opendaylight.controller.cluster.datastore.ShardDataTree.processNextPending(ShardDataTree.java:769)[222:org.opendaylight.controller.sal-distributed-datastore:1.6.1] I am stuck. Any help would be appreciated. Thank you. Ranga -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] Fwd: Listing all flows at a node from an openflow Java Application.
Hello, Starting from the nodeId of an openflow switch (e.g. openflow:1) I can list all the flows at that switch using the following: curl -v -u admin:admin http://127.0.0.1:8181/restconf/config/opendaylight-inventory:nodes/node/openflow:1 I want to do the same thing from my openflow application. I would like to avoid using HttpClient to do this. Is there a way to do this using an rpc service so I can get a reference to this service when starting my provider? i.e. I want to declare this in my blueprint.xml and call it. I can't figure out which service gives me this functionality. Any help would be appreciated. Thank you in advance. Regards, Ranga -- M. Ranganathan -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] No Packets seen at controller.
I ported my application to the latest version of openflow plugin southbound. I am using version 0.6.2. I see my flow rules appear at the switch. One of these flow rules requires packets to be sent to the controller. However, I am not seeing the packets at the controller (i.e. my application listener is not getting called). Is there any new configuration parameter I need to set so that the packets will be sent to the application ? Thank you, Ranga -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] Updated to 0.6.2 but nobody listening on port 6653 !
What is the difference between odl-baseapp ( part of my application ) which is started up on karaf startup and features-baseapp ( which is NOT started up on karaf startup) ? I notice that odl-baseapp and all its dependencies is running when I do karaf clean and list my features whereas features-baseapp is not installed. Then when I go to install features-baseapp, the problem with the port (described above happens). It seems to start fine but it freezes the openflow plugin because it has already been started. I *used* to feature:install features-baseapp when I was using Nitrogen but now it appears I must not install features-baseapp or there will be an issue with opeflow. Indeed, under nitrogen, I was seeing all the openflow bundles uninstalled and they would be installed and started when I start my feature but this has changed. So what is the difference between these two and am I doing something wrong? Is this a bug or expected behavior? If it is a bug then I'd like to bring it to the attention of somebody or file a report so please direct me there (If this is not openflow-dev relevant then please excuse the number of mails on this and let me know where I can post this). I am still learning about the system ( page faulting the gaps in my knowledge in -- a very painful process ) so please excuse the ignorance. Thank you for your help. On Sun, Aug 5, 2018 at 8:08 AM, M. Ranganathan wrote: > No evidence found in that file for openflow being started. I generate the > archetype version 1.5.2 and my karaf version is 4.1.5. > > I stripped the problem down to the essentials and I am able to reproduce > the problem as follows: > > > 1. Generate the archetype : > > > mvn archetype:generate -DarchetypeGroupId=org.opendaylight.controller > -DarchetypeArtifactId=opendaylight-startup-archetype > -DarchetypeRepository=https://nexus.opendaylight.org/content > /repositories/opendaylight.release/ -DarchetypeCatalog=remote > -DarchetypeVersion=1.5.2 > > 2. Edit the features/odl-baseapp/pom.xml and add just the following > dependency: > > > > > .. > >org.opendaylight.openflowplugin >odl-openflowplugin-southbound >xml >features >0.6.2 > > > > > After I build and start karaf ( *Note that I have not started my feature > yet* ) I see the following: > > > feature:list | grep openflow > > odl-openflowplugin-libraries │ 0.6.2│ │ > Started │ odl-openflowplugin-libraries │ OpenDaylight :: > Openflow Plugin :: Libraries > odl-openflowplugin-nsf-model │ 0.6.2│ │ > Started │ odl-openflowplugin-nsf-model │ OpenDaylight :: > OpenflowPlugin :: NSF :: Model > odl-openflowjava-protocol│ 0.6.2│ │ > Started │ odl-openflowjava-0.6.2 │ ODL :: openflowjava > :: odl-openflowjava-protocol > odl-openflowplugin-southbound│ 0.6.2│ │ > Started │ openflowplugin-0.6.2 │ OpenDaylight :: > Openflow Plugin :: Li southbound > > > I can netstat and see that 6653 is being used. > > Now I go to start my feature: > > > feature:install features-baseapp > > And I can no more see 6653 in my netstat. > > Note that I have added no code. This is just a skeleton. > > I wonder if I am editing the right file. Should I be adding the openflow > dependency to features/odl-baseapp/pom.xml or elsewhere? > > Is this a bug report that I should file ( under which component ? ) > > > Thanks a lot for your help. > > Regards, > > Ranga > > > > > > > > On Sat, Aug 4, 2018 at 11:30 PM, Luis Gomez wrote: > >> Not sure which distribution you are using but you can check >> etc/org.apache.karaf.features.cfg to see what is being installed when >> you start it. >> >> On Aug 4, 2018, at 7:06 PM, M. Ranganathan wrote: >> >> Still no luck. Here is my list of openflow features (after the change you >> suggested ): >> >> odl-openflowplugin-app-forwardingrules-manager │ 0.6.2 >> │ │ Started │ odl-openflowplugin-app-forwardingrules-manager >> │ OpenDaylight :: Openflow Plugin :: Application - >> odl-openflowplugin-libraries│ 0.6.2 >> │ │ Started │ odl-openflowplugin-libraries >> │ OpenDaylight :: Openflow Plugin :: Libraries >> odl-openflowplugin-app-config-pusher│ 0.6.2 >> │ │ Started │ odl-openflowplugin-app-config-pusher >> │ OpenDaylight :: Openflow Plugin :: Application - >> odl-openflowplugin-nsf-model│ 0.6.2 >> │ │
Re: [openflowplugin-dev] Updated to 0.6.2 but nobody listening on port 6653 !
No evidence found in that file for openflow being started. I generate the archetype version 1.5.2 and my karaf version is 4.1.5. I stripped the problem down to the essentials and I am able to reproduce the problem as follows: 1. Generate the archetype : mvn archetype:generate -DarchetypeGroupId=org.opendaylight.controller -DarchetypeArtifactId=opendaylight-startup-archetype -DarchetypeRepository= https://nexus.opendaylight.org/content/repositories/opendaylight.release/ -DarchetypeCatalog=remote -DarchetypeVersion=1.5.2 2. Edit the features/odl-baseapp/pom.xml and add just the following dependency: .. org.opendaylight.openflowplugin odl-openflowplugin-southbound xml features 0.6.2 After I build and start karaf ( *Note that I have not started my feature yet* ) I see the following: feature:list | grep openflow odl-openflowplugin-libraries │ 0.6.2│ │ Started │ odl-openflowplugin-libraries │ OpenDaylight :: Openflow Plugin :: Libraries odl-openflowplugin-nsf-model │ 0.6.2│ │ Started │ odl-openflowplugin-nsf-model │ OpenDaylight :: OpenflowPlugin :: NSF :: Model odl-openflowjava-protocol│ 0.6.2│ │ Started │ odl-openflowjava-0.6.2 │ ODL :: openflowjava :: odl-openflowjava-protocol odl-openflowplugin-southbound│ 0.6.2│ │ Started │ openflowplugin-0.6.2 │ OpenDaylight :: Openflow Plugin :: Li southbound I can netstat and see that 6653 is being used. Now I go to start my feature: feature:install features-baseapp And I can no more see 6653 in my netstat. Note that I have added no code. This is just a skeleton. I wonder if I am editing the right file. Should I be adding the openflow dependency to features/odl-baseapp/pom.xml or elsewhere? Is this a bug report that I should file ( under which component ? ) Thanks a lot for your help. Regards, Ranga On Sat, Aug 4, 2018 at 11:30 PM, Luis Gomez wrote: > Not sure which distribution you are using but you can check > etc/org.apache.karaf.features.cfg to see what is being installed when you > start it. > > On Aug 4, 2018, at 7:06 PM, M. Ranganathan wrote: > > Still no luck. Here is my list of openflow features (after the change you > suggested ): > > odl-openflowplugin-app-forwardingrules-manager │ 0.6.2 > │ │ Started │ odl-openflowplugin-app-forwardingrules-manager > │ OpenDaylight :: Openflow Plugin :: Application - > odl-openflowplugin-libraries│ 0.6.2 > │ │ Started │ odl-openflowplugin-libraries > │ OpenDaylight :: Openflow Plugin :: Libraries > odl-openflowplugin-app-config-pusher│ 0.6.2 > │ │ Started │ odl-openflowplugin-app-config-pusher > │ OpenDaylight :: Openflow Plugin :: Application - > odl-openflowplugin-nsf-model│ 0.6.2 > │ │ Started │ odl-openflowplugin-nsf-model > │ OpenDaylight :: OpenflowPlugin :: NSF :: Model > odl-openflowjava-protocol │ 0.6.2 > │ │ Started │ odl-openflowjava-0.6.2 > │ ODL :: openflowjava :: odl-openflowjava-protocol > odl-openflowplugin-app-topology │ 0.6.2 > │ │ Started │ odl-openflowplugin-app-topology > │ OpenDaylight :: Openflow Plugin :: Application - > odl-openflowplugin-flow-services│ 0.6.2 > │ │ Started │ odl-openflowplugin-flow-services > │ OpenDaylight :: Openflow Plugin :: Flow Services > odl-openflowplugin-southbound │ 0.6.2 > │ │ Started │ openflowplugin-0.6.2 > │ OpenDaylight :: Openflow Plugin :: Li southbound > odl-openflowplugin-app-reconciliation-framework │ 0.6.2 > │ │ Started │ odl-openflowplugin-app-reconciliation-framework > │ OpenDaylight :: Openflow Plugin :: Application - > > > I still don't understand one thing -- why is the port being used BEFORE I > start my application? > > It appears that the openflow features are already running when the > container is started. Indeed when I do a feature list BEFORE starting my > own feature I get the SAME list as above. (i.e. the features are in the > started state already). > > This is different from my previous version (i.e. Nitrogen ) where these > features where listed in an Uninstalled state. > > Thanks, > > Ranga > > On Sat, Aug 4, 2018 at 7:42 PM, Luis Gomez wrote: > >> This dependency breaks your feature: >> >> >> org.opendaylight.openflowplugin >> features-openflowplugin >> xml >> features >> >> >> >> With the above
Re: [openflowplugin-dev] Updated to 0.6.2 but nobody listening on port 6653 !
Still no luck. Here is my list of openflow features (after the change you suggested ): odl-openflowplugin-app-forwardingrules-manager │ 0.6.2 │ │ Started │ odl-openflowplugin-app-forwardingrules-manager │ OpenDaylight :: Openflow Plugin :: Application - odl-openflowplugin-libraries│ 0.6.2 │ │ Started │ odl-openflowplugin-libraries │ OpenDaylight :: Openflow Plugin :: Libraries odl-openflowplugin-app-config-pusher│ 0.6.2 │ │ Started │ odl-openflowplugin-app-config-pusher │ OpenDaylight :: Openflow Plugin :: Application - odl-openflowplugin-nsf-model│ 0.6.2 │ │ Started │ odl-openflowplugin-nsf-model │ OpenDaylight :: OpenflowPlugin :: NSF :: Model odl-openflowjava-protocol │ 0.6.2 │ │ Started │ odl-openflowjava-0.6.2 │ ODL :: openflowjava :: odl-openflowjava-protocol odl-openflowplugin-app-topology │ 0.6.2 │ │ Started │ odl-openflowplugin-app-topology │ OpenDaylight :: Openflow Plugin :: Application - odl-openflowplugin-flow-services│ 0.6.2 │ │ Started │ odl-openflowplugin-flow-services │ OpenDaylight :: Openflow Plugin :: Flow Services odl-openflowplugin-southbound │ 0.6.2 │ │ Started │ openflowplugin-0.6.2 │ OpenDaylight :: Openflow Plugin :: Li southbound odl-openflowplugin-app-reconciliation-framework │ 0.6.2 │ │ Started │ odl-openflowplugin-app-reconciliation-framework │ OpenDaylight :: Openflow Plugin :: Application - I still don't understand one thing -- why is the port being used BEFORE I start my application? It appears that the openflow features are already running when the container is started. Indeed when I do a feature list BEFORE starting my own feature I get the SAME list as above. (i.e. the features are in the started state already). This is different from my previous version (i.e. Nitrogen ) where these features where listed in an Uninstalled state. Thanks, Ranga On Sat, Aug 4, 2018 at 7:42 PM, Luis Gomez wrote: > This dependency breaks your feature: > > > org.opendaylight.openflowplugin > features-openflowplugin > xml > features > > > > With the above you are installing all features available in openflowplugin > and some of them are not compatible with each other, so instead of bringing > the full repo just bring one by one the features (odl-openflowplugin-*) > that you need, for example: > > > org.opendaylight.openflowplugin > odl-openflowplugin-southbound > xml > features > > > BR/Luis > > > On Aug 4, 2018, at 3:41 PM, M. Ranganathan wrote: > > > > > > -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] Updated to 0.6.2 but nobody listening on port 6653 !
Thanks for replying. Here is the output of feature:list -i (please see attached file) Regards, Ranga On Sat, Aug 4, 2018 at 4:48 PM, Luis Gomez wrote: > version seems fine, can you tell which ODL features do you install > together? e.g. output of feature:list -i > > BR/Luis > > On Aug 4, 2018, at 12:54 PM, M. Ranganathan wrote: > > Here are my version settings in my pom.xml file: > > > OpenDaylight :: baseapp :: Impl [Karaf Feature] > > 0.12.2 > 1.7.2 > 1.7.2 > 0.7.2 > 0.7.2 > 0.7.2 > 0.4.2 > 0.6.2 > etc/opendaylight/karaf configfile.directory> > > > I see some exceptions in my log like this: > > > Caused by: java.lang.NoSuchMethodException: org.opendaylight.yang.gen.v1. > urn.opendaylight.params.xml.ns.yang.openflowplugin.app. > reconciliation.service.rev180227.ReconciliationService.reconcileNode(org. > opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns. > yang.openflowplugin.app.reconciliation.service. > rev180227.ReconcileNodeInput) > at java.lang.Class.getMethod(Class.java:1786) ~[?:?] > at org.opendaylight.controller.md.sal.binding.impl. > BindingToNormalizedNodeCodec.findRpcMethod(BindingToNormalizedNodeCodec.java:333) > ~[?:?] > at org.opendaylight.controller.md.sal.binding.impl. > BindingToNormalizedNodeCodec.getRpcMethodToSchema( > BindingToNormalizedNodeCodec.java:299) ~[?:?] > at org.opendaylight.controller.md.sal.binding.impl. > RpcServiceAdapter.(RpcServiceAdapter.java:60) ~[?:?] > at org.opendaylight.controller.md.sal.binding.impl. > BindingDOMRpcServiceAdapter.createProxy(BindingDOMRpcServiceAdapter.java:57) > ~[?:?] > at org.opendaylight.controller.md.sal.binding.impl. > BindingDOMRpcServiceAdapter.access$000(BindingDOMRpcServiceAdapter.java:24) > ~[?:?] > at org.opendaylight.controller.md.sal.binding.impl. > BindingDOMRpcServiceAdapter$1.load(BindingDOMRpcServiceAdapter.java:34) > ~[?:?] > at org.opendaylight.controller.md.sal.binding.impl. > BindingDOMRpcServiceAdapter$1.load(BindingDOMRpcServiceAdapter.java:30) > ~[?:?] > at com.google.common.cache.LocalCache$LoadingValueReference. > loadFuture(LocalCache.java:3523) ~[?:?] > at > com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2249) > ~[?:?] > at com.google.common.cache.LocalCache$Segment. > lockedGetOrLoad(LocalCache.java:2132) ~[?:?] > at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2045) > ~[?:?] > at com.google.common.cache.LocalCache.get(LocalCache.java:3962) ~[?:?] > at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:3966) > ~[?:?] > at > com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:4951) > ~[?:?] > at com.google.common.cache.LocalCache$LocalLoadingCache. > getUnchecked(LocalCache.java:4957) ~[?:?] > at org.opendaylight.controller.md.sal.binding.impl. > BindingDOMRpcServiceAdapter.getRpcService(BindingDOMRpcServiceAdapter.java:51) > ~[?:?] > at org.opendaylight.controller.md.sal.binding.compat. > HeliumRpcProviderRegistry.getRpcService(HeliumRpcProviderRegistry.java:48) > ~[?:?] > at Proxy9b50ced3_18c2_46fa_ad81_779f5f28b872.getRpcService(Unknown > Source) ~[?:?] > at org.opendaylight.controller.blueprint.ext. > AbstractInvokableServiceMetadata.create(AbstractInvokableSe > > > Something tells me there's a version mismatch but what? > > Thanks, > > Ranga > > > > On Sat, Aug 4, 2018 at 3:19 PM, M. Ranganathan wrote: > >> Hello, >> >> I recently upgraded to the latest version of openflow plugin. I started >> my karaf container and I noticed that openflow plugin was already running >> when I did a feature:list ( why ? ), I did a netstat and noted port 6653 >> open as expected. I loaded my application ( which includes openflow plugin >> features in its feature description ). I did a netstat again and noticed >> nothing was listening on port 6653. However, when did feature:list the >> openflow plugin feature was still running. >> >> I am looking for clues about what could be happening. Any help debugging >> this would be appreciated. >> >> Note that this same application was running fine under Nitrogen. >> >> I'd be glad to attach Karaf logs if anybody could help. >> >> Thank you in advance. >> >> Ranga >> >> -- >> M. Ranganathan >> >> > > > -- > M. Ranganathan > > ___ > openflowplugin-dev mailing list > openflowplugin-dev@lists.opendaylight.org > https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev > > > -- M. Ranganathan foo Description: Binary data ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] Updated to 0.6.2 but nobody listening on port 6653 !
Here are my version settings in my pom.xml file: OpenDaylight :: baseapp :: Impl [Karaf Feature] 0.12.2 1.7.2 1.7.2 0.7.2 0.7.2 0.7.2 0.4.2 0.6.2 etc/opendaylight/karaf I see some exceptions in my log like this: Caused by: java.lang.NoSuchMethodException: org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.openflowplugin.app.reconciliation.service.rev180227.ReconciliationService.reconcileNode(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.openflowplugin.app.reconciliation.service.rev180227.ReconcileNodeInput) at java.lang.Class.getMethod(Class.java:1786) ~[?:?] at org.opendaylight.controller.md.sal.binding.impl.BindingToNormalizedNodeCodec.findRpcMethod(BindingToNormalizedNodeCodec.java:333) ~[?:?] at org.opendaylight.controller.md.sal.binding.impl.BindingToNormalizedNodeCodec.getRpcMethodToSchema(BindingToNormalizedNodeCodec.java:299) ~[?:?] at org.opendaylight.controller.md.sal.binding.impl.RpcServiceAdapter.(RpcServiceAdapter.java:60) ~[?:?] at org.opendaylight.controller.md.sal.binding.impl.BindingDOMRpcServiceAdapter.createProxy(BindingDOMRpcServiceAdapter.java:57) ~[?:?] at org.opendaylight.controller.md.sal.binding.impl.BindingDOMRpcServiceAdapter.access$000(BindingDOMRpcServiceAdapter.java:24) ~[?:?] at org.opendaylight.controller.md.sal.binding.impl.BindingDOMRpcServiceAdapter$1.load(BindingDOMRpcServiceAdapter.java:34) ~[?:?] at org.opendaylight.controller.md.sal.binding.impl.BindingDOMRpcServiceAdapter$1.load(BindingDOMRpcServiceAdapter.java:30) ~[?:?] at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3523) ~[?:?] at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2249) ~[?:?] at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2132) ~[?:?] at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2045) ~[?:?] at com.google.common.cache.LocalCache.get(LocalCache.java:3962) ~[?:?] at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:3966) ~[?:?] at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:4951) ~[?:?] at com.google.common.cache.LocalCache$LocalLoadingCache.getUnchecked(LocalCache.java:4957) ~[?:?] at org.opendaylight.controller.md.sal.binding.impl.BindingDOMRpcServiceAdapter.getRpcService(BindingDOMRpcServiceAdapter.java:51) ~[?:?] at org.opendaylight.controller.md.sal.binding.compat.HeliumRpcProviderRegistry.getRpcService(HeliumRpcProviderRegistry.java:48) ~[?:?] at Proxy9b50ced3_18c2_46fa_ad81_779f5f28b872.getRpcService(Unknown Source) ~[?:?] at org.opendaylight.controller.blueprint.ext.AbstractInvokableServiceMetadata.create(AbstractInvokableSe Something tells me there's a version mismatch but what? Thanks, Ranga On Sat, Aug 4, 2018 at 3:19 PM, M. Ranganathan wrote: > Hello, > > I recently upgraded to the latest version of openflow plugin. I started my > karaf container and I noticed that openflow plugin was already running > when I did a feature:list ( why ? ), I did a netstat and noted port 6653 > open as expected. I loaded my application ( which includes openflow plugin > features in its feature description ). I did a netstat again and noticed > nothing was listening on port 6653. However, when did feature:list the > openflow plugin feature was still running. > > I am looking for clues about what could be happening. Any help debugging > this would be appreciated. > > Note that this same application was running fine under Nitrogen. > > I'd be glad to attach Karaf logs if anybody could help. > > Thank you in advance. > > Ranga > > -- > M. Ranganathan > > -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] Updated to 0.6.2 but nobody listening on port 6653 !
Hello, I recently upgraded to the latest version of openflow plugin. I started my karaf container and I noticed that openflow plugin was already running when I did a feature:list ( why ? ), I did a netstat and noted port 6653 open as expected. I loaded my application ( which includes openflow plugin features in its feature description ). I did a netstat again and noticed nothing was listening on port 6653. However, when did feature:list the openflow plugin feature was still running. I am looking for clues about what could be happening. Any help debugging this would be appreciated. Note that this same application was running fine under Nitrogen. I'd be glad to attach Karaf logs if anybody could help. Thank you in advance. Ranga -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] Sending flow to switch but NOT the config database?
I did as you suggested but no flow appears and I see the following error in my log: java.util.concurrent.ExecutionException: org.opendaylight.controller.md.sal.dom.api.DOMRpcImplementationNotAvailableException: No implementation of RPC AbsoluteSchemaPath{path=[(urn:opendaylight:flow:service?revision=2013-08-19)add-flow]} available at com.google.common.util.concurrent.AbstractFuture.getDoneValue(AbstractFuture.java:503) at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:462) at com.google.common.util.concurrent.AbstractFuture$TrustedFuture.get(AbstractFuture.java:79) at gov.nist.antd.sdnmud.impl.FlowWriter.writeFlow(FlowWriter.java:69) I just got the FlowService and called the addFlow method of the flow service. Should I do anything prior to making that call? Thanks. On Thu, Jul 12, 2018 at 4:45 PM, Luis Gomez wrote: > You can send openflow RPC like the example below: > > POST http://192.168.0.101:8181/restconf/operations/sal-flow:add-flow > { > "input": { > "opendaylight-flow-service:node":"/opendaylight- > inventory:nodes/opendaylight-inventory:node[opendaylight- > inventory:id='openflow:1']", > "priority": 2, > "flow-name": "flow1", > "table_id": 0, > "hard-timeout": 0, > "instructions": { > "instruction": [ > { > "order": 0, > "apply-actions": { > "action": [ > { > "order": 0, > "output-action": { > "output-node-connector": "1" > } > } > ] > } > } > ] > }, > "idle-timeout": 0, > "match": { > "ipv4-destination": "10.0.10.0/24", > "ethernet-match": { > "ethernet-type": { > "type": 2048 > } > } > } > } > } > > > > > On Jul 12, 2018, at 12:09 PM, M. Ranganathan wrote: > > > > I am using OpendDaylight Nitrogen. In order to send a flow to the > switch, I write to the CONFIG database - which winds up sending the flow to > the switch. However, I want faster performance for ephemeral flows . How > can I send the flow to the switch without involving the CONFIG database? > > > > Thanks, > > > > Ranga > > > > -- > > M. Ranganathan > > > > ___ > > openflowplugin-dev mailing list > > openflowplugin-dev@lists.opendaylight.org > > https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev > > -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] Sending flow to switch but NOT the config database?
I am using OpendDaylight Nitrogen. In order to send a flow to the switch, I write to the CONFIG database - which winds up sending the flow to the switch. However, I want faster performance for ephemeral flows . How can I send the flow to the switch without involving the CONFIG database? Thanks, Ranga -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] OpenFlow 1.5 support
Hello, I am interested in certain features of openflow 1.5 - in particular TCP flags matching. Does opendaylight openflow plugin support Openflow 1.5 and if so what version ? Thank you, Ranga -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] Efficiently re-installing flows in a switch
Hello, I am writing an application where I need to install some short lived flows on a switch that could get re-installed again and again on a switch. Here's the code that writes my flow out : synchronized void writeFlow(Flow flow, InstanceIdentifier flowNodeIdent) { ReadWriteTransaction modification = dataBrokerService.newReadWriteTransaction(); final InstanceIdentifier path1 = flowNodeIdent.child(Table.class, new TableKey(flow.getTableId())) .child(Flow.class, flow.getKey()); modification.merge(LogicalDatastoreType.CONFIGURATION, path1, flow, true); modification.submit(); } I am invoking this code several times for the same flow. I think I am doing something wrong by writing to the Configuration store again and again for the SAME flow. It works but takes longer than I think it should. Perhaps I am doing something wrong and there is a more efficient way to do this? Thanks, Ranga -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] How to match on VLAN
Not sure if this would help ( I was trying something a little different than you are ) but I had some issues creating set Vlan flows in Carbon https://stackoverflow.com/questions/47610513/how-to-create-a-set-vlan-flow I had much better luck with Nitrogen Ranga On Fri, Apr 13, 2018 at 5:42 PM, Brady Johnson <bjohn...@inocybe.ca> wrote: > > Hello, > > Im trying to write flows to pop-vlan or just simply set the vlan-id, but > the flows arent being written to operational, nor the bridge. I tried doing > an etherType match on VLAN (0x8100) but that doesnt help. > > The 2 use cases I have are for flows that ingress the bridge with VLAN > already set are: > > 1) if VLAN present (could be lots of different vlan IDs), pop it. > 2) if VLAN present set the VLAN id to a different one. > > Ive tried flows for both of these cases, and neither are written to > Operational. Ideally there should be an 802.1Q TPID (Tag protocol ID) match > field, where you could match on 0x8100, but I couldnt find anything like > this. > > Regards, > > *Brady Johnson* > bjohn...@inocybe.ca > > <https://twitter.com/inocybetech> <http://www.inocybe.com/> > <https://www.linkedin.com/company/2661537?trk=tyah=clickedVertical%3Acompany%2CclickedEntityId%3A2661537%2Cidx%3A1-1-1%2CtarId%3A1441300264767%2Ctas%3Ainocybe> > [image: > Screenshot 2017-02-14 at 10.43.55 AM.png] > <https://www.youtube.com/channel/UC9uUWABdPR0Je9Du_15FCkw> > > > > ___ > openflowplugin-dev mailing list > openflowplugin-dev@lists.opendaylight.org > https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev > > -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] Convert a Flow object into a command line string
On Thu, Apr 12, 2018 at 2:36 PM, Michael Vorburger <vorbur...@redhat.com> wrote: > On Thu, Apr 12, 2018 at 8:02 PM, Xingjun Chu <xingjun@huawei.com> > wrote: > >> >> >> Hi, >> >> >> >> I am wondering if there is such tool available to convert a Flow java >> Object into a for example ovs-ofctl command line command? >> > > not that I know of, but it could be a cool idea if you would like to > contribute the code with a helper doing this. > > Tx, > M. > -- > Michael Vorburger, Red Hat > vorbur...@redhat.com | IRC: vorburger @freenode | ~ = http://vorburger.ch > > > Thanks >> >> Xingjun >> >> ___ >> openflowplugin-dev mailing list >> openflowplugin-dev@lists.opendaylight.org >> https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev >> >> > > ___ > openflowplugin-dev mailing list > openflowplugin-dev@lists.opendaylight.org > https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev > > Interesting idea. The other direction seems to work fairly mechanically. I can take a JSON object and mechanically map it to Java code. Once the flow is Pushed from your Java application, you can also retrieve it as a JSON object from MDSAL. Ranga -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] [mdsal-dev] Possible MDSAL issue -- how to debug?
I did try using different order parameter but still no luck (I was stuck trying different combinations of various parameters for a week). Incidentally, if I use MPLS tags instead of vlan tags, everything works fine. It almost appears like something is not being appended to a list. I will try to reproduce this using a XML script to see if I can reproduce it and file a bug report in JIRA with instructions on how to reproduce it. Thanks for responding. Regards, Ranga On Sun, Dec 10, 2017 at 5:47 PM, Luis Gomez <ece...@gmail.com> wrote: > Only issue I can think here is if both actions you are trying have the > same "order" parameter. And since order is the list key, you may be hitting > this bug: https://jira.opendaylight.org/browse/YANGTOOLS-834 > > grouping action-list { > list action { > key "order"; > uses ordered; > uses action; > } > } > > > On Dec 8, 2017, at 6:43 PM, M. Ranganathan <mra...@gmail.com> wrote: > > Hi Anil, > > The push vlan is working fine. It does not work when I have a push and a > goto instruction. > > Either the push OR the goto shows up. I cannot have BOTH push and goto in > the same flow. > > I am working via the java API. I am working with the Carbon-42 openflow > plugin. > > Please see attached Java file. > > I had planned to reproduce the issue using a stand alone test script using > the XML API. > > Let me know if I should do that. > > Thank you for your help. > > Regards, > > Ranga > > > > On Fri, Dec 8, 2017 at 8:35 PM, Anil Vishnoi <vishnoia...@gmail.com> > wrote: > >> can you please paste me the flow that you are writing to the datastore? >> Because i tried to push the PUSH_VLAN flow that you mentioned above and i >> was able to push the flow successfully and i see the same data in the >> config data store when i fetched it back. >> >> On Wed, Dec 6, 2017 at 8:27 AM, M. Ranganathan <mra...@gmail.com> wrote: >> >>> >>> >>> I logged everything that I send to the transaction. When I print out the >>> flow (which follows a yang model), I can see all the elements in there (see >>> my previous mail in this thread). It is possible that the openflow >>> southbound plugin which stuffs the datstore (?) does not like something >>> and is silently stripping out data. Once the transaction is submitted and >>> commit succeeds, the app should be able to release references to the data. >>> Indeed I am making the whole commit synchronous to avoid shooting myself in >>> the foot. >>> >>> I will engage with the openflow plugin developers to see how I can track >>> this down. I hope somebody will respond from the openflowplugin-dev list to >>> let me know what debug I should turn on so I can produce some more >>> diagnostics. >>> >>> So in summary, I am able to reproduce the following action in a flow via >>> the JAVA API. >>> >>> https://wiki.opendaylight.org/view/Editing_OpenDaylight_Open >>> Flow_Plugin:End_to_End_Flows:Example_Flows#Push_VLAN >>> >>> I can mimic what the REST api does by direct JAVA calls and the flow >>> does appear but what I want is to ALSO have a goto. This is my issue. If >>> the GOTO is added to the flow, the VLAN push action is stripped off. >>> >>> Thanks for your tips and sorry for the number of mails on this. >>> >>> >>> >>> >>> On Wed, Dec 6, 2017 at 11:16 AM, Tom Pantelis <tompante...@gmail.com> >>> wrote: >>> >>>> >>>> >>>> On Wed, Dec 6, 2017 at 10:46 AM, M. Ranganathan <mra...@gmail.com> >>>> wrote: >>>> >>>>> Hi Ryan, >>>>> >>>>> Thanks for forwarding but what is puzzling me is why the flow does not >>>>> appear as it should in the Config Datastore. If the YANG model matches >>>>> should it not appear in the config datastore? >>>>> >>>>> I could see it as an openflow problem if I saw an exception why trying >>>>> to instantiate the flow. >>>>> >>>>> I was suspecting MDSAL for this reason. Perhaps I am mistaken. >>>>> >>>> >>>> The MDSAL commits exactly what clients tell it to do, ie it doesn't >>>> randomly omit or strip out data. I'm not that familiar with OFP and I'm not >>>> really clear on exactly what you're doing but if something is miss
Re: [openflowplugin-dev] [mdsal-dev] Possible MDSAL issue -- how to debug?
Hi Anil, The push vlan is working fine. It does not work when I have a push and a goto instruction. Either the push OR the goto shows up. I cannot have BOTH push and goto in the same flow. I am working via the java API. I am working with the Carbon-42 openflow plugin. Please see attached Java file. I had planned to reproduce the issue using a stand alone test script using the XML API. Let me know if I should do that. Thank you for your help. Regards, Ranga On Fri, Dec 8, 2017 at 8:35 PM, Anil Vishnoi <vishnoia...@gmail.com> wrote: > can you please paste me the flow that you are writing to the datastore? > Because i tried to push the PUSH_VLAN flow that you mentioned above and i > was able to push the flow successfully and i see the same data in the > config data store when i fetched it back. > > On Wed, Dec 6, 2017 at 8:27 AM, M. Ranganathan <mra...@gmail.com> wrote: > >> >> >> I logged everything that I send to the transaction. When I print out the >> flow (which follows a yang model), I can see all the elements in there (see >> my previous mail in this thread). It is possible that the openflow >> southbound plugin which stuffs the datstore (?) does not like something >> and is silently stripping out data. Once the transaction is submitted and >> commit succeeds, the app should be able to release references to the data. >> Indeed I am making the whole commit synchronous to avoid shooting myself in >> the foot. >> >> I will engage with the openflow plugin developers to see how I can track >> this down. I hope somebody will respond from the openflowplugin-dev list to >> let me know what debug I should turn on so I can produce some more >> diagnostics. >> >> So in summary, I am able to reproduce the following action in a flow via >> the JAVA API. >> >> https://wiki.opendaylight.org/view/Editing_OpenDaylight_Open >> Flow_Plugin:End_to_End_Flows:Example_Flows#Push_VLAN >> >> I can mimic what the REST api does by direct JAVA calls and the flow does >> appear but what I want is to ALSO have a goto. This is my issue. If the >> GOTO is added to the flow, the VLAN push action is stripped off. >> >> Thanks for your tips and sorry for the number of mails on this. >> >> >> >> >> On Wed, Dec 6, 2017 at 11:16 AM, Tom Pantelis <tompante...@gmail.com> >> wrote: >> >>> >>> >>> On Wed, Dec 6, 2017 at 10:46 AM, M. Ranganathan <mra...@gmail.com> >>> wrote: >>> >>>> Hi Ryan, >>>> >>>> Thanks for forwarding but what is puzzling me is why the flow does not >>>> appear as it should in the Config Datastore. If the YANG model matches >>>> should it not appear in the config datastore? >>>> >>>> I could see it as an openflow problem if I saw an exception why trying >>>> to instantiate the flow. >>>> >>>> I was suspecting MDSAL for this reason. Perhaps I am mistaken. >>>> >>> >>> The MDSAL commits exactly what clients tell it to do, ie it doesn't >>> randomly omit or strip out data. I'm not that familiar with OFP and I'm not >>> really clear on exactly what you're doing but if something is missing in >>> the data then I suspect either it isn't getting written or it was deleted >>> or overwritten somewhere along the line in the app code. >>> >>> >>>> >>>> Thanks. >>>> >>>> Ranga >>>> >>> >>> >> >> >> -- >> M. Ranganathan >> >> “If debugging is the process of removing software bugs, then programming >> must be the process of putting them in.” – Edsger Dijkstra >> >> >> ___ >> openflowplugin-dev mailing list >> openflowplugin-dev@lists.opendaylight.org >> https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev >> >> > > > -- > Thanks > Anil > -- M. Ranganathan “If debugging is the process of removing software bugs, then programming must be the process of putting them in.” – Edsger Dijkstra private static Instruction createSetVlanAndOutputToPortInstructions(int vlanId, String outputPortUri) { List actionList = new ArrayList<>(); ActionBuilder ab = new ActionBuilder(); Integer VLAN_ETHERTYPE = 0x8100; ActionBuilder actionBuilder = new ActionBuilder(); // push vlan Action pushVlanAction = actionBuilder.setOrder(0) .setAction(new PushVlanActionCaseBuilder() .setPushVlanAction( new PushVlanActionBuilder().setTag(vlanId).setEthernetType(VLAN_ETHERTYPE).b
[openflowplugin-dev] How to report issues?
Hello devs. I want to report a bug in the openflow southbound plugin along with a test case. Is there a JIRA for openflow plugin where I can do this? I am willing to pitch in to try to fix bugs. Thank you for your work. Regards, Ranga -- M. Ranganathan “If debugging is the process of removing software bugs, then programming must be the process of putting them in.” – Edsger Dijkstra ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] [mdsal-dev] Possible MDSAL issue -- how to debug?
I logged everything that I send to the transaction. When I print out the flow (which follows a yang model), I can see all the elements in there (see my previous mail in this thread). It is possible that the openflow southbound plugin which stuffs the datstore (?) does not like something and is silently stripping out data. Once the transaction is submitted and commit succeeds, the app should be able to release references to the data. Indeed I am making the whole commit synchronous to avoid shooting myself in the foot. I will engage with the openflow plugin developers to see how I can track this down. I hope somebody will respond from the openflowplugin-dev list to let me know what debug I should turn on so I can produce some more diagnostics. So in summary, I am able to reproduce the following action in a flow via the JAVA API. https://wiki.opendaylight.org/view/Editing_OpenDaylight_OpenFlow_Plugin:End_to_End_Flows:Example_Flows#Push_VLAN I can mimic what the REST api does by direct JAVA calls and the flow does appear but what I want is to ALSO have a goto. This is my issue. If the GOTO is added to the flow, the VLAN push action is stripped off. Thanks for your tips and sorry for the number of mails on this. On Wed, Dec 6, 2017 at 11:16 AM, Tom Pantelis <tompante...@gmail.com> wrote: > > > On Wed, Dec 6, 2017 at 10:46 AM, M. Ranganathan <mra...@gmail.com> wrote: > >> Hi Ryan, >> >> Thanks for forwarding but what is puzzling me is why the flow does not >> appear as it should in the Config Datastore. If the YANG model matches >> should it not appear in the config datastore? >> >> I could see it as an openflow problem if I saw an exception why trying to >> instantiate the flow. >> >> I was suspecting MDSAL for this reason. Perhaps I am mistaken. >> > > The MDSAL commits exactly what clients tell it to do, ie it doesn't > randomly omit or strip out data. I'm not that familiar with OFP and I'm not > really clear on exactly what you're doing but if something is missing in > the data then I suspect either it isn't getting written or it was deleted > or overwritten somewhere along the line in the app code. > > >> >> Thanks. >> >> Ranga >> > > -- M. Ranganathan “If debugging is the process of removing software bugs, then programming must be the process of putting them in.” – Edsger Dijkstra ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
Re: [openflowplugin-dev] [mdsal-dev] Possible MDSAL issue -- how to debug?
Hi Ryan, Thanks for forwarding but what is puzzling me is why the flow does not appear as it should in the Config Datastore. If the YANG model matches should it not appear in the config datastore? I could see it as an openflow problem if I saw an exception why trying to instantiate the flow. I was suspecting MDSAL for this reason. Perhaps I am mistaken. Thanks. Ranga On Wed, Dec 6, 2017 at 10:42 AM, Ryan Goulding <ryandgould...@gmail.com> wrote: > This is an OpenFlow issue; forwarding your request to openflowplugin-dev. > > Kind Regards, > > Ryan Goulding > > On Wed, Dec 6, 2017 at 10:40 AM, M. Ranganathan <mra...@gmail.com> wrote: > >> What is interesting is that a PUSH and output WITHOUT the GOTO does >> appear. Why does the GOTO cause the problem? >> >> Clearly this is a legal flow -- I can construct it with ovs-ofctl but not >> with opendaylight. >> >> What am I doing wrong? >> >> On Tue, Dec 5, 2017 at 4:22 PM, M. Ranganathan <mra...@gmail.com> wrote: >> >>> >>> On Tue, Dec 5, 2017 at 2:14 AM, Tom Pantelis <tompante...@gmail.com> >>> wrote: >>> >>>> >>>> >>>> On Mon, Dec 4, 2017 at 6:42 PM, M. Ranganathan <mra...@gmail.com> >>>> wrote: >>>> >>>>> >>>>> Hello, >>>>> >>>>> I am working with the openflow southbound trying to install a flow >>>>> that installs a vlan push action with a goto and an output. >>>>> >>>>> I believe I have hit an MDSAL issue because all I see in the config >>>>> data store is: >>>>> >>>>> >>>>> First, is this a known issue for the Carbon release that has been fixed >>>>> >>>>> (is there a bug tracker for MDSAL where I can check?) If so I'll move up >>>>> to Nitrogen. >>>>> >>>>> Second, how can I debug MDSAL? I'd like to selectively turn on debug >>>>> tracing for that component only. >>>>> >>>>> How can I set up debugging ONLY for that component so I can figure >>>>> >>>>> out what is going on? >>>>> >>>>> >>>> I'm not aware of any issue in the data store where a client submits >>>> data but it somehow doesn't get written/applied or is otherwise missing >>>> when retrieved. It will return an error (and log it) if it can't commit the >>>> transaction for any reason. >>>> >>>> To see transaction activity on the front-end side, you can enable this >>>> debug: >>>> >>>>log4j.logger.org.opendaylight.controller.cluster.datastore. >>>> TransactionProxy=DEBUG >>>> >>>> This will log all writes, merges, and deletes so you can see if you're >>>> expected data was actually written (or if it got deleted). >>>> >>> >>> >>> I did what you suggested and logged the instructions from the flow just >>> before commit. I turned on debugging. The commit succeded (no exceptions). >>> So the flow appears in the config but no Vlan push or set instruction or >>> output only the goto table instruction. It appears that something stripped >>> these off in the process of writing to config datastore. >>> The match here is on metadata. >>> >>> In the logs, I simply see : >>> >>> | 288 - gov.nist.sdnmud.impl - 0.1.0.SNAPSHOT | >>> org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory >>> .rev130819.tables.table.FlowBuilder@470b2bcb >>> 2017-12-06 02:48:35,843 | DEBUG | tp1317035402-582 | >>> TransactionProxy | 204 - >>> org.opendaylight.controller.sal-distributed-datastore >>> - 1.5.2.Carbon | New READ_WRITE Tx - member-1-datastore-config-fe-1 >>> -txn-121-0 >>> 2017-12-06 02:48:35,843 | DEBUG | tp1317035402-582 | >>> TransactionProxy | 204 - >>> org.opendaylight.controller.sal-distributed-datastore >>> - 1.5.2.Carbon | Tx member-1-datastore-config-fe-1-txn-121-0 >>> executeModification MergeModification /(urn:opendaylight:inventory?r >>> evision=2013-08-19)nodes >>> 2017-12-06 02:48:35,843 | DEBUG | tp1317035402-582 | >>> TransactionProxy | 204 - >>> org.opendaylight.controller.sal-distributed-datastore >>> - 1.5.2.Carbon | Tx member-1-datastore-config-fe-1-txn-121-0 >>> executeModification MergeModification /(urn:opendaylight:inventory?r >>>
Re: [openflowplugin-dev] VLAN strip action is not appearing in the flow
I was able to get this to work using a pop vlan tag instruction. I wonder why strip vlan tag does not work. Oh well... On Sun, Dec 3, 2017 at 11:52 AM, M. Ranganathan <mra...@gmail.com> wrote: > Hello experts, > > I am using the Carbon-4.2 version of the openflow plugin. I am attempting > to install a flow where I match on a vlan tag and strip the tag if present > and go to a target table. I find that the vlan strip action never gets > added to my flow. Here is what I get > > cookie=0x34c13baf, duration=10.147s, table=3, n_packets=0, n_bytes=0, > priority=35,dl_vlan=1001 actions=goto_table:4 > > ONLY the gototable instruction appears in the flow and not the strip vlan > tag instruction. > > What am I doing wrong? Is VLAN tag manipulation working in Carbon-42? I am > using the Java API to try to do this. Thank you in advance. > > Here's my code to strip the vlan > > >InstructionBuilder ib = new InstructionBuilder(); > > tagStripVlanActionCaseBuilder stripCaseBuilder = new > StripVlanActionCaseBuilder(); > StripVlanActionBuilder stripBuilder = new StripVlanActionBuilder(); > stripCaseBuilder.setStripVlanAction(stripBuilder.build()); > > ActionBuilder ab = new ActionBuilder().setAction( > stripCaseBuilder.build()); > ab.setOrder(order); > List actionList = new ArrayList(); > actionList.add(ab.build()); > > WriteActionsBuilder wab = new WriteActionsBuilder(); > > wab.setAction(actionList); > > // Create an Apply Action > ApplyActionsBuilder aab = new ApplyActionsBuilder(); > > aab.setAction(actionList); > > // Wrap our Apply Action in an Instruction > ib.setInstruction(new WriteActionsCaseBuilder(). > setWriteActions(wab.build()).build()); > > Instruction stripVlanTagInstruction = ib.build(); > > // Create the goto table instruction > >Instruction gotoInstruction = ib.setInstruction(new > GoToTableCaseBuilder() > .setGoToTable(new GoToTableBuilder().setTableId( > SdnMudConstants.L2SWITCH_TABLE).build()).build()) > .setOrder(1).build(); > > > > // Here's the section of the code that builds the flow. > > instructions.add(stripVlanTagInstruction); > instructions.add(gotoInstruction); > > InstructionsBuilder insb = new InstructionsBuilder(); > > insb.setInstruction(instructions); > > FlowBuilder fb = new FlowBuilder(); > fb.setStrict(false); > fb.setBarrier(false); > > > fb.setMatch(matchBuilder.build()).setTableId(tableId) > .setFlowName("vlanMatchStripVlanTagGoToL2Swi > tch").setId(flowId).setKey(new FlowKey(flowId)) > .setCookie(flowCookie).setInstructions(insb.build()) > .setPriority(35).setBufferId(OFConstants.ANY) > .setHardTimeout(0).setIdleTimeout(0).setFlags(new > FlowModFlags(false, false, false, false, false)); > > > > > > > > > > > > -- > M. Ranganathan > -- M. Ranganathan “If debugging is the process of removing software bugs, then programming must be the process of putting them in.” – Edsger Dijkstra ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] match on metadata + Push vlan + output + goto table in one flow.
am trying to replicate the following in opendaylight that works fine for me using ovs-ofctl on openvswitch : sudo ovs-ofctl add-flow s1 priority=35,table=2,metadata=1 379878762,actions=push_vlan:0x8100,mod_vlan_vid:4000,output:6,goto_table:3 -O openflow13 When I do this with opendaylight, I don't see any actions related to vlan appearing in my flow. Neither do they appear in the config data store. Here is the code I use to create the instructions to push the flow: vlan.setTag(vlanId); vlan.setEthernetType(0x8100); ab.setAction(new PushVlanActionCaseBuilder().se tPushVlanAction(vlan.build()).build()); ab.setKey(new ActionKey(0)); ab.setOrder(0); actionList.add(ab.build()); /* Then we set vlan id value as vlanId */ SetVlanIdActionBuilder vl = new SetVlanIdActionBuilder(); vl.setVlanId(new VlanId(vlanId)); ab = new ActionBuilder(); ab.setKey(new ActionKey(0)); ab.setAction(new SetVlanIdActionCaseBuilder().s etSetVlanIdAction(vl.build()).build()); ab.setOrder(1); actionList.add(ab.build()); OutputActionBuilder output = new OutputActionBuilder(); output.setMaxLength(Integer.valueOf(0x)); Uri controllerPort = new Uri(outputPortUri); output.setOutputNodeConnector(controllerPort); ab = new ActionBuilder(); ab.setKey(new ActionKey(0)); ab.setAction(new OutputActionCaseBuilder().setO utputAction(output.build()).build()); ab.setOrder(2); actionList.add(ab.build()); // Create an Apply Action ApplyActionsBuilder aab = new ApplyActionsBuilder(); aab.setAction(actionList); // Wrap our Apply Action in an Instruction ib.setOrder(0).setInstruction(newApplyActionsCaseBuilder().setA pplyActions(aab.build()).build()); Proceeding along here's how I actually create the flow MatchBuilder matchBuilder = new MatchBuilder(); createMetadataMatch(matchBuilder, flowCookie.getValue()); InstructionBuilder ib = new InstructionBuilder(); // See above. Instruction createVlanTag = FlowUtils.createSetVlanAndOutputToPortIn structions( SdnMudConstants.MUD_RULE_HIT_LABEL, outputPortUri); InstructionsBuilder insb = new InstructionsBuilder(); ArrayList instructions = new ArrayList(); instructions.add(createVlanTag); Instruction gotoInstruction = ib.setInstruction(new GoToTableCaseBuilder() .setGoToTable(new GoToTableBuilder().setTableId( SdnMudConstants.STRIP_VLAN_RULE_TABLE).build()).build()) .setKey(new InstructionKey(0)).build(); instructions.add(gotoInstruction); insb.setInstruction(instructions); tagPacketFlow.setMatch(matchBuilder.build()). setInstructions(insb.build()) .setPriority(35).setBufferId(OFConstants.ANY) .setHardTimeout(time).setIdleTimeout(0).setFlags(new FlowModFlags(false, false, false, false, false)); I put everything into an instructionsbuilder and created a flow that included the instruction above and a goto_table instruction. Note that ONLY the gototable instruction appeared although I had set the vlan tag. What happened to my Vlan instructions? Can they coexist? { "buffer_id": 4294967295, "cookie": 1379878762, "flags": "", "flow-name": "metadataMatchVlanTagSendToPort AndGoToStripVlanTagTable", "hard-timeout": 3, "id": "toaster/42", "idle-timeout": 0, "instructions": { "instruction": [ { "go-to-table": { "table_id": 3 }, "order": 0 } ] }, "match": { "metadata": { "metadata": 1379878762 } }, "priority": 35, "table_id": 2 } -- M. Ranganathan “If debugging is the process of removing software bugs, then programming must be the process of putting them in.” – Edsger Dijkstra ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev
[openflowplugin-dev] VLAN strip action is not appearing in the flow
Hello experts, I am using the Carbon-4.2 version of the openflow plugin. I am attempting to install a flow where I match on a vlan tag and strip the tag if present and go to a target table. I find that the vlan strip action never gets added to my flow. Here is what I get cookie=0x34c13baf, duration=10.147s, table=3, n_packets=0, n_bytes=0, priority=35,dl_vlan=1001 actions=goto_table:4 ONLY the gototable instruction appears in the flow and not the strip vlan tag instruction. What am I doing wrong? Is VLAN tag manipulation working in Carbon-42? I am using the Java API to try to do this. Thank you in advance. Here's my code to strip the vlan InstructionBuilder ib = new InstructionBuilder(); tagStripVlanActionCaseBuilder stripCaseBuilder = new StripVlanActionCaseBuilder(); StripVlanActionBuilder stripBuilder = new StripVlanActionBuilder(); stripCaseBuilder.setStripVlanAction(stripBuilder.build()); ActionBuilder ab = new ActionBuilder().setAction(stripCaseBuilder.build()); ab.setOrder(order); List actionList = new ArrayList(); actionList.add(ab.build()); WriteActionsBuilder wab = new WriteActionsBuilder(); wab.setAction(actionList); // Create an Apply Action ApplyActionsBuilder aab = new ApplyActionsBuilder(); aab.setAction(actionList); // Wrap our Apply Action in an Instruction ib.setInstruction(new WriteActionsCaseBuilder().setWriteActions(wab.build()).build()); Instruction stripVlanTagInstruction = ib.build(); // Create the goto table instruction Instruction gotoInstruction = ib.setInstruction(new GoToTableCaseBuilder() .setGoToTable(new GoToTableBuilder().setTableId(SdnMudConstants.L2SWITCH_TABLE).build()).build()) .setOrder(1).build(); // Here's the section of the code that builds the flow. instructions.add(stripVlanTagInstruction); instructions.add(gotoInstruction); InstructionsBuilder insb = new InstructionsBuilder(); insb.setInstruction(instructions); FlowBuilder fb = new FlowBuilder(); fb.setStrict(false); fb.setBarrier(false); fb.setMatch(matchBuilder.build()).setTableId(tableId) .setFlowName("vlanMatchStripVlanTagGoToL2Switch").setId(flowId).setKey(new FlowKey(flowId)) .setCookie(flowCookie).setInstructions(insb.build()) .setPriority(35).setBufferId(OFConstants.ANY) .setHardTimeout(0).setIdleTimeout(0).setFlags(new FlowModFlags(false, false, false, false, false)); -- M. Ranganathan ___ openflowplugin-dev mailing list openflowplugin-dev@lists.opendaylight.org https://lists.opendaylight.org/mailman/listinfo/openflowplugin-dev