SFC delete port chain failed

Sa Pham saphi070 at gmail.com
Thu Apr 4 15:39:19 UTC 2019


As your list of flows in br-int bridge. I don’t see any flow relevant sfc. So maybe your openvswitch-agent can not load sfc extension sucessful. 
Please check log of ovs-first. If right, there is a message like “ loaded extensions [‘sfc’]”. 
If the list extensions above is None. So the extension is not loaded. 

Sa Pham Dang
Cloud RnD Team - VCCLOUD
Phone: 0986849582
Skype: great_bn

> On Apr 5, 2019, at 12:28 AM, Navdeep Uniyal <navdeep.uniyal at bristol.ac.uk> wrote:
> 
> Hi Pham,
> 
> I am able to create the port chain now. However, I cannot see it running.
> My scenario is simple with 3 VMs:  VM1---<net1>--VM2--<net2>--VM3 (Please note: it is not working with single network as well)
>  
> I followed the following steps:
> openstack port create --no-security-group --disable-port-security --network sfcnet1 net1p1vm1
> openstack port create --no-security-group --disable-port-security --network sfcnet1 net1p2vm2
> openstack port create --no-security-group --disable-port-security --network sfcnet2 net2p1vm2
> openstack port create --no-security-group --disable-port-security --network sfcnet2 net2p2vm3
>  
> openstack server create --nic port-id=net1p1vm1 --image cloudUb16 --flavor m1.large vm1
> openstack server create --nic port-id=net1p2vm2 --nic port-id=net2p1vm2 --image cloudUb16 --flavor m1.large vm2
> openstack server create --nic port-id=net2p2vm3 --image cloudUb16 --flavor m1.large vm3
>  
> openstack sfc port pair create --ingress net1p1vm1 --egress net1p1vm1 PoP1
> openstack sfc port pair create --ingress net1p2vm2 --egress net2p1vm2 PoP2
> openstack sfc port pair create --ingress net2p2vm3 --egress net2p2vm3 PoP3
>  
> openstack sfc port pair group create --port-pair PoP1 PPGp1
> openstack sfc port pair group create --port-pair PoP2 PPGp2
> openstack sfc port pair group create --port-pair PoP3 PPGp3
>  
> openstack sfc flow classifier create --protocol icmp --ethertype IPv4 --source-ip-prefix 10.10.10.6/32 --destination-ip-prefix 20.20.20.9/32 --logical-source-port net1p1vm1 --logical-destination-port net2p2vm3 FCx
>  
> openstack sfc port chain create --flow-classifier FCx --port-pair-group PPGp1 --port-pair-group PPGp2 --port-pair-group PPGp3 PChain
>  
> sudo ovs-ofctl dump-flows br-int
> cookie=0x4ae16a9e2f1a7bee, duration=101217.953s, table=0, n_packets=268367, n_bytes=445608419, priority=3,in_port="int-br-provider",vlan_tci=0x0000/0x1fff actions=mod_vlan_vid:2,resubmit(,60)
> cookie=0x4ae16a9e2f1a7bee, duration=1415.837s, table=0, n_packets=0, n_bytes=0, priority=3,in_port="int-br-pr6e8b65",dl_vlan=1000 actions=mod_vlan_vid:9,resubmit(,60)
> cookie=0x4ae16a9e2f1a7bee, duration=1215.812s, table=0, n_packets=0, n_bytes=0, priority=3,in_port="int-br-pr6e8b65",dl_vlan=500 actions=mod_vlan_vid:10,resubmit(,60)
> cookie=0x4ae16a9e2f1a7bee, duration=101218.540s, table=0, n_packets=0, n_bytes=0, priority=2,in_port="int-br-pr6e8b65" actions=drop
> cookie=0x4ae16a9e2f1a7bee, duration=101218.531s, table=0, n_packets=19, n_bytes=1634, priority=2,in_port="int-br-provider" actions=drop
> cookie=0x4ae16a9e2f1a7bee, duration=101218.591s, table=0, n_packets=1532, n_bytes=106439, priority=0 actions=resubmit(,60)
> cookie=0x4ae16a9e2f1a7bee, duration=101218.592s, table=23, n_packets=0, n_bytes=0, priority=0 actions=drop
> cookie=0x4ae16a9e2f1a7bee, duration=101218.590s, table=24, n_packets=0, n_bytes=0, priority=0 actions=drop
> cookie=0x4ae16a9e2f1a7bee, duration=101218.591s, table=60, n_packets=402197, n_bytes=455450343, priority=3 actions=NORMAL
>  
> I cannot see any relevant flow entries and the port chain is not working.
>  
> Kind Regards,
> Navdeep
>  
> From: Sa Pham <saphi070 at gmail.com> 
> Sent: 04 April 2019 15:40
> To: Navdeep Uniyal <navdeep.uniyal at bristol.ac.uk>
> Cc: openstack at lists.openstack.org
> Subject: Re: SFC delete port chain failed
>  
> What is the version of Openstack and networking-sfc you are running?
>  
> On Thu, Apr 4, 2019 at 11:38 PM Navdeep Uniyal <navdeep.uniyal at bristol.ac.uk> wrote:
> In addition to the following logs, I have attached the logs I captured while creating the port chain.
>  
> From: Navdeep Uniyal <navdeep.uniyal at bristol.ac.uk> 
> Sent: 04 April 2019 12:06
> To: openstack at lists.openstack.org
> Subject: SFC delete port chain failed
>  
> Dear All,
>  
> I am facing errors while creating/deleting the SF Chain:
>  
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager [req-d03ef918-2314-4728-bb8b-c5670b4b9da1 c8c777caa52b45649a6c312b38e81956 1c915b508cfa4c799389bf354fceb056 - default default] 'PortChainContext' object has no attribute 'session': AttributeError: 'PortChainContext' object has no attribute 'session'
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager Traceback (most recent call last):
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/driver_manager.py", line 101, in _call_drivers
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     getattr(driver.obj, method_name)(context)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/lib/python2.7/dist-packages/oslo_log/helpers.py", line 67, in wrapper
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     return method(*args, **kwargs)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/drivers/ovs/driver.py", line 887, in delete_port_chain
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     self._delete_portchain_path(context, port_chain)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/lib/python2.7/dist-packages/oslo_log/helpers.py", line 67, in wrapper
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     return method(*args, **kwargs)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/drivers/ovs/driver.py", line 594, in _delete_portchain_path
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     port_chain['flow_classifiers']
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/drivers/ovs/driver.py", line 577, in _delete_path_node_flowrule
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     context, node, port, pc_corr, fc_ids)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/drivers/ovs/driver.py", line 568, in _delete_path_node_port_flowrule
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     self._delete_agent_fdb_entries(context, flow_rule)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/drivers/ovs/driver.py", line 192, in _delete_agent_fdb_entries
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     self._call_on_l2pop_driver(context, "remove_fdb_entries", flow_rule)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/drivers/ovs/driver.py", line 170, in _call_on_l2pop_driver
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     pop_ports = self._get_remote_pop_ports(context, flow_rule)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/lib/python2.7/dist-packages/oslo_log/helpers.py", line 67, in wrapper
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     return method(*args, **kwargs)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/drivers/ovs/driver.py", line 133, in _get_remote_pop_ports
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     next_hop['net_uuid'])
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager   File "/usr/lib/python2.7/dist-packages/neutron/plugins/ml2/drivers/l2pop/db.py", line 152, in get_agent_network_active_port_count
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager     query = context.session.query(models_v2.Port)
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager AttributeError: 'PortChainContext' object has no attribute 'session'
> 2019-04-04 12:00:10.186 182062 ERROR networking_sfc.services.sfc.driver_manager
> 2019-04-04 12:00:10.188 182062 ERROR networking_sfc.services.sfc.driver_manager [req-d03ef918-2314-4728-bb8b-c5670b4b9da1 c8c777caa52b45649a6c312b38e81956 1c915b508cfa4c799389bf354fceb056 - default default] SFC driver 'ovs' failed in delete_port_chain
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin [req-d03ef918-2314-4728-bb8b-c5670b4b9da1 c8c777caa52b45649a6c312b38e81956 1c915b508cfa4c799389bf354fceb056 - default default] delete_port_chain failed.: SfcDriverError: delete_port_chain failed.
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin Traceback (most recent call last):
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/plugin.py", line 99, in delete_port_chain
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin     self.driver_manager.delete_port_chain(pc_context)
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/driver_manager.py", line 130, in delete_port_chain
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin     self._call_drivers("delete_port_chain", context)
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/driver_manager.py", line 113, in _call_drivers
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin     method=method_name
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin SfcDriverError: delete_port_chain failed.
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin
> 2019-04-04 12:00:10.189 182062 ERROR networking_sfc.services.sfc.plugin [req-d03ef918-2314-4728-bb8b-c5670b4b9da1 c8c777caa52b45649a6c312b38e81956 1c915b508cfa4c799389bf354fceb056 - default default] Delete port chain failed, portchain 'b8bba555-e22b-46ee-8267-dc8babe07ef2': SfcDriverError: delete_port_chain failed.
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource [req-d03ef918-2314-4728-bb8b-c5670b4b9da1 c8c777caa52b45649a6c312b38e81956 1c915b508cfa4c799389bf354fceb056 - default default] delete failed: No details.: SfcDriverError: delete_port_chain failed.
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource Traceback (most recent call last):
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/neutron/api/v2/resource.py", line 98, in resource
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     result = method(request=request, **args)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/neutron/api/v2/base.py", line 551, in delete
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     return self._delete(request, id, **kwargs)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/neutron/db/api.py", line 91, in wrapped
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     setattr(e, '_RETRY_EXCEEDED', True)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 220, in __exit__
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     self.force_reraise()
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 196, in force_reraise
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     six.reraise(self.type_, self.value, self.tb)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/neutron/db/api.py", line 87, in wrapped
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     return f(*args, **kwargs)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/oslo_db/api.py", line 147, in wrapper
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     ectxt.value = e.inner_exc
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 220, in __exit__
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     self.force_reraise()
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 196, in force_reraise
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     six.reraise(self.type_, self.value, self.tb)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/oslo_db/api.py", line 135, in wrapper
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     return f(*args, **kwargs)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/neutron/db/api.py", line 126, in wrapped
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     LOG.debug("Retry wrapper got retriable exception: %s", e)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 220, in __exit__
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     self.force_reraise()
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 196, in force_reraise
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     six.reraise(self.type_, self.value, self.tb)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/neutron/db/api.py", line 122, in wrapped
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     return f(*dup_args, **dup_kwargs)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/neutron/api/v2/base.py", line 579, in _delete
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     obj_deleter(request.context, id, **kwargs)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/lib/python2.7/dist-packages/oslo_log/helpers.py", line 67, in wrapper
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     return method(*args, **kwargs)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/plugin.py", line 104, in delete_port_chain
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     portchain_id)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 220, in __exit__
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     self.force_reraise()
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 196, in force_reraise
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     six.reraise(self.type_, self.value, self.tb)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/plugin.py", line 99, in delete_port_chain
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     self.driver_manager.delete_port_chain(pc_context)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/driver_manager.py", line 130, in delete_port_chain
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     self._call_drivers("delete_port_chain", context)
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource   File "/usr/local/lib/python2.7/dist-packages/networking_sfc/services/sfc/driver_manager.py", line 113, in _call_drivers
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource     method=method_name
> 2019-04-04 12:00:10.191 182062 ERROR neutron.api.v2.resource SfcDriverError: delete_port_chain failed.
>  
> Due to this error, I am unable to delete the existing chain. I am using openstack queens Full installation. Please let me know how to triage this issue.
>  
> Kind Regards,
> Navdeep
>  
> 
>  
> --
> Sa Pham Dang
> Master Student - Soongsil University
> Kakaotalk: sapd95
> Skype: great_bn
>  
>  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-discuss/attachments/20190405/6562eed2/attachment-0001.html>


More information about the openstack-discuss mailing list