1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-11 05:18:09 +03:00
samba-mirror/ctdb/config/events.d/06.nfs

40 lines
625 B
Plaintext
Raw Normal View History

#!/bin/sh
# script to manage nfs in a clustered environment
[ -n "$CTDB_BASE" ] || \
export CTDB_BASE=$(cd -P $(dirname "$0") ; dirname "$PWD")
. $CTDB_BASE/functions
service_name="nfs"
loadconfig
ctdb_setup_service_state_dir
######################################################################
nfs_callout_pre ()
{
_event="$1"
shift
nfs_callout "${_event}-pre" "$@"
}
######################################################################
nfs_callout_init
ctdb_start_stop_service
is_ctdb_managed_service || exit 0
case "$1" in
takeip)
nfs_callout_pre "$@"
;;
releaseip)
nfs_callout_pre "$@"
;;
esac