From 92c20eda4976fbb0b61ff8fb7819169fc4dd83c61155e167c728aea27c5af272 Mon Sep 17 00:00:00 2001 From: OBS User unknown Date: Mon, 17 Nov 2008 16:32:01 +0000 Subject: [PATCH] OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/nfs-utils?expand=0&rev=39 --- modprobe.nfs-utils | 3 +++ nfs-utils.changes | 13 +++++++++++++ nfs-utils.spec | 17 ++++++++++++++++- nfsserver.init | 7 +++++-- 4 files changed, 37 insertions(+), 3 deletions(-) create mode 100644 modprobe.nfs-utils diff --git a/modprobe.nfs-utils b/modprobe.nfs-utils new file mode 100644 index 0000000..23dc787 --- /dev/null +++ b/modprobe.nfs-utils @@ -0,0 +1,3 @@ +install sunrpc /sbin/modprobe --ignore-install sunrpc ; grep '^sunrpc' /etc/sysctl.conf | sysctl -q -e -n -p - +install lockd /sbin/modprobe --ignore-install lockd ; grep '^fs.nfs.n.m' /etc/sysctl.conf | sysctl -q -e -n -p - +install nfs /sbin/modprobe --ignore-install nfs ; grep -E '^fs.nfs.(nfs|idmap)' /etc/sysctl.conf | sysctl -q -e -n -p - diff --git a/nfs-utils.changes b/nfs-utils.changes index 1c045a0..22be1a8 100644 --- a/nfs-utils.changes +++ b/nfs-utils.changes @@ -1,3 +1,16 @@ +------------------------------------------------------------------- +Fri Nov 14 03:19:34 CET 2008 - nfbrown@suse.de + +- nfsserver.init + * don't set version if nfsd already running. + doing that causes unhelpful error when trying + to start nfsserver when it is already running. + (bnc#427330) +- modprobe.nfs-utils + * arrange that when various nfs modules are loaded + the relevant values from /etc/sysctl.conf are set + (bnc#431306, bnc#443118) + ------------------------------------------------------------------- Fri Nov 7 04:32:51 CET 2008 - nfbrown@suse.de diff --git a/nfs-utils.spec b/nfs-utils.spec index 410ed2a..2d09a5f 100644 --- a/nfs-utils.spec +++ b/nfs-utils.spec @@ -27,7 +27,7 @@ BuildRequires: libevent Url: http://nfs.sourceforge.net Summary: Support Utilities for Kernel nfsd Version: 1.1.3 -Release: 9 +Release: 10 Group: Productivity/Networking/NFS License: GPL v2 or later BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -45,6 +45,7 @@ Source7: fw-client Source8: fw-server Source9: mkinitrd-setup.sh Source10: mkinitrd-boot.sh +Source11: modprobe.nfs-utils Patch0: nfs-utils-1.0.7-bind-syntax.patch Patch1: nfs-utils-1.1.2-try-before-mount.patch Patch2: nfs-utils-1.1.2-connect-UDP.patch @@ -177,6 +178,8 @@ install -m 0644 %{SOURCE8} ${RPM_BUILD_ROOT}/etc/sysconfig/SuSEfirewall2.d/servi install -d $RPM_BUILD_ROOT/lib/mkinitrd/scripts install -m 755 %{S:9} $RPM_BUILD_ROOT/lib/mkinitrd/scripts/setup-nfs.sh install -m 755 %{S:10} $RPM_BUILD_ROOT/lib/mkinitrd/scripts/boot-nfs.sh +install -d $RPM_BUILD_ROOT/etc/modprobe.d +install -m 644 ${S:11} $RPM_BUILD_ROOT/etc/modprobe.d/nfs-utils %clean rm -rf $RPM_BUILD_ROOT @@ -210,6 +213,8 @@ rm -rf $RPM_BUILD_ROOT %defattr(-,root,root) %config /etc/init.d/nfs %config /etc/idmapd.conf +%dir /etc/modprobe.d +/etc/modprobe.d/nfs-utils %dir /lib/mkinitrd %dir /lib/mkinitrd/scripts /lib/mkinitrd/scripts/setup-nfs.sh @@ -281,6 +286,16 @@ rm -rf $RPM_BUILD_ROOT %doc nfs/*.html nfs/*.ps linux-nfs/* README.NFSv4 %changelog +* Fri Nov 14 2008 nfbrown@suse.de +- nfsserver.init + * don't set version if nfsd already running. + doing that causes unhelpful error when trying + to start nfsserver when it is already running. + (bnc#427330) +- modprobe.nfs-utils + * arrange that when various nfs modules are loaded + the relevant values from /etc/sysctl.conf are set + (bnc#431306, bnc#443118) * Fri Nov 07 2008 nfbrown@suse.de - nfs.init * fix typo in handling of "init.d/nfs status" diff --git a/nfsserver.init b/nfsserver.init index fe7b656..bf889ee 100644 --- a/nfsserver.init +++ b/nfsserver.init @@ -167,12 +167,15 @@ case "$1" in rc_status fi if [ "$NFS4_SUPPORT" = "yes" ]; then - echo "+2 +3 +4" > /proc/fs/nfsd/versions + VERSION_LIST="+2 +3 +4" VERSION_PARAMS="" else - echo "+2 +3 -4" > /proc/fs/nfsd/versions + VERSION_LIST="+2 +3 -4" VERSION_PARAMS="--no-nfs-version 4" fi + if [ " `cat /proc/fs/nfsd/threads`" = " 0" ]; then + echo $VERSION_LIST > /proc/fs/nfsd/versions + fi nfs4_bind_mounts # svcgssd; idmapd if [ "$NEED_SVCGSSD" = yes ]; then