12
2
I'm not sure when/why this started happening, but I have a RAID array entered in my /etc/fstab
to mount on boot to /mnt/data
. Up until today everything has been fine, and it's been that way for several years!
Anyway, I rebooted the server today (CentOS 7) and it went into "emergency mode". After checking journalctrl
the following entries existed:
Feb 01 13:04:45 CentOS7 systemd[1]: Mounting /mnt/data...
Feb 01 13:04:45 CentOS7 mount[819]: mount: /dev/md126 is already mounted or /mnt/data busy
Feb 01 13:04:45 CentOS7 systemd[1]: Failed to mount /mnt/data.
However, if I remove the line from /etc/fstab
and reboot (which starts normally), then re-enter the line, and run mount -a
then it mounts OK.
Any reason why it's failing on boot?
I've added errors=continue
as an option to the line in /etc/fstab
which prevents a reboot entering emergency mode (and strangely mounts the drive anyway – presumably in a later step), but as there are other mounts I would like to perform on boot which depend on that one being mounted initially, so really I'd like to find a proper solution.
1can you post the entire fstab file please – d4v3y0rk – 2017-09-28T17:07:35.387
Is it possible something mounts /mnt/data in a script, like rc.local, that runs after the fstab mount? That would show those errors in the journal and cause the system to not boot properly. Is /mnt/data empty and not being accessed? If something is trying to write to that area when the mount occurs, it will cause this error as well. Some process that starts on boot may have it's log file set to /mnt/data/log, for example. Just a few idea. – Peter Berbec – 2017-10-02T17:58:23.980
Could you please post your: cat /etc/fstab And with your line inside fstab, after a reboot. Please post the content of: dmesg – hrdy – 2017-10-05T14:08:39.433
Did you, by any chance, updated from Centos 6 to Centos 7? As Centos 7 is only around for a little over 2 years... – mikky – 2017-11-04T23:16:49.610