From antuan@cplus.ru  Mon Mar  5 10:44:29 2007
Return-Path: <antuan@cplus.ru>
Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52])
	by hub.freebsd.org (Postfix) with ESMTP id 2AD5B16A401
	for <FreeBSD-gnats-submit@freebsd.org>; Mon,  5 Mar 2007 10:44:29 +0000 (UTC)
	(envelope-from antuan@cplus.ru)
Received: from tyger.cplus.ru (tyger.cplus.ru [193.125.204.51])
	by mx1.freebsd.org (Postfix) with ESMTP id 8D31413C428
	for <FreeBSD-gnats-submit@freebsd.org>; Mon,  5 Mar 2007 10:44:28 +0000 (UTC)
	(envelope-from antuan@cplus.ru)
Received: from tyger.cplus.ru (antuan@localhost [127.0.0.1])
	by tyger.cplus.ru (8.13.8/8.13.8) with ESMTP id l25AMB0Y058334
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 5 Mar 2007 13:22:11 +0300 (MSK)
	(envelope-from antuan@tyger.cplus.ru)
Received: (from antuan@localhost)
	by tyger.cplus.ru (8.13.8/8.13.8/Submit) id l25AMAVn058330;
	Mon, 5 Mar 2007 13:22:10 +0300 (MSK)
	(envelope-from antuan)
Message-Id: <200703051022.l25AMAVn058330@tyger.cplus.ru>
Date: Mon, 5 Mar 2007 13:22:10 +0300 (MSK)
From: Antuan Avdioukhine <antuan@cplus.ru>
Reply-To: Antuan Avdioukhine <antuan@cplus.ru>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: mountd(8) does not accept identical network address-mask pairs on different mount entries on the same file system
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         109912
>Category:       misc
>Synopsis:       mountd(8) does not accept identical network address-mask pairs on different mount entries on the same file system
>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:   Mon Mar 05 10:50:02 GMT 2007
>Closed-Date:    Mon Mar 05 10:51:53 GMT 2007
>Last-Modified:  Mon Mar 05 10:51:53 GMT 2007
>Originator:     Antuan Avdioukhine
>Release:        FreeBSD 5.5-STABLE i386
>Organization:
TC Convey Plus
>Environment:
System: FreeBSD tyger.cplus.ru 5.5-STABLE FreeBSD 5.5-STABLE #2: Sat Mar 3 18:54:38 MSK 2007 toor@tyger.cplus.ru:/usr/obj/usr/src/sys/TYGER i386


>Description:
If /etc/exports contains mount entries, belongs to one file system and
exported for identical host groups or networks mountd(8) produces an error
"can't change attributes for <mountpoint path>" and "bad export line
<mountpoint path>" for each mount entry but first. This is happens whether
different mount options was used or not.

>How-To-Repeat:

1. Create two directories for mount points on the same file system, eg:
/tmp/u1 and /tmp/u2, check that this directories are suitable for export
(eg. have proper permissions) and no other filesystems mounted on this
directories.

2. Start NFS server as usual. Check that syslog catches daemon facility at
notice level or lower. mountd started with flags: -l -r -n

3. create /etc/exports file entries:

/tmp/u1 10.0.0.1
/tmp/u2 10.0.0.1

4. run 'kill -1 `head -1 /var/run/montd.pid`'

5. Check log for mountd reporting. It is expected to see messages:
Mar  5 13:02:35 tyger mountd[50813]: can't change attributes for /tmp/u2
Mar  5 13:02:35 tyger mountd[50813]: bad exports list line /tmp/u2 10.0.0.1

You may also change host sets from single host to list of hosts or networks,
with the only condition: if you are using networks, all networks must be
with identical addreses and masks.

>Fix:

Workaround:

For host sets specified with network-mask pair it is possible to split
network using longer masks, eg. 

/tmp/u1 -network 10.0.0.0 -mask 255.255.255.0
/tmp/u2 -network 10.0.0.0 -mask 255.255.255.128
/tmp/u2 -network 10.0.0.128 -mask 255.255.255.128

I don't know suitable workaround for host sets specified with host lists.


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: remko 
State-Changed-When: Mon Mar 5 10:51:51 UTC 2007 
State-Changed-Why:  
duplicate of misc/109911 

http://www.freebsd.org/cgi/query-pr.cgi?pr=109912 
>Unformatted:
 
