RHEL7.0 Storage Foundation 6.2 (SF6.2) system will not boot into multi-user, and boots into maintenance mode/emergency mode. VxFS filesystems not mounted at boot time.

book

Article ID: 100014656

calendar_today

Updated On:

Description

Error Message

 

The system will not boot and will drop into emergency mode/maintenance mode. Related to this, adding the “nofail” option to the mount options in /etc/fstab will allow the system to boot into multiuser, but the system will not mount any of the VxFS filesystems in /etc/fstab that have the “nofail” option set. So the system could be booting, but not mounting any VxFS filesystems, this is addressed in the solutions section below.

Cause

 

Because of changes in the boot sequence introduced in RHEL 7 (systemd), VxVM volumes may not be available to the Operating System when initial parsing of /etc/fstab occurs. Thus any entries in the /etc/fstab file that have a filesystem type of vxfs will not be available; this will produce an error that drops the system into emergency mode (also sometimes referred to as maintenance mode or recovery mode). IE, the system will not boot into multiuser mode.

Resolution

 

There are two solutions listed here, the first addresses the system not booting to multiuser, the second addresses the system not mounting the VxFS filesystems at boot time, there is an example for each as well.
To allow the system to boot into multi-user mode use the “nofail” mount option for the VxFS filesystem on the VxVM volume. The “nofail” mount option avoids the boot failure. As a result of this workaround, it’s likely that no VxFS filesystems will be mounted when the system reaches multiuser mode, so please continue to the solution for mounting the filesystems at boot.
Example of changes that need to be made to /etc/fstab to boot multiuser:
All VxFS filesystems listed in /etc/fstab must have the “nofail” option added to the mount options similar to this:
/dev/vx/dsk/cdg/cvol /cvol      vxfs    defaults ,nofail         1 2
 
The following default /etc/fstab will cause the host to fail into emergency/maintenance mode and needs to be modified as shown.
bash# cat /etc/fstab
 
#
# /etc/fstab
# Created by anaconda on Wed Jun 25 12:13:43 2014
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
UUID=9ff7aaf0-358a-49dc-a43b-cb51dfe4713b /                       ext4    defaults        1 1
UUID=2a43b96b-5a02-4300-9202-dcb1b2c9b980 swap                    swap    defaults        0 0
 
# Note: When adding or modifying VxFS or VxVM entries, add 'nofail'
# to the mount options to avoid boot failure during system bootup
# if systemd tries to mount filesystem before VxVM and VxFS have
# started.
/dev/vx/dsk/cdg/cvol /cvol      vxfs    defaults        1 2
 
The last line in this file needs to be edited to look like this:
/dev/vx/dsk/cdg/cvol /cvol      vxfs    defaults ,nofail         1 2
 
 
In order for the VxFS filesystems to be mounted at boot time, either install SFHA 6.2.1 (that contains a fix for this issue) or use a workaround: the command “mount -at vxfs” can be run after the system reaches multiuser mode. 

Below is an example for setting up /etc/rc.d/rc.local to do this at boot time.
 
Example of how to mount the VxFS filesystems at boot:
The following steps activate the new rc-local Systemd service and configure it to mount the VxFS filesystems at boot time.
First, edit /etc/rc.d/rc.local and include the following line at the end of this file:
/usr/bin/mount -at vxfs > /dev/null 2>&1
 
Then add the execute permission to /etc/rc.d/rc.local as follows:
bash# chmod u+x /etc/rc.c/rc.local
You can test these changes by running this command:
bash#  systemctl start rc-local
All the VxFS filesystems should now be mounted, and should be mounted at the next reboot.
Here is what a modified /etc/rc.d/rc.local file looks like:
# cat /etc/rc.d/rc.local
#!/bin/bash
# THIS FILE IS ADDED FOR COMPATIBILITY PURPOSES
#
# It is highly advisable to create own systemd services or udev rules
# to run scripts during boot instead of using this file.
#
# In constrast to previous versions due to parallel execution during boot
# this script will NOT be run after all other services.
#
# Please note that you must run 'chmod +x /etc/rc.d/rc.local' to ensure
# that this script will be executed during boot.
 
touch /var/lock/subsys/local
/usr/bin/mount -at vxfs > /dev/null 2>&1
 
 

Applies To

 

Storage Foundation 6.2 (SF6.2, SFHA6.2, SFCFSHA6.2) running on Redhat Enterprise Linux version 7 (RHEL 7), with VxFS filesystems listed in /etc/fstab.

Issue/Introduction

 
On RHEL 7 system the /etc/fstab entries for VxFS filesystem on the VxVM volume does not mount during the boot-up phase (3587126)
On RHEL 7 when entries are added in the file systems table (/etc/fstab) for VxFS file system on the VxVM volume, the system enters into emergency mode during the system boot-up phase. This occurs because the systemd daemon is not able to find the VxVM volume while processing the /etc/fstab file.