cluster/dlm/man dlm_create_lockspace.3 dlm_loc ...
CVSROOT: /cvs/cluster
Module name: cluster
Changes by: teigland at sourceware.org 2007-07-09 16:53:08
Modified files:
dlm/man : dlm_create_lockspace.3 dlm_lock.3 dlm_unlock.3
Log message:
Various small changes and additions. Munging formatting to avoid line wrapping on 80 columns.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/dlm/man/dlm_create_lockspace.3.diff?cvsroot=cluster&r1=1.2&r2=1.3
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/dlm/man/dlm_lock.3.diff?cvsroot=cluster&r1=1.2&r2=1.3
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/dlm/man/dlm_unlock.3.diff?cvsroot=cluster&r1=1.2&r2=1.3
dlm/man/dlm_create_lockspace.3 +4 -4
@@ -1,6 +1,6 @@ .TH DLM_CREATE_LOCKSPACE 3 "July 5, 2007" "libdlm functions" .SH NAME -dlm_create_lockspace, dlm_open_lockspace, dlm_close_lockspace, dlm_releas_lockspace \- manipulate DLM lockspaces +dlm_create_lockspace, dlm_open_lockspace, dlm_close_lockspace, dlm_release_lockspace \- manipulate DLM lockspaces .SH SYNOPSIS .nf #include <libdlm.h>
@@ -9,18 +9,18 @@ dlm_lshandle_t dlm_new_lockspace(const char *name, mode_t mode, uint32_t flags); dlm_lshandle_t dlm_open_lockspace(const char *name); int dlm_close_lockspace(dlm_lshandle_t lockspace); -int dlm_release_lockspace(const char *name, dlm_lshandle_t lockspace, int force) +int dlm_release_lockspace(const char *name, dlm_lshandle_t lockspace, int force); .fi .SH DESCRIPTION The DLM allows locks to be partitioned into "lockspaces", and these can be manipulated by userspace calls. It is possible (though not recommended) for an application to have multiple lockspaces open at one time. -Many of the DLM calls work on the "default" lockspace, which should be fine for most users. The calls with _ls_ in them allow you to isolate your application from all others running in the cluster. Remember, lockspaces are a cluster-wide resource, so if you create a lockspace called "myls" it will share locks with a lockspace called "myls" on all nodes. These calls allow users to create & remove lockspaces, and users to connecto to existing lockspace to store their locks there. +Many of the DLM calls work on the "default" lockspace, which should be fine for most users. The calls with _ls_ in them allow you to isolate your application from all others running in the cluster. Remember, lockspaces are a cluster-wide resource, so if you create a lockspace called "myls" it will share locks with a lockspace called "myls" on all nodes. These calls allow users to create & remove lockspaces, and users to connect to existing lockspace to store their locks there. .PP .SS dlm_lshandle_t dlm_create_lockspace(const char *name, mode_t mode); .br -This creates a lockspace called <name> and the mode of the file user to access it will be <mode> (subject to umask as usual). The lockspace must not already exist on this node, if it does -1 will be returned and errno will be set to EEXIST. If you really want to use this lockspace you can then user dlm_open_lockspace() below. The name is the name of a misc device that will be created in /dev/misc. +This creates a lockspace called <name> and the mode of the file user to access it will be <mode> (subject to umask as usual). The lockspace must not already exist on this node, if it does -1 will be returned and errno will be set to EEXIST. If you really want to use this lockspace you can then use dlm_open_lockspace() below. The name is the name of a misc device that will be created in /dev/misc. .br On success a handle to the lockspace is returned, which can be used to pass into subsequent dlm_ls_lock/unlock calls. Make no assumptions as to the content of this handle as it's content may change in future. .br
dlm/man/dlm_lock.3 +83 -75
215 lines not on this page · raw message
dlm/man/dlm_unlock.3 +18 -13
@@ -26,15 +26,16 @@ .B flags flags affecting the unlock operation: .nf - LKF_CANCEL Cancel a pending lock or conversion. - This returns the lock to it's - previously granted mode (in case of a - conversion) or unlocks it (in case of a waiting lock). - LKF_IVVALBLK Invalidate value block + LKF_CANCEL Cancel a pending lock or conversion. + This returns the lock to it's previously + granted mode (in case of a conversion) or + unlocks it (in case of a waiting lock). + LKF_IVVALBLK Invalidate value block + LKF_FORCEUNLOCK Unlock the lock even if it's waiting. .fi .PP .B lksb -LKSB to return status and value block information. +LKSB to return status and value block information. .PP .B astarg New parameter to be passed to the completion AST.
@@ -50,13 +51,17 @@ 0 is returned if the call completed successfully. If not, -1 is returned and errno is set to one of the following: .PP .nf -EINVAL An invalid parameter was passed to the call (eg bad lock mode or flag) -EINPROGRESS The lock is already being unlocked -EBUSY The lock is currently being locked or converted -ENOTEMPTY An attempt to made to unlock a parent lock that still has child locks. -ECANCEL A lock conversion was successfully cancelled -EUNLOCK An unlock operation completed successfully (sb_status only) -EFAULT The userland buffer could not be read/written by the kernel +EINVAL An invalid parameter was passed to the call (eg bad + lock mode or flag) +EINPROGRESS The lock is already being unlocked +EBUSY The lock is currently being locked or converted +ENOTEMPTY An attempt to made to unlock a parent lock that still has + child locks. +ECANCEL A lock conversion was successfully cancelled +EUNLOCK An unlock operation completed successfully + (sb_status only) +EFAULT The userland buffer could not be read/written by the + kernel .fi If an error is returned in the AST, then lksb.sb_status is set to the one of the above numbers instead of zero. .SH EXAMPLE