[ovs-dev] [PATCH] OVN resource agent - make promotion synchronous
blp at ovn.org
Wed Jul 17 18:11:25 UTC 2019
On Tue, Jul 09, 2019 at 09:02:57AM +0200, Michele Baldessari wrote:
> Currently inside the ovsdb_server_promote() function we call 'promote_ovnnb'
> and 'promote_ovnsb' and then just record the new master state in the
> This creates a race because those two promote commands are asynchronous
> so when we exit the ovsdb_server_promote() function the underlying DBs
> are not guaranteed to be in master state. That means that clients might
> connect to an instance that is in read-only mode.
> We add a simple sleep loop where we wait for the underlying DB state to
> confirm the master state. We do not need to add a timeout loop because
> in case of an issue the resource timeout set within pacemaker will kick
> in and the resource agent script will be killed by pacemaker.
Thanks, applied to master.
More information about the dev