Kernel panic - not syncing: VFS: unable to mount root fs on unknown-block(8,7)

Open
#3,465 41 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
18/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
linux

Research direction

Start with the boot configuration in /boot/cmdline.txt and the reported root device /dev/sda7, then review the kernel panic and the e2fsck command and result described in the update. Done would mean identifying whether the failure is attributable to the external USB root filesystem or boot configuration and documenting a reproducible diagnosis or fix.

Written by the indexing model from the issue text.

Description

Raspbian 10 and RPi4

It happened for several time, that i seen some errors that given me a suggestion like file system disconnected.

But this time after power cycling, it failed to start showing error:
Kernel panic - not syncing: VFS: unable to mount root fs on unknown-block(8,7)

as seen on the screenshot:
sudden-boot-fail-raspbian10

My system partition is on the external USB drive (made by clonning system SD card using Raspbian built in GUI disk cloner tool and then: sudo sed -i "s/mmcblk0p7/sda7/g" /boot/cmdline.txt
It worked good, numerous reboots, but suddenly fails.

What is the easiest way to discover cause or to likely fix it without clean install please?

>>> UPDATE <<<:

what worked was to unmount root partition and run following command on it: e2fsck -f -y -v -C 0 /dev/sda7
(replace partition path if you have different - command: lsblk)

Dominant language
C
Stars
13.2k
Forks
5.5k
Avg merge
2d 21h
Merged PRs (30d)
21

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from raspberrypi/linux

All issues in raspberrypi/linux

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.