RHEL7 - Cannot boot with XFS_WANT_CORRUPTED_GOTO error

I've been using the RHEL7.3 system for more than 1 year, suddenly system failed to boot up, hanging somewhere right before UI pops up for password input. 

Issue

  • System halts during boot after showing:
XFS: Internal error XFS_WANT_CORRUPTED_GOTO at line 1596 of file fs/xfs/xfs_alloc.c. Caller xfs_free_extent+0h4n/0xyuU [xfs]
XFS (dm-2): Corruption of in-memory data detected. Shutting down filesystem
XFS (dm-2): Please umount the filesystem and rectify the problem(s)
  • System cannot boot due to corrupted XFS root filesystem

Resolution

  • The file system repair tool needs to be run on the XFS file system. However, if this file system is the root file system this must be done in rescue mode. This is because the file system must be unmounted to perform repairs, yet the root file system cannot be unmounted while the system is running.

1.     Boot the system from the binary DVD or an USB disk. Once the system has successfully booted from the ISO image and Red Hat Enterprise Linux boot screen will appear. Choose the "Troubleshooting"menu, followed by "Rescue a Red Hat Enterprise Linux system"

2.     Repair the filesystem with xfs_repair:

# xfs_repair /dev/rhel/root

3.     In the event xfs_repair cannot repair the file system due to a dirty log, with error:

mount /dev/rhel/root /mnt failed. Structure needs cleaning.

 it must be cleared. This is typically done by with a mount and unmount of the XFS file system.

# mount /dev/rhel/root /mnt
# umount /dev/rhel/root
# xfs_repair /dev/rhel/root

4.     If the last two steps were unsuccessful, the log may be corrupt and cannot be replayed, use the -L option (force log zeroing) to clear the log.

# xfs_repair -L /dev/rhel/root

Finally, exit the rescue mode and boot the system normally.


Referred to: https://access.redhat.com/solutions/2018903

 
  

你可能感兴趣的:(Linux)