-   Linux - Networking (
-   -   NFS mounting using FSTAB (

Ammad 05-16-2008 08:13 AM

NFS mounting using FSTAB
Hi all,

i am using rhel 4.2 and 5. both systems are working and i am able to mount using mount manually.

#mount server1:/opt/tmp /opt/tmp

and it works,
but if i try it via /etc/fstab

server1:/opt/tmp /opt/tmp nfs _netdev,defaults 0 0

it doesn't. any tip , in this ?

b0uncer 05-16-2008 09:07 AM

What error does it throw if you try to mount it via fstab? Using

mount -a
or should say what's wrong if it doesn't succeed.

Ammad 05-17-2008 07:15 AM

there isn't any error if i use

#mount -a

and able to successfully mount nfs share :( . whereas it should also work
when system reboots.
Google is also populated with this problem, and i still didn't found work solution of this.


tox2ik 05-19-2008 11:48 PM

what the hell is _netdev?
try removing that option unless you know better.

also for names to work in fstab like this one:

tryggve:/mnt/140g /mnt/net/140g nfs defaults 0 0
you need a line in the /etc/hosts file for each one like so:
Code: tryggve try router otherhost

alternatively there is a dns server in your network which knows where "server1" is.

your distro probably has an init script called something like nfsmount in /etc/init.d or /etc/rc.*
make sure it is included in the startup configuration

Ammad 05-20-2008 04:38 AM

i have also done using ip address but no success, the
"_netdev" defines to wait until network devices up. even though i removed all options and used just "defaults" but fails to mount on boot.

whereas "mount -a " works fine, that is strange, i am using RHEL 4 and RHEL 5.

thanks for interest.

PDock 05-20-2008 06:44 AM

have you tried

mount -a -t nfs
Most distributions will parse fstab multiple times during the boot process. Whats more they (should) use parameters like nonfs to prevent mounting remote file systems until the network has been brought up. Thus _netdev is probably not necessary and of note in man is it only prevents mounting this line. ie A second mount like the one above needs to be issued during the init process.

so if the above mount did not work reformat fstab entry until it does else

well not being a RHEL user think the best thing I should advise is to reinstall your nfsd package hoping it will fix your mount problem.

Ammad 05-20-2008 07:38 AM

i did changes in fstab. but i think reinstalling will solve this. i will check this

hasanatizaz 12-18-2008 06:23 AM

whats the update ? is this problem solved ?

All times are GMT -5. The time now is 04:16 AM.