nfs mounts failing during reboot
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
nfs-utils (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
12.04.1 LTS
I have 3 nfs mounts in /etc/fstab but only 2 succeed. After logging in, I can manually mount the 3rd nfs file system (/alansun_root) with no problems. This seems to be similar to https:/
If I change the order of the 3 nfs file systems in /etc/fstab, the file system not mounted changes, so it seems to be a timing issue. Sometimes, only 1 of the 3 file systems is mounted.
Here is /etc/fstab:
proc /proc proc nodev,noexec,nosuid 0 0
UUID=7ecd0957-
UUID=7f698647-
/dev/fd0 /media/floppy0 auto rw,user,
UUID=2405d070-
UUID=2613cf1b-
UUID=84295b7a-
UUID=95ddb6ca-
UUID=e2b812d7-
LABEL=Passport1 /media/Passport1 ntfs defaults,
LABEL=Passport2 /media/Passport2 ntfs defaults,
alansun:/ /alansun_root nfs defaults,
alansun:/usr/tims /alansun_usr_tims nfs defaults,
chcaix01:
After boot, mountall is still running:
# ps -ef|grep mount
root 267 1 0 14:06 ? 00:00:00 mountall --verbose --daemon
root 829 1 0 14:06 ? 00:00:00 /sbin/mount.ntfs /dev/sdc1 /media/Passport2 -o rw,windows_
I added --verbose to mountall in /etc/init/
Connected to Plymouth
/ is local
/proc is virtual
/sys is virtual
/sys/fs/
/sys/kernel/debug is virtual
/sys/kernel/
/dev is virtual
/dev/pts is virtual
/tmp is local
/run is virtual
/run/lock is virtual
/run/shm is virtual
UUID=7f698647-
/usr/local is local
/usr/tims is local
/data1 is local
/u is local
/spare is local
/media/Passport1 is nowait
/media/Passport2 is nowait
/alansun_root is nowait
/alansun_usr_tims is nowait
/u/i22/
local 0/7 remote 0/0 virtual 1/10 swap 0/1
local 0/7 remote 0/0 virtual 2/10 swap 0/1
local 0/7 remote 0/0 virtual 3/10 swap 0/1
local 0/7 remote 0/0 virtual 4/10 swap 0/1
local 0/7 remote 0/0 virtual 5/10 swap 0/1
mounting /sys/fs/
mount /sys/fs/
local 0/7 remote 0/0 virtual 6/10 swap 0/1
mounting /sys/kernel/debug
mount /sys/kernel/debug [449] exited normally
local 0/7 remote 0/0 virtual 7/10 swap 0/1
mounting /sys/kernel/
mount /sys/kernel/
local 0/7 remote 0/0 virtual 8/10 swap 0/1
mounting /run/lock
mount /run/lock [453] exited normally
local 0/7 remote 0/0 virtual 9/10 swap 0/1
mounting /run/shm
mount /run/shm [454] exited normally
virtual finished
remote finished
local 0/7 remote 0/0 virtual 10/10 swap 0/1
checking /
fsck from util-linux 2.20.1
activating /dev/disk/
swapon /dev/disk/
swap finished
local 0/7 remote 0/0 virtual 10/10 swap 1/1
checking /usr/local
checking /usr/tims
fsck from util-linux 2.20.1
checking /data1
fsck from util-linux 2.20.1
checking /u
checking /spare
fsck from util-linux 2.20.1
fsck from util-linux 2.20.1
fsck from util-linux 2.20.1
rpcbind: Cannot open '/run/rpcbind/
rpcbind: Cannot open '/run/rpcbind/
Received SIGUSR1 (network device up)
ata_id[571]: HDIO_GET_IDENTITY failed for '/dev/sdc': Invalid argument
/dev/sda1: clean, 176620/393216 files, 1081761/1572864 blocks
fsck / [464] exited normally
remounting /
mount / [789] exited normally
mount / [791] exited normally
mount /proc [792] exited normally
mount /sys [793] exited normally
mount /sys/fs/
mount /sys/kernel/debug [795] exited normally
mount /sys/kernel/
mount /dev [797] exited normally
mount /dev/pts [798] exited normally
mount /run [799] exited normally
mount /run/lock [800] exited normally
mount /run/shm [801] exited normally
local 1/7 remote 0/0 virtual 10/10 swap 1/1
usr_local: clean, 47/122160 files, 16627/487966 blocks
local 2/7 remote 0/0 virtual 10/10 swap 1/1
mounting /media/Passport2
spare: clean, 11/1414448 files, 132798/5652480 blocks
u: clean, 984/610800 files, 108455/2441728 blocks
usr_tims: clean, 150509/1831424 files, 2057142/7323631 blocks
data1: clean, 15371/610800 files, 763789/2441872 blocks
mount /media/Passport2 [814] exited normally
local 2/7 remote 0/0 virtual 10/10 swap 1/1
mounting /alansun_root
mount.nfs: Network is unreachable
mounting /alansun_usr_tims
mount.nfs: Network is unreachable
fsck /usr/local [483] exited normally
mounting /usr/local
mount /usr/local [856] exited normally
local 3/7 remote 0/0 virtual 10/10 swap 1/1
fsck /usr/tims [485] exited normally
mounting /usr/tims
mount /usr/tims [860] exited normally
local 4/7 remote 0/0 virtual 10/10 swap 1/1
fsck /data1 [497] exited normally
mounting /data1
mount /data1 [864] exited normally
local 5/7 remote 0/0 virtual 10/10 swap 1/1
fsck /u [498] exited normally
mounting /u
mount /u [868] exited normally
local 6/7 remote 0/0 virtual 10/10 swap 1/1
fsck /spare [499] exited normally
mounting /spare
mount /spare [872] exited normally
local finished
All filesystems mounted
local 7/7 remote 0/0 virtual 10/10 swap 1/1
mountall: mount /alansun_root [843] terminated with status 32
Filesystem could not be mounted: /alansun_root
mountall: mount /alansun_usr_tims [848] terminated with status 32
Filesystem could not be mounted: /alansun_usr_tims
modem-manager[929]: <info> ModemManager (version 0.5.2.0) starting...
modem-manager[929]: <info> Loaded plugin Wavecom
modem-manager[929]: <info> Loaded plugin X22X
modem-manager[929]: <info> Loaded plugin Gobi
modem-manager[929]: <info> Loaded plugin Longcheer
modem-manager[929]: <info> Loaded plugin Novatel
modem-manager[929]: <info> Loaded plugin Samsung
modem-manager[929]: <info> Loaded plugin Nokia
modem-manager[929]: <info> Loaded plugin Option High-Speed
modem-manager[929]: <info> Loaded plugin AnyData
modem-manager[929]: <info> Loaded plugin Sierra
modem-manager[929]: <info> Loaded plugin MotoC
modem-manager[929]: <info> Loaded plugin SimTech
modem-manager[929]: <info> Loaded plugin Ericsson MBM
modem-manager[929]: <info> Loaded plugin Huawei
modem-manager[929]: <info> Loaded plugin ZTE
modem-manager[929]: <info> Loaded plugin Option
modem-manager[929]: <info> Loaded plugin Linktop
modem-manager[929]: <info> Loaded plugin Generic
mounting /alansun_root
mount.nfs: Network is unreachable
* Starting mDNS/DNS-SD daemon [ OK ]
* Starting bluetooth daemon [ OK ]
* Starting Block the mounting event for NFS filesytems until statd is running [ OK ]
mounting /alansun_usr_tims
* Stopping Block the mounting event for NFS filesytems until statd is running [ OK ]
mount.nfs: Network is unreachable
Skipping profile in /etc/apparmor.
* Starting Block the mounting event for NFS filesytems until statd is running [ OK ]
Skipping profile in /etc/apparmor.
* Stopping Block the mounting event for NFS filesytems until statd is running [ OK ]
mounting /u/i22/
local 7/7 remote 0/0 virtual 10/10 swap 1/1
mountall: mount /alansun_root [973] terminated with status 32
Filesystem could not be mounted: /alansun_root
mountall: mount /alansun_usr_tims [995] terminated with status 32
Filesystem could not be mounted: /alansun_usr_tims
* Starting AppArmor profiles [ OK ]
mounting /alansun_root
* Starting Block the mounting event for NFS filesytems until statd is running [ OK ]
* Stopping Block the mounting event for NFS filesytems until statd is running [ OK ]
* Starting Block the mounting event for NFS filesytems until statd is running [ OK ]
* Stopping Block the mounting event for NFS filesytems until statd is running [ OK ]
mounting /alansun_usr_tims
* Stopping System V initialisation compatibility [ OK ]
* Not starting internet superserver: no services enabled
* Starting Block the mounting event for NFS filesytems until statd is running [ OK ]
* Starting System V runlevel compatibility [ OK ]
* Starting crash report submission daemon [ OK ]
* Starting automatic crash report generation [ OK ]
* Starting ACPI daemon [ OK ]
* Starting anac(h)ronistic cron [ OK ]
* Starting save kernel messages [ OK ]
* Starting regular background program processing daemon [ OK ]
* Starting deferred execution scheduler [ OK ]
* Starting CPU interrupts balancing daemon [ OK ]
* Starting LightDM Display Manager [ OK ]
* Stopping Block the mounting event for NFS filesytems until statd is running [ OK ]
* Starting CUPS printing spooler/server [ OK ]
* Stopping anac(h)ronistic cron [ OK ]
# apt-cache policy nfs-common
nfs-common:
Installed: 1:1.2.5-3ubuntu3.1
Candidate: 1:1.2.5-3ubuntu3.1
Version table:
*** 1:1.2.5-3ubuntu3.1 0
500 http://
100 /var/lib/
1:
500 http://
Please let me know if you need any more info.
I have worked around the problem by running a script during reboot which sleeps for 30 seconds, then mounts any unmounted nsf file systems.
Add to /etc/rc.local :
nohup /usr/local/ bin/nfs_ fix >/tmp/nfs_fix.out 2>&1 &
/usr/local/ bin/nfs_ fix :
#!/bin/ksh
# /usr/local/ bin/nfs_ fix
# Do to timing problem causing some nfs mounts to fail during reboot,
# this script is initiated from /etc/rc.local.
do_fix_nfs()
echo $1 is already mounted
echo Mounting $1
mount $1
{
echo Checking $1
if df | grep $1 >/dev/null ; then
else
fi
}
sleep 30 # wait for networking to start
awk '($3=="nfs") {print $2;}' /etc/fstab |
grep -v '^#' > /tmp/nfs_fix.fs
while read fs ; do
do_fix_nfs $fs
done < /tmp/nfs_fix.fs