This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 98724 - NFS exports: sudden bad exports
NFS exports: sudden bad exports
Status: CLOSED CURRENTRELEASE
Product: Red Hat Linux
Classification: Retired
Component: nfs-utils (Show other bugs)
7.3
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Steve Dickson
Ben Levenson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-07-07 19:07 EDT by Leonard den Ottolander
Modified: 2007-04-18 12:55 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-06-15 17:02:47 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Leonard den Ottolander 2003-07-07 19:07:50 EDT
Description of problem:

Athlon Thunderbird 800, Red Hat 7.3, kernel-2.4.20-18.7 (standard athlon rpm).

$ cat /etc/exports
/data/leonard/RedHat/updates.sorted     192.168.0.0/24(rw,no_root_squash)
/data/inout                             192.168.0.0/24(rw,no_root_squash)

Second export gives no problems, first one suddenly does (no recent changes on
the server).

Client (either other Pentium or Athlon itself) report Stale NFS file handle
errors.
# mount /mnt/updates (being first export above)
# rpm -iv /mnt/updates/7.3/i386/ghostscript-6.52-9.5.i386.rpm
error: open of /mnt/updates/7.3/i386/ghostscript-6.52-9.5.i386.rpm failed: Stale
 NFS file handle
(same problem on athlon when mounting it's own share, but no problem with
/data/inout)

Snippets from /var/log/messages on athlon:
Jul  7 23:50:06 athlon rpc.mountd: authenticated mount request from
athlon.localdomain:686 for /data/leonard/RedHat/updates.sorted
(/data/leonard/RedHat/updates.sorted) 
Jul  7 23:50:24 athlon kernel: nfsd Security: i386/ghostscript-6.52-9.5.i386.rpm
bad export.
Jul  8 00:03:59 athlon rpc.mountd: authenticated mount request from
pentium.localdomain:749 for /data/inout (/data/inout)
Jul  8 00:05:21 athlon kernel: nfsd Security: updates/getupdates bad export.

(This is weird, because the mount path is /mnt/updates, but the export path
is .../updates.sorted.)

Jul  8 00:13:04 athlon rpc.mountd: authenticated mount request from
pentium.localdomain:772 for /data/leonard/RedHat/updates.sorted
(/data/leonard/RedHat/updates.sorted)
Jul  8 00:13:06 athlon kernel: nfsd Security: i386/ghostscript-6.52-9.5.i386.rpm
bad export.

(Here the path is incomplete as well, actually <mount point>/7.3/i386/ghost...,
but this could be an abbreviation.)

Tried to solve this by issueing
# service nfslock stop; service nfs stop; service portmap restart; service nfs
start; service nfslock restart
No result
# exportfs -ua
# exportfs -a
No result
# exportfs -r
No result
# init 1
...
# init 5
No result

And now, while I fill out this bug report the problem has suddenly dissapeared.
Weird.
Comment 1 Steve Dickson 2003-07-08 07:01:30 EDT
How does /proc/fs/nfs/exports compair with /etc/exports
when this happens...
Comment 2 Leonard den Ottolander 2003-07-08 07:25:39 EDT
Sorry I forgot to check this. I will let you know as soon as the problem occurs
again. As you might have understood it is an intermittent problem, so I can't tell
you when this will be ;) .

