On Mon, Apr 25, 2022 at 8:23 PM 刘梦馨 <[email protected]> wrote:
>
>
> Hi, Han
>
> I just found flow-restore-wait option in ovs-vswitchd.conf.db(5) can we
just use it to simulate ovn-ofctrl-wait-before-clear to reduce upgrade
downtime in old version ovn

It is possible, but depending on your use cases. There are some major
differences between the two approaches:

1. With ovn-ofctrl-wait-before-clear, we don't need to restart OVS when
upgrading ovn-controller, while flow-restore-wait works only with OVS
restart. This means the operations for upgrading is much more complicated
using flow-restore-wait. With ovn-ofctrl-wait-before-clear there is no
special steps required during ovn-controller upgrade.
2. flow-restore-wait is more about keeping the old datapath flows untouched
during the upgrade, but the ovs-vswitchd user space flows won't work, so
this only works for packets that doesn't need any slow-path handling. For
OVN this is not always true, e.g. ARP responders, ICMP handling, etc. would
require ovs-vswitchd to participate. If those are unimportant during the
upgrade (possibly very long due to large scale), then it is fine.
3. flow-restore-wait is particularly useful when packet miss (and upcall to
slow path) is not acceptable during OVS/ovn-controller upgrade (probably
for traffic that can't even tolerate the short latency increase during the
rare situation of an OVS/OVN upgrade). ovn-ofctrl-wait-before-clear doesn't
cover such use cases (but not conflict with flow-restore-wait, of course).

Thanks,
Han

>
> On Tue, 19 Apr 2022 at 03:23, Han Zhou <[email protected]> wrote:
>>
>> Whenever OpenFlow connection between ovn-controller and OVS is
>> connected/reconnected, typically during ovn-controller/OVS
>> restart/upgrade, ovn-controller would:
>> 1. clears all the existing flows after the initial hand-shaking
>> 2. compute the new flows
>> 3. install the new flows to OVS.
>>
>> In large scale environments when there are a big number of flows
>> needs to be computed by ovn-controller, the step 2 and 3 above can take
>> very long time (from seconds to minutes, depending on the scale and
>> topology), which would cause a data plane down time.
>>
>> This series solves the problem: patches 1 and 2 avoids the down time
introduced
>> by step 2; patches 3 and 4 avoids the down time introduced by step 3.
>>
>> A test shows zero ping loss (with 0.1s interval), while without the
patches it
>> was 100% ping drops during ~13s.
>>
>> Han Zhou (4):
>>   ofctrl: Wakeup when entering S_UPDATE_FLOWS.
>>   ofctrl: Support ovn-ofctrl-wait-before-clear to reduce down time
>>     during upgrade.
>>   ofctrl.c: Include group changes to bundle.
>>   ofctrl.c: Use bundle to avoid data plane downtime during the first
>>     flow installation.
>>
>>  controller/ofctrl.c             | 275 +++++++++++++++++++++-----------
>>  controller/ofctrl.h             |   4 +-
>>  controller/ovn-controller.8.xml |  34 ++++
>>  controller/ovn-controller.c     |   6 +-
>>  tests/ovn-controller.at         |  52 ++++++
>>  5 files changed, 275 insertions(+), 96 deletions(-)
>>
>> --
>> 2.30.2
>>
>> _______________________________________________
>> dev mailing list
>> [email protected]
>> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>
>
>
> --
> 刘梦馨
> Blog: http://oilbeater.com
> Weibo: @oilbeater
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to