From nobody@FreeBSD.org  Wed Feb  6 07:29:28 2002
Return-Path: <nobody@FreeBSD.org>
Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21])
	by hub.freebsd.org (Postfix) with ESMTP id 706D737B416
	for <freebsd-gnats-submit@FreeBSD.org>; Wed,  6 Feb 2002 07:29:28 -0800 (PST)
Received: (from nobody@localhost)
	by freefall.freebsd.org (8.11.6/8.11.6) id g16FTSc30530;
	Wed, 6 Feb 2002 07:29:28 -0800 (PST)
	(envelope-from nobody)
Message-Id: <200202061529.g16FTSc30530@freefall.freebsd.org>
Date: Wed, 6 Feb 2002 07:29:28 -0800 (PST)
From: Warren Smith <warren_a_smith@yahoo.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: Last entry in /etc/exports ignored
X-Send-Pr-Version: www-1.0

>Number:         34666
>Category:       misc
>Synopsis:       Last entry in /etc/exports ignored
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Feb 06 07:30:01 PST 2002
>Closed-Date:    Thu Feb 7 12:45:09 PST 2002
>Last-Modified:  Thu Feb 07 12:51:07 PST 2002
>Originator:     Warren Smith
>Release:        4.5-RELEASE
>Organization:
>Environment:
FreeBSD obiwan.wandrsmith.net 4.5-RELEASE FreeBSD 4.5-RELEASE #1: Thu Jan 31 09:10:04 CST 2002     warren@obiwan.wandrsmith.net:/usr/obj/usr/src/sys/OBIWAN  i386
>Description:
Valid entry in /etc/exports seems to be ignored if it is the last entry.  The exact same entry works as long as it is not the last entry.  Several different entries tried.  All worked at other positions.  None worked if last.
>How-To-Repeat:
Attempt to mount an exported filesystem that appears last in /etc/exports.
>Fix:

>Release-Note:
>Audit-Trail:

From: Maxim Konovalov <maxim@macomnet.ru>
To: Warren Smith <warren_a_smith@yahoo.com>
Cc: freebsd-gnats-submit@FreeBSD.ORG
Subject: Re: misc/34666: Last entry in /etc/exports ignored
Date: Wed, 6 Feb 2002 18:44:33 +0300 (MSK)

 Works for me on yesterday -stable right now. Could you please show
 your /etc/exports?
 
 -- 
 Maxim Konovalov, MAcomnet, Internet-Intranet Dept., system engineer
 phone: +7 (095) 796-9079, mailto: maxim@macomnet.ru
 
 

From: Peter Pentchev <roam@ringlet.net>
To: Warren Smith <warren_a_smith@yahoo.com>
Cc: bug-followup@FreeBSD.org
Subject: Re: misc/34666: Last entry in /etc/exports ignored
Date: Wed, 6 Feb 2002 17:58:08 +0200

 On Wed, Feb 06, 2002 at 07:29:28AM -0800, Warren Smith wrote:
 > 
 > >Number:         34666
 > >Category:       misc
 > >Synopsis:       Last entry in /etc/exports ignored
 > >Originator:     Warren Smith
 > >Description:
 > Valid entry in /etc/exports seems to be ignored if it is the last entry.  The exact same entry works as long as it is not the last entry.  Several different entries tried.  All worked at other positions.  None worked if last.
 > >How-To-Repeat:
 > Attempt to mount an exported filesystem that appears last in /etc/exports.
 
 As Maxim Konovalov already asked, can you show us your /etc/exports file?
 You wouldn't happen to be trying to export several directories from
 the same mounted filesystem on different lines, would you?  If you are,
 then this is the problem - when exporting a directory tree, mountd modifies
 the filesystem it resides on, and for some reason or other it cannot do
 this twice.
 
 G'luck,
 Peter
 
 -- 
 Peter Pentchev	roam@ringlet.net	roam@FreeBSD.org
 PGP key:	http://people.FreeBSD.org/~roam/roam.key.asc
 Key fingerprint	FDBA FD79 C26F 3C51 C95E  DF9E ED18 B68D 1619 4553
 because I didn't think of a good beginning of it.
