You are not logged in.

#1 2020-12-13 17:33:02

cdwijs
Member
Registered: 2010-04-24
Posts: 310

NFS share not mounted, as network is available 3 seconds too late

I have a NFS server, and on my PC I have the following in my /etc/fstab:

# cat /etc/fstab 
# Static information about the filesystems.
# See fstab(5) for details.

# <file system> <dir> <type> <options> <dump> <pass>
# /dev/sda1
UUID=3f9f9ebb-ce22-4a22-842d-4881c8da92a5	/         	ext4      	noatime	0 1
#/swapfile none swap sw 0 0 
192.168.31.104:/storage-btrfs	/mnt/nfs/storage-btrfs nfs   defaults,timeo=900,retrans=5,_netdev

During boot, I get this error, and the NFS share is not mounted.

[    9.602964] NFS4: Couldn't follow remote path
[   12.137186] IPv6: ADDRCONF(NETDEV_CHANGE): enp4s0: link becomes ready
[   12.137383] r8169 0000:04:00.0 enp4s0: Link is Up - 1Gbps/Full - flow control rx/tx

Afterwards, I can run this command as root, and the NFS share does get mounted:

mount -a

How can I mount the NFS share only after the network is connected?

Offline

#2 2020-12-13 21:44:27

wmcclain
Member
Registered: 2015-12-20
Posts: 3
Website

Re: NFS share not mounted, as network is available 3 seconds too late

Add "bg" to your mount option in fstab, for "background".

See "man nfs" for details.

Offline

Board footer

Powered by FluxBB