← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1658019] [NEW] ovs_lib.OVSBridge.delete_flows does not delete flows when called with no args

 

Public bug reported:

ovs_lib.OVSBridge.delete_flows does not delete flows when called with no
args, because in that case ovs-ofctl is called as "ovs-ofctl del-flows
<bridge-name> -" [2] and nothing is provided on stdin, which is not
interpreted by ovs-fctl as delete all flows [3].

The issue really is in OVSBridge.do_action_flows [4] and would impact
mod_flows as well.

This bug is currently silent because there does not seem to be any code
calling delete_flows() without arguments on an OVSBridge instance ;
existing code uses bridges inheriting from OpenFlowSwitchMixin which
shadow the problematic implementation in ovs_lib.OVSBridge.


[1] https://github.com/openstack/neutron/blob/master/neutron/agent/common/ovs_lib.py#L310
[2] https://github.com/openstack/neutron/blob/master/neutron/agent/common/ovs_lib.py#L302

[3] http://openvswitch.org/support/dist-docs/ovs-ofctl.8.txt

       [--bundle] del-flows switch
       [--bundle] [--strict] del-flows switch [flow]
       [--bundle] [--strict] del-flows switch - < file
              Deletes entries from switch's flow table.  With  only  a  switch
              argument,  deletes  all  flows.  Otherwise, deletes flow entries
              that match the specified flows.  With  --strict,  wildcards  are
              not treated as active for matching purposes.

[4]
https://github.com/openstack/neutron/blob/master/neutron/agent/common/ovs_lib.py#L296

** Affects: neutron
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1658019

Title:
  ovs_lib.OVSBridge.delete_flows does not delete flows when called with
  no args

Status in neutron:
  New

Bug description:
  ovs_lib.OVSBridge.delete_flows does not delete flows when called with
  no args, because in that case ovs-ofctl is called as "ovs-ofctl del-
  flows <bridge-name> -" [2] and nothing is provided on stdin, which is
  not interpreted by ovs-fctl as delete all flows [3].

  The issue really is in OVSBridge.do_action_flows [4] and would impact
  mod_flows as well.

  This bug is currently silent because there does not seem to be any
  code calling delete_flows() without arguments on an OVSBridge instance
  ; existing code uses bridges inheriting from OpenFlowSwitchMixin which
  shadow the problematic implementation in ovs_lib.OVSBridge.

  
  [1] https://github.com/openstack/neutron/blob/master/neutron/agent/common/ovs_lib.py#L310
  [2] https://github.com/openstack/neutron/blob/master/neutron/agent/common/ovs_lib.py#L302

  [3] http://openvswitch.org/support/dist-docs/ovs-ofctl.8.txt

         [--bundle] del-flows switch
         [--bundle] [--strict] del-flows switch [flow]
         [--bundle] [--strict] del-flows switch - < file
                Deletes entries from switch's flow table.  With  only  a  switch
                argument,  deletes  all  flows.  Otherwise, deletes flow entries
                that match the specified flows.  With  --strict,  wildcards  are
                not treated as active for matching purposes.

  [4]
  https://github.com/openstack/neutron/blob/master/neutron/agent/common/ovs_lib.py#L296

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1658019/+subscriptions


Follow ups