"Failed to start file system check on /dev/disk..." error on Photon OS based virtual appliances
book
Article ID: 326323
calendar_today
Updated On:
Products
VMware Cloud FoundationVMware vCenter Server
Issue/Introduction
Symptoms:
After rebooting a Photon OS based virtual appliance (vCenter Server Appliance for example), executing any commands on the shell (emergency mode) fails.
The appliance fails to start and and you see an error similar to:
[FAILED] Failed to start File System Check on /dev/dis...uuid/7986780-8987- See 'systemctl status systemd-fsck-root.service' for details. [DEPEND] Dependency failed for /sysroot. [DEPEND] Dependency failed for Initrd Root File System. [DEPEND] Dependency failed for Reload Configuration from the Real Root.
Note: The preceding log excerpts are only examples. Date, time, and environmental variables may vary depending on your environment.
Environment
VMware Cloud Foundation 2.x
VMware vCenter Server 7.0.x
VMware vCenter Server Appliance 6.7.x
VMware vCenter Server Appliance 6.5.x
Cause
This issue occurs when there is a storage failure or power failure causing file inconsistencies.
Resolution
To resolve this issue, scan and correct the filesystem:
Caution: Before proceeding, take a snapshot or backup of the affected virtual appliance.
Reboot the virtual appliance, and immediately after the OS starts, press e to open the GNU GRUB Edit Menu.
Locate the line that begins with the word linux.
Option 1
At the end of the line, add fsck.repair=yes then reboot the appliance. This will force the default filesystem check to auto-resolve any issues, and does not require emergency mode.
Option 2
At the end of the line, add systemd.unit=emergency.target Example:
Press F10 to continue booting.
Find the filesystems by running these commands:
/bin/sh
/bin/mount
blkid
Note: You will see the list of devices mounted with the disk uuid.
Run this command against the mount point that has issue:
e2fsck -y /dev/sda3
Note: The -y switch will fix the nodes automatically. Replace /dev/sda3 with the mount point that has the issue.