[ovs-dev] [PATCH v3] Scanning only changed entries in the ovnsb

Hui Kang kangh at us.ibm.com
Tue Jul 26 20:38:29 UTC 2016



Russell Bryant <russell at ovn.org> wrote on 07/26/2016 03:50:44 PM:

> From: Russell Bryant <russell at ovn.org>
> To: Hui Kang/Watson/IBM at IBMUS
> Cc: Ben Pfaff <blp at ovn.org>, Hui Kang <hkang.sunysb at gmail.com>, ovs
> dev <dev at openvswitch.org>
> Date: 07/26/2016 03:51 PM
> Subject: Re: [ovs-dev] [PATCH v3] Scanning only changed entries in the
ovnsb
>
> On Tue, Jul 26, 2016 at 3:44 PM, Hui Kang <kangh at us.ibm.com> wrote:
>
>
> "dev" <dev-bounces at openvswitch.org> wrote on 07/26/2016 02:20:27 PM:
>
> > From: Ben Pfaff <blp at ovn.org>
> > To: Hui Kang <hkang.sunysb at gmail.com>
> > Cc: dev at openvswitch.org
> > Date: 07/26/2016 02:20 PM
> > Subject: Re: [ovs-dev] [PATCH v3] Scanning only changed entries in the
> ovnsb
> > Sent by: "dev" <dev-bounces at openvswitch.org>
> >
> > On Sat, Jul 16, 2016 at 11:58:25PM -0400, Hui Kang wrote:
> > > Improve performance by scanning only changed port binding entries
> > > when determining whether to mark the logical switch port up or
> > > down
> > >
> > > Signed-off-by: Hui Kang <kangh at us.ibm.com>
> >
> > Won't this skip an initial round of updates at ovn-northd startup time?
> > (Certainly ovn-northd might get killed and restarted occasionally,
> > especially if we're doing failover to a second host.)
>
> Hi, Ben,
> After second thought, I think skipping the initial round is the purpose
of
> this patch.
>
> ovsdb_idl_create(ovsdb) copies the the Port_binding table from southbound
> database whenever ovn-northd gets started. In this case, the northbound
> DB and southbound db are synced. In ovnsb_db_run, ovn-northd only gets
> notified when there is change to the Chassis column [1]. Therefore,
> ovnsb_db_run should only look the entry that are changed with its Chassis
> column. There is no need to initialize by iterating every entry in the
> Port_binding table. Please correct me if my understanding is incorrect.
> Thanks.
>
> What if the Chassis column changes in some Port_Binding records
> while ovn-northd isn't running?

Hi, Russel,
Thanks for correcting me. In this case, initialization is necessary each
time
ovn-northd restarts.

- Hui

>
> --
> Russell Bryant



More information about the dev mailing list