• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
Source Digit

Source Digit

Linux, Ubuntu Tutorials & News, Technology, Gadgets & Gizmos

  • Home
  • How To
  • Ubuntu
  • Instagram
  • Blogging
  • Android
  • WordPress
  • +More
    • Cloud Computing
    • Gadgets
    • Social Media
    • Technology
  • Write for Us

Free AI Courses With Certificate For Beginners In India

There are a variety of free AI courses with certificate for beginners in India. Whether you're looking to enhance your skills or start from scratch, you can find numerous free AI courses with … [Read More...] about Free AI Courses With Certificate For Beginners In India

Home / How To / Fix Unexpected Inconsistency By Running Fsck Manually From Initramfs

Fix Unexpected Inconsistency By Running Fsck Manually From Initramfs

By Sourabh / January 14, 2026 Category: How To, Ubuntu

How to fix unexpected inconsistency; run fsck manually fsck exited with status code 4. Easiest way is to run fsck manually in Linux from Initramfs.

Run Fsck Manually In Linux From Initramfs

Before you begin, identify the partition. When dropped into the (initramfs) prompt, the system message usually indicates which partition has errors (e.g., /dev/sda1, /dev/mapper/ubuntu–vg-root).


sudo umount /dev/sdb
sudo fsck /dev/sdb

NOTE: Replace the “/dev/sdb” with the partition showing error or replace /dev/sdb with the device you want to unmount.

You can also run “sudo fsck -py /dev/sdb” where:

  • -p will automatically apply repairs
  • -y flag is to fix all correctable errors without manual interaction for each prompt.
  • -f flag to force a check even if the filesystem appears clean.

If you do not specify a filesystem with the command, it will analyze the fstab file (/etc/fstab).

If you wish to run fsck on all filesystems at once, run the command “fsck -AR”.

Note:

  1. Run the fsck command as root user
  2. Unmount the device before running fsck

Remember to unmount the device/disk befor you execute fsck command as it may damage your files. Whenever you try running fsck on a mounted device, you should see an error like this: fsck from util-linux 2.34 e2fsck 1.45.5 (28-aug-2023) /dev/sda3 is mounted. e2fsck: Cannot continue, aborting.

Upon successful execution of the command, you will see the total number of fies and clusters on the device/partition “/dev/sda3: 5 files, 1967/1972 clusters”

unexpected inconsistency; run fsck manually fsck exited with status code 4

If you are getting an error “unexpected inconsistency; run fsck manually”, you will have to follow the steps given below:

  1. Type exit into the prompt – it will tell you which partition has an error, e.g. /dev/sda6.
  2. Type fsck /dev/sdaX -y where X is the partition mentioned in the error.
  3. Once it has finished, type reboot into the prompt, and if prompted, select to continue normal startup.

NOTE: If you are getting an error “/dev/sda3 is mounted.”, follow the steps given above to umount and the run fsck command manually.

Repeat if Necessary – If the command reports errors were fixed, run the fsck command again until it reports that the filesystem is clean or no more errors are found.

Once you get back to the normal startup, open terminal and run the following commands: sudo apt-get update sudo apt-get clean sudo apt-get update sudo apt-get upgrade

That’s all, reboot the system again. Type exit at the (initramfs) prompt. Now the system will typically attempt to resume the normal boot process automatically.

If not, you can manually type reboot to restart the system. Your system should now boot normally.

Primary Sidebar

Latest Posts

Best AI Plugins For WordPress To Use In 2026

3 Commands To Check USB Connection In Linux Terminal

Linux Terminal Commands for Beginners With Examples

How To Password Protect A Folder In Linux Command Line

Best Download Managers for Ubuntu Linux (2026 Edition)

5 Best Free Keyword Research Tools for Bloggers in 2026

How To Check Linux 32 or 64-Bit Command Line

How To Delete And Remove Repository In Ubuntu Terminal

How To Delete And Remove Files Older Than 7 Days In Linux

Install and Use GitHub Desktop on Ubuntu Linux

© 2026 Source Digit • Linux, Ubuntu Tutorials & News, Technology, Gadgets & Gizmos

  • Home
  • About
  • Privacy Policy
  • Terms & Conditions
  • Contact Us
  • Sitemap