[Ocfs2-tools-devel] [PATCH 0/9] Add support for libdlmcontrol

Joel Becker joel.becker at oracle.com
Wed Aug 13 17:15:30 PDT 2008


ocfs2 must start recovery before the dlm completes its recovery.
Otherwise, the dlm might give out locks that belonged to the dead node
before ocfs2 has had a chance to replay its journal.

libdlmcontrol implements this ordering.  When ocfs2_controld sees a node
go down, it tells dlm_controld via dlmc_fs_notified().  dlm_controld
responds with success if it also has seen the node go down.  It
responds nonzero otherwise.  dlm_controld knows to wait until it has
seen the notification from ocfs2_controld.

The ocfs2_controld implementation is simple.  It first notifies ocfs2,
then sends the notification to dlm_controld.  ocfs2_controld will keep
resending it while dlm_controld responds in the negative.  When
dlm_controld finally gets the node down event, ocfs2_controld will stop
sending.  We keep such a simple busy-looping scheme because the
back-and-forth traffic actually means context switches and process
sleeping.

The code is available via git, in the 'libdlmcontrol' branch of the
ocfs2-tools git repository.

View:
http://oss.oracle.com/git/?p=ocfs2-tools.git;a=shortlog;h=libdlmcontrol
Pull:
git pull git://oss.oracle.com/git/ocfs2-tools.git libdlmcontrol





More information about the Ocfs2-tools-devel mailing list