diff mbox

[ovs-dev] ovn: fix data loss after an OVN-DB's backup node promote used pacemaker

Message ID 1483026478-16183-1-git-send-email-ligs@dtdream.com
State Accepted
Headers show

Commit Message

Guoshuai Li Dec. 29, 2016, 3:47 p.m. UTC
When master node shut down, VIP and OVNDB Master will go to other node.

On the node that will become the master, if the VIP starts upgrading
earlier than OVNDB promote, the ovsdb process in backup state will
reconnects to the VIP at its own node, and clears the data in the local
database in RPL_S_SEMEME_REQUESTED state. So the VIP started must be
after OVNDB promote.

See also:
http://clusterlabs.org/doc/en-US/Pacemaker/1.1-pcs/html/
Pacemaker_Explained/s-resource-ordering.html

Signed-off-by: Guoshuai Li <ligs@dtdream.com>
---
 Documentation/topics/integration.rst | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Andy Zhou Dec. 30, 2016, 11:35 p.m. UTC | #1
On Thu, Dec 29, 2016 at 7:47 AM, Guoshuai Li <ligs@dtdream.com> wrote:

> When master node shut down, VIP and OVNDB Master will go to other node.
>
> On the node that will become the master, if the VIP starts upgrading
> earlier than OVNDB promote, the ovsdb process in backup state will
> reconnects to the VIP at its own node, and clears the data in the local
> database in RPL_S_SEMEME_REQUESTED state. So the VIP started must be
> after OVNDB promote.
>
> See also:
> http://clusterlabs.org/doc/en-US/Pacemaker/1.1-pcs/html/
> Pacemaker_Explained/s-resource-ordering.html
>
> Signed-off-by: Guoshuai Li <ligs@dtdream.com>
>

Thanks for the patch.  Pushed.
Acked-by: Andy Zhou <azhou@ovn.org>
diff mbox

Patch

diff --git a/Documentation/topics/integration.rst b/Documentation/topics/integration.rst
index e3c2092..2f4043e 100644
--- a/Documentation/topics/integration.rst
+++ b/Documentation/topics/integration.rst
@@ -252,6 +252,6 @@  with the active server::
 
     $ pcs resource create VirtualIP ocf:heartbeat:IPaddr2 ip=x.x.x.x \
         op monitor interval=30s
-    $ pcs constraint order VirtualIP then ovndb_servers-master
-    $ pcs constraint colocation add master ovndb_servers-master with VirtualIP \
+    $ pcs constraint order promote ovndb_servers-master then VirtualIP
+    $ pcs constraint colocation add VirtualIP with master ovndb_servers-master \
         score=INFINITY