State-Changed-From-To: open->feedback 
State-Changed-By: cjc 
State-Changed-When: Wed Feb 6 17:05:55 PST 2002 
State-Changed-Why:  
Waiting for information from the submitter, 

$ cat /etc/exports 
$ mount -t ufs 


http://www.FreeBSD.org/cgi/query-pr.cgi?pr=34666 

From: Peter Pentchev <roam@ringlet.net>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: misc/34666: Last entry in /etc/exports ignored
Date: Thu, 7 Feb 2002 10:22:56 +0200

 Adding the submitter's response to the PR audit trail..
 
 G'luck,
 Peter
 
 -- 
 Peter Pentchev	roam@ringlet.net	roam@FreeBSD.org
 PGP key:	http://people.FreeBSD.org/~roam/roam.key.asc
 Key fingerprint	FDBA FD79 C26F 3C51 C95E  DF9E ED18 B68D 1619 4553
 This sentence contradicts itself - or rather - well, no, actually it doesn't!
 
 ----- Forwarded message from Warren Smith <warren_a_smith@yahoo.com> -----
 
 From: Warren Smith <warren_a_smith@yahoo.com>
 To: Peter Pentchev <roam@ringlet.net>
 Subject: Re: misc/34666: Last entry in /etc/exports ignored
 Date: Wed, 6 Feb 2002 10:32:36 -0600
 In-Reply-To: <20020206175808.H5015@straylight.oblivion.bg>
 
 On Wednesday 06 February 2002 09:58 am, you wrote:
 > On Wed, Feb 06, 2002 at 07:29:28AM -0800, Warren Smith wrote:
 > > >Number:         34666
 > > >Category:       misc
 > > >Synopsis:       Last entry in /etc/exports ignored
 > > >Originator:     Warren Smith
 > > >Description:
 > >
 > > Valid entry in /etc/exports seems to be ignored if it is the last
 > > entry.  The exact same entry works as long as it is not the last
 > > entry.  Several different entries tried.  All worked at other
 > > positions.  None worked if last.
 > >
 > > >How-To-Repeat:
 > >
 > > Attempt to mount an exported filesystem that appears last in
 > > /etc/exports.
 >
 > As Maxim Konovalov already asked, can you show us your /etc/exports
 > file? You wouldn't happen to be trying to export several
 > directories from the same mounted filesystem on different lines,
 > would you?  If you are, then this is the problem - when exporting a
 > directory tree, mountd modifies the filesystem it resides on, and
 > for some reason or other it cannot do this twice.
 >
 > G'luck,
 > Peter
 
 Yes, I am trying to do that.  The first two lines work.  Further 
 experimentation reveals that the third and higher mount points for 
 /usr fail.  I had originally had only 3 mount points, hence the 
 reference to "last" in my original post.  I added the /usr/test entry 
 for testing.  
 
 Here is my /etc/exports. 
 
 /usr/src        -ro             yoda
 /usr/obj        -ro             yoda
 /usr/ports      -maproot=root   yoda
 /usr/test        -ro             yoda
 
 Perhaps I misunderstood exports(5)?
 
 <snip>
 Mount points for a filesystem may appear on multiple lines each with 
 different sets of hosts and export options.
 <snip>
 
 -- 
 Warren Smith
 
 
 ----- End forwarded message -----
State-Changed-From-To: feedback->closed 
State-Changed-By: cjc 
State-Changed-When: Thu Feb 7 12:45:09 PST 2002 
State-Changed-Why:  
The submitter was using an exports(5) file with multiple lines for one 
filesystem and one network/host. This is not a valid exports(5) 
file, and this is reflected in the documentation, 

Each line in the file (other than comment lines that begin with a #) 
specifies the mount point(s) and export flags within one local server 
filesystem for one or more hosts.  A host may be specified only once for 
each local filesystem on the server and there may be only one default 
entry for each server filesystem that applies to all other hosts. 

And FAQ question 12.13. 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=34666 
>Unformatted:
