LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 02-29-2012, 02:36 PM   #1
barataaway
LQ Newbie
 
Registered: Jan 2012
Location: São Paulo / SP / Brazil
Distribution: Red Hat, Fedora, SuSe, HPUX, Solaris
Posts: 12

Rep: Reputation: Disabled
Unhappy NFS doesn't mount after reboot on RHEL 5.8 box/NFSv3.


Hello linuxers!

I got a little problem on having a NFS automatically mounted after reboot. RHEL 5.8 box/NFSv3/NAS volume.

The fs simply doesn't mount after reboot. However, when the box comes up, if I input a "mount -a" the volume get mounted without problems.

It seems (at least to me) that the configuration is alright. Please, take a look:


- NFS Service

Code:
[root@mybox ~]# chkconfig --list nfs
nfs             0:no  1:no  2:yes   3:yes   4:yes   5:yes   6:no  
[root@mybox ~]# chkconfig --list netfs
netfs           0:no  1:no  2:yes   3:yes   4:yes   5:yes   6:no  
[root@mybox ~]#
- NFS version

Code:
[root@mybox ~]# nfsstat
Server rpc stats:
calls      badcalls   badclnt    badauth    xdrcall
0          0          0          0          0

Client rpc stats:
calls      retrans    authrefrsh
1560927    0          0

Client nfs v3:
null         getattr      setattr      lookup       access       readlink
0         0% 967758   61% 77227     4% 216627   13% 152323    9% 15        0%
read         write        create       mkdir        symlink      mknod
21988     1% 22142     1% 18114     1% 8         0% 0         0% 0         0%
remove       rmdir        rename       link         readdir      readdirplus
81        0% 0         0% 18114     1% 0         0% 2210      0% 64310     4%
fsstat       fsinfo       pathconf     commit
7         0% 2         0% 0         0% 0         0%

[root@mybox ~]#

