Bug 164186 - exportfs incorrectly unexports filesystems when -r is used
Summary: exportfs incorrectly unexports filesystems when -r is used
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: nfs-utils
Version: 3.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Steve Dickson
QA Contact: Ben Levenson
URL:
Whiteboard:
Keywords:
: IT_59244 (view as bug list)
Depends On:
Blocks: 156320 165061
TreeView+ depends on / blocked
 
Reported: 2005-07-25 20:04 UTC by Neil Horman
Modified: 2007-11-30 22:07 UTC (History)
2 users (show)

(edit)
Clone Of:
(edit)
Last Closed: 2005-09-28 18:54:11 UTC


Attachments (Terms of Use)
patch to set maymount flag for database built from /proc/fs/nfs/exports (349 bytes, patch)
2005-07-25 20:04 UTC, Neil Horman
no flags Details | Diff


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2005:697 qe-ready SHIPPED_LIVE nfs-utils bug fix update 2005-09-28 04:00:00 UTC

Description Neil Horman 2005-07-25 20:04:06 UTC
Description of problem:
exportfs, when re-exporting filesystems, instead unexports them.

Version-Release number of selected component (if applicable):
RHEL3 U5

How reproducible:
always

Steps to Reproduce:
1) On server added the folowing to file  /etc/exports :
   /tmp *(ro)

2) On server restart nfs :
    # service nfs restart

3) On client mount/unmount  (WORKS) :
    # mount server123.redhat.com:/tmp /mnt/tmp
    # umount /tmp/mnt

4) On server re-export /tmp :
    # exportfs -rv
    exporting *:/tmp
    unexporting client123.redhat.com:/tmp from kerne
  
Actual results:
/tmp is not exported in the kernel, and subsequent attempts to mount the file
system from a client result in getfh: permission denied messages on the client
and from rpc.mountd on the server

Expected results:
filesystem should continue to be mount-able.

Additional info:
I'm attaching my patch to correct this.  It appears when re-exporting, the
rebuild of the export database in xtab_read, when reading /proc/fs/nfs/exports,
fails to set the m_mayexport flag, as it does when reading /var/lib/nfs/xtab. 
The result is that exportfs interprets this as a indicator to explicitly
unexport the mount.  The attached patch corrects this, and has been successfully
tested by the customer

Comment 1 Neil Horman 2005-07-25 20:04:07 UTC
Created attachment 117133 [details]
patch to set maymount flag for database built from /proc/fs/nfs/exports

Comment 2 Issue Tracker 2005-07-25 20:27:51 UTC
From User-Agent: XML-RPC

The patch provided by SEG (nhorman) has been tested in the GSS lab to
resolve the problem and allow the  mounts to work correctly past the point
the 'exportfs -rv' is run on the server.



Requesting Dell L3 or customer to test the patch
(nfs-utils-1.0.6-reexport.patch) attached in this case and confirm the
fix.


This event sent from IssueTracker by sbenjamin
 issue 73749

Comment 4 Steve Dickson 2005-07-27 09:58:12 UTC
The above patch was added to nfs-utils-1.0.6-40EL.

Comment 5 Steve Dickson 2005-07-27 14:51:25 UTC
*** Bug 126129 has been marked as a duplicate of this bug. ***

Comment 10 Red Hat Bugzilla 2005-09-28 18:54:12 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2005-697.html



Note You need to log in before you can comment on or make changes to this bug.