By the way, shouldn't you assign the bug to yourself?
Comment 3 Leonard den Ottolander 2003-07-13 19:45:49 EDT
[leonard@pentium leonard]$ mount /mnt/updates
mount: only root can mount athlon:/data/leonard/RedHat/updates.sorted on
/mnt/updates
[leonard@pentium leonard]$ sudo mount /mnt/updates
Password:
[leonard@pentium leonard]$ cd /mnt/updates/
[leonard@pentium updates]$ ls
6.2  7.0  7.1  7.2  7.3  8.0  getupdates  getupdates.8  mkiso.rh73  speedtouch
[leonard@pentium updates]$ cp getupdates /dev/null
cp: reading `getupdates': Input/output error

(I haven't tried cp getupdates.8 /dev/null immediately.)



[leonard@athlon log]$ sudo cat messages
<snip>
Jul 14 00:58:12 athlon rpc.mountd: authenticated mount request from
firewall.localdomain:647 for /da
ta/leonard/RedHat/updates.sorted (/data/leonard/RedHat/updates.sorted)
Jul 14 01:12:03 athlon rpc.mountd: authenticated mount request from
pentium.localdomain:604 for /dat
a/leonard/RedHat/updates.sorted (/data/leonard/RedHat/updates.sorted)
Jul 14 01:12:41 athlon kernel: nfsd Security: updates/getupdates bad export.
Jul 14 01:12:41 athlon last message repeated 2 times
<snip>



[leonard@athlon log]$ cat /etc/exports
#
#/home/leonard  *(no_root_squash,ro)
#/data/leonard  192.168.0.0/24(rw)
#/data/leonard/firewall.images  192.168.0.0/24(rw,no_root_squash)
/data/leonard/RedHat/updates.sorted     192.168.0.0/24(rw,no_root_squash)
/data/inout                             192.168.0.0/24(rw,no_root_squash)
#/data/leonard/firewall.images \
192.168.0.0/24(rw,root_squash,all_squash,anonuid=500,anongid=500)



[leonard@athlon log]$ cat /proc/fs/nfs/exports
# Version 1.1
# Path Client(Flags) # IPs
/data/leonard/RedHat/updates.sorted    
firewall.localdomain(rw,no_root_squash,async,wdelay) # 192.168.0.1
/data/leonard/RedHat/updates.sorted    
athlon.localdomain(rw,no_root_squash,async,wdelay) # 192.168.0.3
/data/leonard/RedHat/updates.sorted    
pentium.localdomain(rw,no_root_squash,async,wdelay) # 192.168.0.6
/data/inout     pentium.localdomain(rw,no_root_squash,async,wdelay) # 192.168.0.6



[leonard@athlon log]$ ls -l /data/leonard/RedHat/u*
/data/leonard/RedHat/updates:
total 56
drwxrwxr-x    4 leonard  leonard      4096 Oct 30  2002 6.2
drwxrwxr-x    4 leonard  leonard      4096 Oct 26  2002 7.0
drwxr-xr-x    4 leonard  leonard      4096 Oct 30  2002 7.1
drwxr-xr-x    9 leonard  leonard      4096 Oct 30  2002 7.2
drwxrwxr-x    8 leonard  leonard      4096 Oct 30  2002 7.3
drwxr-xr-x    8 leonard  leonard      4096 Oct 30  2002 8.0
-rwxr-xr-x    2 leonard  leonard      1899 Jul  3 18:50 getupdates
-rwxr-xr-x    1 leonard  leonard       482 Jun  6 19:40 getupdates-7.3
-rwxr-xr-x    1 leonard  leonard       468 Nov 10  2002 getupdates-7.3.000
-rwxr-xr-x    1 leonard  leonard       482 Jul  3 18:53 getupdates-8.0
-rwxr-xr-x    1 leonard  leonard      1773 Oct 26  2002 getupdates.000
-rwxr-xr-x    1 leonard  leonard      1724 Jul  3 18:52 getupdates.tmp
-rwxr--r--    1 leonard  leonard       609 Oct 30  2002 sortupdates
-rwxr--r--    1 leonard  leonard       305 Nov 10  2002 sortupdates-7.3

/data/leonard/RedHat/updates.otherarch:
total 4
drwxrwxr-x    3 leonard  leonard      4096 Oct 30  2002 6.2

/data/leonard/RedHat/updates.sorted:
total 40
drwxrwxr-x    4 leonard  leonard      4096 Oct 30  2002 6.2
drwxrwxr-x    4 leonard  leonard      4096 Oct 30  2002 7.0
drwxrwxr-x    4 leonard  leonard      4096 Oct 30  2002 7.1
drwxrwxr-x    8 leonard  leonard      4096 Oct 30  2002 7.2
drwxrwxr-x   11 leonard  leonard      4096 Jul  5 03:04 7.3
drwxrwxr-x   10 leonard  leonard      4096 Jul  5 03:03 8.0
-rwxr-xr-x    2 leonard  leonard      1899 Jul  3 18:50 getupdates
-rwxr-xr-x    1 leonard  leonard       469 Oct 30  2002 getupdates.8
-rwxr--r--    1 leonard  leonard       569 Nov 10  2002 mkiso.rh73
drwxrwxr-x    4 leonard  leonard      4096 Jun  7 12:25 speedtouch

 Could it be nfs chokes on the hard file links occasionally?
/data/leonard/RedHat/updates.sorted/getupdates is a hard link to
/data/leonard/RedHat/updates/getupdates and so are most of the files in the
other subdirectories of .../updates.sorted .
Comment 4 Leonard den Ottolander 2003-07-13 20:10:45 EDT
Missed this at first, but /data/inout which seems exported in
/proc/fs/nfs/exports on athlon above is not actually mounted on pentium.

[leonard@pentium updates]$ cat /etc/fstab
/dev/hda1               /                       ext2    defaults        1 1
/dev/hda7               /tmp                    ext2    defaults        1 2
/dev/hda8               /var/log                ext2    defaults        1 2
/dev/hda9               /mnt/testsys            ext2    noauto          0 0
/dev/hda10              /data                   ext2    defaults        1 2
/dev/hdd1               /mnt/hdd1               ext2    noauto          0 0
/dev/hda5               /mnt/backsys            ext2    noauto          0 0
none                    /dev/pts                devpts  gid=5,mode=620  0 0
none                    /proc                   proc    defaults        0 0
none                    /dev/shm                tmpfs   defaults        0 0
/dev/hda6               swap                    swap    defaults        0 0
/dev/cdrom              /mnt/cdrom              iso9660 noauto,user,kudzu,ro 0 0
/dev/cdrom1             /mnt/cdrom1             iso9660 noauto,user,kudzu,ro 0 0
/dev/fd0                /mnt/floppy             auto    noauto,user,kudzu 0 0
athlon:/data/leonard/RedHat/updates.sorted /mnt/updates         nfs    
noauto,rsize=8192,wsize=8192,retry=2,hard,intr 0 0



[leonard@pentium updates]$ cat /etc/mtab
/dev/hda1 / ext2 rw 0 0
none /proc proc rw 0 0
usbdevfs /proc/bus/usb usbdevfs rw 0 0
/dev/hda7 /tmp ext2 rw 0 0
/dev/hda8 /var/log ext2 rw 0 0
/dev/hda10 /data ext2 rw 0 0
none /dev/pts devpts rw,gid=5,mode=620 0 0
none /dev/shm tmpfs rw 0 0
athlon:/data/leonard/RedHat/updates.sorted /mnt/updates nfs
rw,rsize=8192,wsize=8192,retry=2,hard,intr,addr=192.168.0.3 0 0



[leonard@pentium updates]$ ls /mnt/tmp

 (athlon:/data/inout has been mounted on /mnt/tmp before but isn't now)



[leonard@pentium updates]$ cat /proc/net/rpc/nfs
net 0 0 0 0
rpc 58 0 0
proc2 18 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
proc3 22 0 35 0 12 5 0 3 0 0 0 0 0 0 0 0 0 1 0 1 1 0 0



 I should also add the state of /proc/net/rpc/nfsd on athlon after the initial
error:
[root@athlon root]# cat net_rpc_nfsd
rc 0 0 1246
fh 3 1211 0 0 0
io 1794836 0
th 8 0 0.290 0.010 0.000 0.000 0.040 0.000 0.000 0.000 0.000 0.000
ra 16 436 0 0 0 0 0 0 0 0 0 3
net 1246 1246 0 0
rpc 1246 0 0 0 0
proc2 18 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
proc3 22 0 34 0 756 0 0 440 0 0 0 0 0 0 0 0 0 12 0 2 2 0 0



 By the way, the problem has dissappeared although the fake export is still
there. Do exports that are forcedly unmounted survive a reboot??

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