[OPNFLWPLUG-244] Flow id corrupted in operational data Created: 18/Aug/14  Updated: 27/Sep/21  Resolved: 16/Aug/16

Status: Resolved
Project: OpenFlowPlugin
Component/s: General
Affects Version/s: None
Fix Version/s: None

Type: Bug
Reporter: Luis Gomez Assignee: Luis Gomez
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: Linux
Platform: PC


External issue ID: 1565

 Description   

After pushing following flow:

{
"flow-node-inventory:table": [
{
"flow-node-inventory:flow": [
{
"flow-node-inventory:flow-name": "foo",
"flow-node-inventory:match": {
"flow-node-inventory:vlan-match": {
"flow-node-inventory:vlan-id":

{ "flow-node-inventory:vlan-id": 78, "flow-node-inventory:vlan-id-present": true }

,
"flow-node-inventory:vlan-pcp": 3
},
"flow-node-inventory:ethernet-match": {
"flow-node-inventory:ethernet-destination":

{ "flow-node-inventory:address": "ff:ff:29:01:19:61" }

,
"flow-node-inventory:ethernet-source":

{ "flow-node-inventory:address": "00:00:00:11:23:ae" }

,
"flow-node-inventory:ethernet-type":

{ "flow-node-inventory:type": 2048 }

}
},
"flow-node-inventory:priority": 2,
"flow-node-inventory:instructions": {
"flow-node-inventory:instruction": [
{
"flow-node-inventory:apply-actions": {
"flow-node-inventory:action": [
{
"flow-node-inventory:order": 2,
"flow-node-inventory:output-action":

{ "flow-node-inventory:output-node-connector": "openflow:1:1" }

},
{
"flow-node-inventory:order": 1,
"flow-node-inventory:set-field": {
"flow-node-inventory:vlan-match": {
"flow-node-inventory:vlan-id":

{ "flow-node-inventory:vlan-id": 79, "flow-node-inventory:vlan-id-present": true }

,
"flow-node-inventory:vlan-pcp": 4
}
}
}
]
},
"flow-node-inventory:order": 0
}
]
},
"flow-node-inventory:strict": false,
"flow-node-inventory:table_id": 0,
"flow-node-inventory:id": "138"
}
],
"flow-node-inventory:id": 0
}
]
}

I check Operational data for it:

{
"flow-node-inventory:table": [
{
"opendaylight-flow-table-statistics:flow-table-statistics":

{ "opendaylight-flow-table-statistics:packets-looked-up": 404, "opendaylight-flow-table-statistics:active-flows": 10, "opendaylight-flow-table-statistics:packets-matched": 212 }

,
"flow-node-inventory:flow-cookie-map": [

{ "flow-node-inventory:flow-ids": [ "#UF$TABLE*0-1" ], "flow-node-inventory:cookie": 1 }

],
"flow-node-inventory:flow": [
{
"flow-node-inventory:match": {
"flow-node-inventory:vlan-match": {
"flow-node-inventory:vlan-id":

{ "flow-node-inventory:vlan-id": 78 }

,
"flow-node-inventory:vlan-pcp": 3
},
"flow-node-inventory:ethernet-match": {
"flow-node-inventory:ethernet-destination":

{ "flow-node-inventory:address": "FF:FF:29:01:19:61" }

,
"flow-node-inventory:ethernet-source":

{ "flow-node-inventory:address": "00:00:00:11:23:AE" }

,
"flow-node-inventory:ethernet-type":

{ "flow-node-inventory:type": 2048 }

}
},
"flow-node-inventory:flags": "SEND_FLOW_REM",
"flow-node-inventory:priority": 2,
"flow-node-inventory:instructions": {
"flow-node-inventory:instruction": [
{
"flow-node-inventory:apply-actions": {
"flow-node-inventory:action": [
{
"flow-node-inventory:order": 0,
"flow-node-inventory:set-field": {
"flow-node-inventory:vlan-match": {
"flow-node-inventory:vlan-id":

{ "flow-node-inventory:vlan-id": 79 }

}
}
},
{
"flow-node-inventory:order": 1,
"flow-node-inventory:output-action":

{ "flow-node-inventory:output-node-connector": "1", "flow-node-inventory:max-length": 0 }

}
]
},
"flow-node-inventory:order": 0
}
]
},
"flow-node-inventory:idle-timeout": 300,
"opendaylight-flow-statistics:flow-statistics": {
"opendaylight-flow-statistics:duration":

{ "opendaylight-flow-statistics:second": 11, "opendaylight-flow-statistics:nanosecond": 725000000 }

,
"opendaylight-flow-statistics:byte-count": 0,
"opendaylight-flow-statistics:packet-count": 0
},
"flow-node-inventory:hard-timeout": 600,
"flow-node-inventory:table_id": 0,
"flow-node-inventory:id": "#UF$TABLE*0-1",
"flow-node-inventory:cookie": 1
}
],
"flow-node-inventory:id": 0
}
]
}

And I see "flow-node-inventory:id": "#UF$TABLE*0-1" and I get OSGi errors related to this too.

BR/Luis



 Comments   
Comment by Luis Gomez [ 18/Aug/14 ]

Please use this URL to configure the flow:

PUT http://<controller IP>:8080/restconf/config/opendaylight-inventory:nodes/node/openflow:1/table/0

BR/Luis

Comment by Vaclav Demcak [ 19/Aug/14 ]

It looks like same problem with MacAddress comparison as we've talked in bug https://bugs.opendaylight.org/show_bug.cgi?id=1088.
Could you please look at it ?

Comment by Luis Gomez [ 19/Aug/14 ]

Do you mean this is fix now? like I should not see any weird flow-id in operational?

Comment by Anil Vishnoi [ 04/Sep/14 ]

Hi Luis,

I believe this should be fixed with the latest controller code. This weird flow-is is something statistics manager creates to augment the flow that it got from switch but that flow doesn't exist in the config data store. To check whether specific flow existing in the config data store or not, it uses custom comparators. These custom comparators sometime can give you false positive results as well, like in the scenario you reported in this bug, if you notice the mac address in the config flow its in lower case string "ff:ff:29:01:19:61", but if you see the operational flow mac address, it is in upper case string "FF:FF:29:01:19:61". So till now we were using default equals method of MacAddress class, but that do case agnostic comparison and hence match fails. We recently fixed this and merged the patch.

So in conclusion, we can still see the flows with weird flow-id for following two cases, 1) when switch reported flow really don't exist in the config data store and this is valid case 2) when custom comparator fails in matching the flows.

Thanks
Anil

Comment by Abhijit Kumbhare [ 16/Sep/14 ]

Any update on this?

Comment by Luis Gomez [ 16/Sep/14 ]

I tested with latest controller yesterday and I still see the weird flow id in operational area after putting the flow in configuration.

BR/Luis

Comment by Luis Gomez [ 09/Nov/15 ]

Hi Anil, I think this never got fixed as I recently try flows with small case MAC or IPv6 and they generate alien ids.

Comment by Andrej Leitner [ 16/Aug/16 ]

The issue with alien flow id was resolved recently in OPNFLWPLUG-722.
Also problem with comparing IPv6 addresses in OPNFLWPLUG-736.
Closing bug after successful test with the input above and current codebase.

Generated at Wed Feb 07 20:31:57 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.