FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian Kernel

 
 
LinkBack Thread Tools
 
Old 06-27-2012, 09:01 PM
Vagrant Cascadian
 
Default Bug#676604: nfs-kernel-server: fails to start if exports are only defined in /etc/exports.d/*.exports

tags 676604 patch
thanks

On Fri, Jun 08, 2012 at 12:06:15AM -0700, Vagrant Cascadian wrote:
> After upgrading nfs-kernel-server, it fails to start, complaining that there are no exports.
>
> service nfs-kernel-server start
> Not starting NFS kernel daemon: no exports. ... (warning).
>
> I do not have any changes to /etc/exports, it is true, but do have exports
> defined in /etc/exports.d/*.exports, and these are valid exports.
>
> By commenting out the check for an empty /etc/exports (introduced to resolve
> #673798) in /etc/init.d/nfs-kernel-server, nfsd starts and all is well again:
>
> if [ -f /etc/exports ] # && grep -q '^[[:space:]]*[^#]*/' /etc/exports
>
> This check should probably be either be reverted, or it should at least iterate
> it through all the /etc/exports.d/*.exports files before deciding there are no
> exports.

patch implementing the latter follows:

--- a/init.d/nfs-kernel-server
+++ b/init.d/nfs-kernel-server
@@ -60,7 +60,13 @@ do_mount() {
# See how we were called.
case "$1" in
start)
- if [ -f /etc/exports ] && grep -q '^[[:space:]]*[^#]*/' /etc/exports
+ export_files="/etc/exports"
+ for file in /etc/exports.d/*.exports ; do
+ if [ -f "$file" ]; then
+ export_files="$export_files $file"
+ fi
+ done
+ if [ -f /etc/exports ] && grep -q '^[[:space:]]*[^#]*/' $export_files
then
do_modprobe nfsd


live well,
vagrant



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: http://lists.debian.org/20120627210147.GM21245@talon.fglan
 

Thread Tools




All times are GMT. The time now is 09:57 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org