- /etc/fstab (I can't put my real ip here, sorry)

Code:
[root@mybox ~]# grep nfs /etc/fstab
200.X.X.240:/vol/vol_web2 /web      nfs     intr,soft,rw    0 0
[root@mybox ~]#
- Service sequence of initialization (nfs svces is initializing after network svc)

Code:
[root@mybox ~]# ls -l /etc/rc3.d/ | egrep -i "netfs|nfs|netw"
lrwxrwxrwx 1 root root 24 Dez 16 18:27 K02NetworkManager -> ../init.d/NetworkManager
lrwxrwxrwx 1 root root 17 Fev  8 11:24 S10network -> ../init.d/network
lrwxrwxrwx 1 root root 17 Dez 16 18:27 S14nfslock -> ../init.d/nfslock
lrwxrwxrwx 1 root root 15 Fev 24 18:02 S25netfs -> ../init.d/netfs
lrwxrwxrwx 1 root root 13 Fev 24 18:02 S60nfs -> ../init.d/nfs
[root@mybox ~]#
- /etc/hosts has NAS' ip

Code:
[root@mybox ~]# grep nas /etc/hosts
200.X.X.240 nas01
[root@mybox ~]#

- There is a route to the NAS ip (and it works)

Code:
[root@mybox ~]# netstat -rnv | grep 200
200.X.X.240 10.X.X.33    255.255.255.255 UGH       0 0          0 eth3
[root@mybox ~]#

- Persistent route

Code:
[root@mybox ~]# cat /etc/sysconfig/network-scripts/route-eth3
ADDRESS0=200.X.X.240
NETMASK0=255.255.255.255
GATEWAY0=10.X.X.33
[root@mybox ~]#



At this time, as a workaround, i've added "mount -a" to /etc/rc.local, and, at least, the nfs is mounting after reboot. However, it takes about 3~4 min to mount (checked with "uptime").




below are more info from dmesg:



Code:
[root@mybox ~]# dmesg | grep -i nfs
Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
NFSD: Using /var/lib/nfs/v4recovery as the NFSv4 state recovery directory
NFSD: starting 90-second grace period
[root@mybox ~]# dmesg | grep -i netfs
[root@mybox ~]# dmesg | grep -i error
ACPI Error (psparse-0537): Method parse/execution failed [\_SB_.PMI0._GHL] (Node ffff81023003d8b0), AE_SUPPORT
ACPI Error (psparse-0537): Method parse/execution failed [\_SB_.PMI0._PMC] (Node ffff81023003d8f0), AE_SUPPORT
[root@mybox ~]# dmesg | grep -i mount
Mount-cache hash table entries: 256
EXT3-fs: mounted filesystem with ordered data mode.
EXT3-fs: mounted filesystem with ordered data mode.
EXT3-fs: mounted filesystem with ordered data mode.
EXT3-fs: mounted filesystem with ordered data mode.
EXT3-fs: mounted filesystem with ordered data mode.
EXT3-fs: mounted filesystem with ordered data mode.
EXT3-fs: mounted filesystem with ordered data mode.
EXT3-fs: mounted filesystem with ordered data mode.
[root@mybox ~]#

and /var/log/messages:

Code:
[root@mybox ~]# grep -i nfs /var/log/messages
Feb 28 17:56:55 mybox kernel: Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
Feb 28 17:56:55 mybox kernel: NFSD: Using /var/lib/nfs/v4recovery as the NFSv4 state recovery directory
Feb 28 17:56:55 mybox kernel: NFSD: starting 90-second grace period
Feb 28 18:02:53 mybox kernel: nfsd: last server has exited
Feb 28 18:02:53 mybox kernel: nfsd: unexporting all filesystems
Feb 28 18:06:37 mybox kernel: Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
Feb 28 18:06:37 mybox kernel: NFSD: Using /var/lib/nfs/v4recovery as the NFSv4 state recovery directory
Feb 28 18:06:37 mybox kernel: NFSD: starting 90-second grace period
Feb 29 10:33:03 mybox kernel: nfsd: last server has exited
Feb 29 10:33:03 mybox kernel: nfsd: unexporting all filesystems
Feb 29 10:33:03 mybox kernel: NFSD: Using /var/lib/nfs/v4recovery as the NFSv4 state recovery directory
Feb 29 10:33:03 mybox kernel: NFSD: starting 90-second grace period
Feb 29 14:21:43 mybox kernel: nfsd: last server has exited
Feb 29 14:21:43 mybox kernel: nfsd: unexporting all filesystems
Feb 29 14:25:28 mybox kernel: Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
Feb 29 14:25:28 mybox kernel: NFSD: Using /var/lib/nfs/v4recovery as the NFSv4 state recovery directory
Feb 29 14:25:28 mybox kernel: NFSD: starting 90-second grace period
[root@mybox ~]#


Any hints?

Thank you very much
 
Old 02-29-2012, 02:49 PM   #2
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
@ Reply

Hi barataaway,

Welcome to LQ!!!

Questions for you:

1. Any changes made to the system?
2. Any update that you have installed recently?

Can you share nfs configuration file and /etc/exports?
 
Old 03-02-2012, 08:58 AM   #3
barataaway
LQ Newbie
 
Registered: Jan 2012
Location: São Paulo / SP / Brazil
Distribution: Red Hat, Fedora, SuSe, HPUX, Solaris
Posts: 12

Original Poster
Rep: Reputation: Disabled
Hi T3RM1NVT0R! Thank you very much.

Yes, I updated it from RHEL5.7 to 5.8 but, to be honest, I don't know if the mounting was working before (I only tried it after updating).


What NFS configuration file you need?

The NAS volume configuration is:

/vol/vol_web2 -sec=sys,rw,root=10.YY.YY.39

(pointing to host's ip)

Thank you.
 
Old 03-02-2012, 01:43 PM   #4
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
@ Reply

I am looking for /etc/nfsmount.conf
 
Old 03-03-2012, 07:39 PM   #5
barataaway
LQ Newbie
 
Registered: Jan 2012
Location: São Paulo / SP / Brazil
Distribution: Red Hat, Fedora, SuSe, HPUX, Solaris
Posts: 12

Original Poster
Rep: Reputation: Disabled
This file does not exist... It should?
 
Old 03-03-2012, 09:03 PM   #6
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
@ Reply

I have checked on my RHEL5 system and it was not there but it is there on my RHEL6 system. From the dmesg that you have pasted it appears that it is trying to negotiate over NFSv4 first and when it doesn't work it switches to NFSv3.

Attached is the edited nfsmount.conf file. Rename it from .txt to .conf, copy it under /etc and then reboot to see if your nfs share mount automatically after reboot or not. Don't forget to remark (#) out mount -a /etc/rc.local :-)
Attached Files
File Type: txt nfsmount.conf.txt (3.3 KB, 217 views)
 
Old 03-24-2015, 01:37 AM   #7
gauravgoel1989
Member
 
Registered: Feb 2013
Posts: 42

Rep: Reputation: Disabled
Check if netfs service is running or not.
 
Old 03-24-2015, 02:03 AM   #8
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
You are replying to a thread which is almost 3 years old. Why???
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] mount nfs problem: mount(2) Input/Output error, virtual box involved gjatute Linux - Newbie 6 10-23-2012 01:57 PM
RHEL 6 Can't Mount NFS Share carlosinfl Red Hat 9 04-01-2011 09:53 AM
[SOLVED] mount solaris NFS share in RHEL 4 ZAMO Linux - Enterprise 2 04-28-2010 07:55 PM
RHEL 5 nfs mount hangs on RHEL 3 gwasigh Linux - Networking 1 06-13-2008 10:43 PM
nfs mount using nfsv3 with HPUX fails mpqcman Linux - Software 5 10-27-2005 11:14 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 02:56 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration