packages: nfs-utils/nfs-utils.spec, nfs-utils/nfsfs.sysconfig, nfs-utils/bl...
baggins
baggins at pld-linux.org
Fri Oct 7 14:35:44 CEST 2011
Author: baggins Date: Fri Oct 7 12:35:44 2011 GMT
Module: packages Tag: HEAD
---- Log message:
- init script and options for blkmapd
---- Files affected:
packages/nfs-utils:
nfs-utils.spec (1.213 -> 1.214) , nfsfs.sysconfig (1.8 -> 1.9) , blkmapd.init (NONE -> 1.1) (NEW)
---- Diffs:
================================================================
Index: packages/nfs-utils/nfs-utils.spec
diff -u packages/nfs-utils/nfs-utils.spec:1.213 packages/nfs-utils/nfs-utils.spec:1.214
--- packages/nfs-utils/nfs-utils.spec:1.213 Fri Oct 7 14:20:23 2011
+++ packages/nfs-utils/nfs-utils.spec Fri Oct 7 14:35:38 2011
@@ -32,6 +32,7 @@
Source8: nfs.sysconfig
Source9: nfslock.sysconfig
Source10: nfsfs.sysconfig
+Source11: blkmapd.init
Patch0: %{name}-install.patch
Patch1: %{name}-statdpath.patch
Patch2: %{name}-subsys.patch
@@ -226,6 +227,7 @@
install %{SOURCE5} $RPM_BUILD_ROOT/etc/rc.d/init.d/idmapd
install %{SOURCE6} $RPM_BUILD_ROOT/etc/rc.d/init.d/gssd
install %{SOURCE7} $RPM_BUILD_ROOT/etc/rc.d/init.d/svcgssd
+install %{SOURCE11} $RPM_BUILD_ROOT/etc/rc.d/init.d/blkmapd
install %{SOURCE8} $RPM_BUILD_ROOT/etc/sysconfig/nfsd
install %{SOURCE9} $RPM_BUILD_ROOT/etc/sysconfig/nfslock
install %{SOURCE10} $RPM_BUILD_ROOT/etc/sysconfig/nfsfs
@@ -406,6 +408,9 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.214 2011/10/07 12:35:38 baggins
+- init script and options for blkmapd
+
Revision 1.213 2011/10/07 12:20:23 baggins
- merge -lock into -common
- package blkmapd in -clients subpackage
================================================================
Index: packages/nfs-utils/nfsfs.sysconfig
diff -u packages/nfs-utils/nfsfs.sysconfig:1.8 packages/nfs-utils/nfsfs.sysconfig:1.9
--- packages/nfs-utils/nfsfs.sysconfig:1.8 Sun Oct 3 01:08:20 2010
+++ packages/nfs-utils/nfsfs.sysconfig Fri Oct 7 14:35:38 2011
@@ -10,6 +10,12 @@
# Options for NFSv4 rpcsec_gss daemon
#RPCGSSOPTIONS=
+# Uncomment if you want to mount pNFS volumes
+#ENABLE_PNFS=yes
+
+# Options for pNFS blkmapd daemon
+#BLKMAPDOPTIONS=
+
# Space separated list of mount points that init script should not even
# try to umount because it will not work
# May contain regular expressions (ex. "/dev/union/.*")
================================================================
Index: packages/nfs-utils/blkmapd.init
diff -u /dev/null packages/nfs-utils/blkmapd.init:1.1
--- /dev/null Fri Oct 7 14:35:44 2011
+++ packages/nfs-utils/blkmapd.init Fri Oct 7 14:35:38 2011
@@ -0,0 +1,82 @@
+#!/bin/sh
+#
+# blkmapd Start up and shut down pNFS block layout mapping daemon
+#
+# chkconfig: 345 13 82
+# description: Starts the blkmapd daemon that performs device discovery \
+# and mapping for the parallel NFS (pNFS) block layout \
+# client [RFC5663].
+
+# Source function library.
+. /etc/rc.d/init.d/functions
+
+# Get network config
+. /etc/sysconfig/network
+
+# Check that networking is up.
+if is_yes "${NETWORKING}"; then
+ if [ ! -f /var/lock/subsys/network -a "$1" != stop -a "$1" != status ]; then
+ msg_network_down "pNFS block layout mapping daemon"
+ exit 1
+ fi
+else
+ exit 0
+fi
+
+# Get service config
+[ -f /etc/sysconfig/nfsfs ] && . /etc/sysconfig/nfsfs
+
+is_yes "${ENABLE_PNFS}" || exit 0
+
+start() {
+ # Check if the service is already running?
+ if [ -f /var/lock/subsys/blkmapd ]; then
+ msg_already_running "pNFS block layout mapping daemon"
+ return
+ fi
+
+ if ! grep -q rpc_pipefs /proc/mounts; then
+ modprobe sunrpc >/dev/null 2>&1
+ run_cmd "Mounting /var/lib/nfs/rpc_pipefs filesystem" \
+ mount -t rpc_pipefs rpc_pipefs /var/lib/nfs/rpc_pipefs
+ fi
+ msg_starting "pNFS block layout mapping daemon"
+ daemon /usr/sbin/blkmapd $BLKMAPDOPTIONS
+ RETVAL=$?
+ [ $RETVAL = 0 ] && touch /var/lock/subsys/blkmapd
+}
+
+stop() {
+ if [ ! -f /var/lock/subsys/blkmapd ]; then
+ msg_not_running "pNFS block layout mapping daemon"
+ return
+ fi
+
+ msg_stopping "pNFS block layout mapping daemon"
+ killproc blkmapd
+ rm -f /var/lock/subsys/blkmapd
+}
+
+# See how we were called.
+RETVAL=0
+case "$1" in
+ start)
+ start
+ ;;
+ stop)
+ stop
+ ;;
+ restart|reload)
+ stop
+ start
+ ;;
+ status)
+ status blkmapd
+ RETVAL=$?
+ ;;
+ *)
+ msg_usage "$0 {start|stop|restart|status}"
+ exit 1
+esac
+
+exit $RETVAL
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nfs-utils/nfs-utils.spec?r1=1.213&r2=1.214&f=u
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nfs-utils/nfsfs.sysconfig?r1=1.8&r2=1.9&f=u
More information about the pld-cvs-commit
mailing list