[ovs-dev] [ovs-dev, v7, 3/6, ovn-controller] Make flow table persistent

Ryan Moats rmoats at us.ibm.com
Thu Feb 25 21:59:46 UTC 2016


Ben Pfaff <blp at ovn.org> wrote on 02/25/2016 03:49:37 PM:

> From: Ben Pfaff <blp at ovn.org>
> To: Ryan Moats/Omaha/IBM at IBMUS
> Cc: dev at openvswitch.org
> Date: 02/25/2016 03:49 PM
> Subject: Re: [ovs-dev,v7,3/6,ovn-controller] Make flow table persistent
>
> On Thu, Feb 25, 2016 at 03:38:10PM -0600, Ryan Moats wrote:
> > Ben Pfaff <blp at ovn.org> wrote on 02/25/2016 03:19:32 PM:
> >
> > > From: Ben Pfaff <blp at ovn.org>
> > > To: Ryan Moats/Omaha/IBM at IBMUS
> > > Cc: dev at openvswitch.org
> > > Date: 02/25/2016 03:20 PM
> > > Subject: Re: [ovs-dev,v7,3/6,ovn-controller] Make flow table
persistent
> > >
> > > On Fri, Feb 19, 2016 at 11:25:09AM -0600, Ryan Moats wrote:
> > > > From: RYAN D. MOATS <rmoats at us.ibm.com>
> > > >
> > > > This is a prerequisite for incremental processing.
> > > >
> > > > Signed-off-by: RYAN D. MOATS <rmoats at us.ibm.com>
> > >
> > > This appears to make ofctrl_add_flow() into an O(n) operation in the
> > > number of flows already in the flow table.  That shouldn't be
necessary?
> > >
> >
> > Han and I had this discussion on v6 of the patch set in the thread
starting
> > at http://openvswitch.org/pipermail/dev/2016-February/thread.html#66312
> >
> > My ending conclusion still applies - I don't like it, but I've not come
> > up with a better solution - if somebody can think of a better way to do
> > this, I'm all ears...
>
> Clearly we need to delete and replace an old flow, the question is why
> that's being done by iterating over all the flows in O(n) instead of
> hashing to find it in O(1).
>

Doh! /me headdesks with the comment "why didn't I think of that..."

Would a hash that covers table/priority be enough or would it be better to
have two hashes - one that covers table/priority/match set and the other
that covers table/priority/ofpacts set.

Ryan



More information about the dev mailing list