[OPNFLWPLUG-894] Mismatch between Operational Datastore and the actual Flow Entry Created: 22/May/17  Updated: 27/Sep/21  Resolved: 15/Jun/17

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

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

Operating System: All
Platform: All


Attachments: File CSIT log.html.gz     Text File Operational_datastore_vlanpcp.txt     File log.html.gz    
Issue Links:
Duplicate
is duplicated by OPNFLWPLUG-893 Mismatch between Operational Datastor... Resolved
External issue ID: 8527

 Description   

While VTN Testing, We have identified that for some actions the flow entries are installed correctly on the OpenFlow switch. But, the operational datastore does not reflect the correct action for the flow entry. It has been noted for a few actions specifically

a. action: set vlan pcp

Flow Entry on Switch
cookie=0x7f5600000000007b, duration=0.193s, table=0, n_packets=0, n_bytes=0, send_flow_rem priority=13,ip,in_port=1,dl_vlan=200,dl_src=6e:30:ce:63:16:4b,dl_dst=26:a1:54:78:73:70,nw_src=10.0.0.1,nw_dst=10.0.0.5 actions=set_field:6->vlan_pcp,output:3

Operational DS contents for the switch

  • Added as attachment txt file

Similar problems seen when using flow entries for setting vlan id, set-dl-
src-action, set-dl-dst, set-nw-src, set-nw-tos, set-tp-src, set-tp-dst.

  • Please see other attachment where entries are collected from every switch as well as the operational DS contens.

b. POST /restconf/operations/sal-flow:add-flow
Body:

{
"input": {
"node": "/opendaylight-inventory:nodes/opendaylight-inventory:node[opendaylight-inventory:id=\"openflow:1\"]",
"table_id": 0,
"priority": 10,
"idle-timeout": 0,
"hard-timeout": 0,
"match": {
"ip-match":

{ "ip-protocol": 6 }

,
"ethernet-match": {
"ethernet-type":

{ "type": 2048 }

}
}
"instructions": {
"instruction": [
{
"order": 0,
"apply-actions": {
"action": [
{
"set-vlan-id-action":

{ "vlan-id": 10 }

,
"order": 0
},
{
"order": 1,
"set-vlan-pcp-action":

{ "vlan-pcp": 5 }

},
{
"order": 2,
"set-dl-src-action":

{ "address": "00:aa:bb:cc:dd:ee" }

},
{
"set-dl-dst-action":

{ "address": "00:11:22:33:44:55" }

,
"order": 3
},
{
"set-nw-src-action":

{ "ipv4-address": "10.20.30.40/32" }

,
"order": 4
},
{
"order": 5,
"set-nw-dst-action":

{ "ipv4-address": "192.168.1.2/32" }

},
{
"order": 6,
"set-nw-tos-action":

{ "tos": 252 }

},
{
"order": 7,
"set-tp-src-action":

{ "ip-protocol": 6, "port": 32000 }

},
{
"order": 8,
"set-tp-dst-action":

{ "port": 333, "ip-protocol": 6 }

}
]
}
}
]
}
}
}

The flow is installed correctly.

      • s1 ------------------------------------------------------------------------
        NXST_FLOW reply (xid=0x4):
        cookie=0x0, duration=54.583s, table=0, n_packets=0, n_bytes=0, idle_age=54, \ priority=10,tcp \ actions=mod_vlan_vid:10,mod_vlan_pcp:5,\
        mod_dl_src:00:aa:bb:cc:dd:ee,mod_dl_dst:00:11:22:33:44:55,\
        mod_nw_src:10.20.30.40,mod_nw_dst:192.168.1.2,\
        mod_nw_tos:252,mod_tp_src:32000,mod_tp_dst:333

However, action information for the flow entry in operational DS is wrong due to the bug.

  • set-nw-dst-action doesn't have the value of MAC address.
  • Other action information doesn't exist in the operational DS.

GET /restconf/operational/opendaylight-inventory:nodes/node/openflow:1/table/0
Result:

{
"flow-node-inventory:table": [
{
"id": 0,
"flow": [
{
"id": "#UF$TABLE*0-5",
"priority": 10,
"table_id": 0,
"opendaylight-flow-statistics:flow-statistics": {
"duration":

{ "second": 244, "nanosecond": 397000000 }

,
"byte-count": 0,
"packet-count": 0
},
"idle-timeout": 0,
"match": {
"ip-match":

{ "ip-protocol": 6 }

,
"ethernet-match": {
"ethernet-type":

{ "type": 2048 }

}
},
"hard-timeout": 0,
"cookie": 0,
"instructions": {
"instruction": [
{
"order": 0,
"apply-actions": {
"action": [
{
"order": 0,
"set-nw-dst-action": {}
}
]
}
}
]
}
}
],
"opendaylight-flow-table-statistics:flow-table-statistics":

{ "active-flows": 0, "packets-looked-up": 10464, "packets-matched": 10464 }

}
]
}



 Comments   
Comment by Venkatrangan Govindarajan [ 22/May/17 ]

Attachment Operational_datastore_vlanpcp.txt has been added with description: vlan_pcp operational datastore contents

Comment by Venkatrangan Govindarajan [ 22/May/17 ]

Attachment log.html.gz has been added with description: CSIT run with additional information (inventory table from operational DS)

Comment by Venkatrangan Govindarajan [ 22/May/17 ]

The problems are seen in OpenFlow 10. We feel that there is no implementation to convert OF action to SAL action for certain actions.

Comment by Tomas Slusny [ 23/May/17 ]

Can you also provide karaf.log with org.opendaylight.openflowplugin.impl set to DEBUG please? Or did you saw any Deserialization failed messages in your karaf log?

Comment by Tomas Slusny [ 23/May/17 ]

I found the issue, we are deserializing everything correctly, but we are missing some convertors. I will write them and hopefully I will have fix ready today.

Comment by Tomas Slusny [ 23/May/17 ]

GERRIT: https://git.opendaylight.org/gerrit/#/c/57680/

Comment by Y Ananth [ 12/Jun/17 ]

I have tested it manually and the fix is working.

Comment by Y Ananth [ 15/Jun/17 ]

Attachment CSIT log.html.gz has been added with description: CSIT job with vlan pcp failure

Comment by Y Ananth [ 15/Jun/17 ]

I have found in CSIT job that some cases are working like set-dl-src-action, set-nw-src, set-nw-dst, set-nw-tos.

But vlan pcp is not reflecting in operational datastore. Tomas, please look into this.

I need to test some cases manually like set-vlan-id, set-dl-dst, set-tp-src, set-tp-dst and I will get back to you.

I have attached the corresponding CSIT job for reference.

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