ctdb-server: Implement CTDB_CONTROL_START_IPREALLOCATE
authorVinit Agnihotri <vagnihotri@ddn.com>
Thu, 26 Oct 2023 06:55:17 +0000 (23:55 -0700)
committerVolker Lendecke <vl@samba.org>
Wed, 6 Mar 2024 06:05:38 +0000 (06:05 +0000)
commitb7cc56d22dbd117f4c32a794f3116a61b3c8a7ee
treefd3689b70f6b4e8d1dda7290c2fabf5d044078b5
parent9a20dfe97a03d772a5bb73e4becd7865acb3644f
ctdb-server: Implement CTDB_CONTROL_START_IPREALLOCATE

Trigger a "startipreallocate" event, but only if in RUNNING runstate.
"startipreallocate" is intended to allow an NFS server to be put into
grace on all nodes before any locks are released as part of releaseip
during failover.  If node A is leader and initiates a takeover run
then node B may be connected/active but may not have completed
startup.  In this case, the attempt to put NFS-Ganesha into grace on
node B will fail, startipreallocate will fail, and the node will be
banned.

Signed-off-by: Vinit Agnihotri <vagnihotri@ddn.com>
Reviewed-by: Martin Schwenke <mschwenke@ddn.com>
Reviewed-by: Volker Lendecke <vl@samba.org>
ctdb/include/ctdb_private.h
ctdb/server/ctdb_control.c
ctdb/server/ctdb_takeover.c
ctdb/tests/src/fake_ctdbd.c