LCD-show icon indicating copy to clipboard operation
LCD-show copied to clipboard

Kernel panic-not syncing: VFS: unable to mount root fs on unknown- block(179,2) running Raspbian on top of NOOBS

Open PagesByZ opened this issue 6 years ago • 38 comments

I already have Raspbian through NOOBS installed and whenever I install the LCD-show driver, i get the following error during reboot after installation:

 `Kernel panic-not syncing: VFS: unable to mount root fs on unknown- block(179,2)`

Any idea what is the issue and how I can fix it? I already have Raspbian OS 2017-11-29 version of NOOBS.

PagesByZ avatar Jan 13 '18 01:01 PagesByZ

The reason is that NOOBS has the rootfs in another partition. Mount your sd card in your pc, open the cmdline.txt with an editor (not Word or Wordpad!!) and change the term after rootfs (should be mmcblk0px) to mmcblk0p7.

Am 13.01.2018 2:15 vorm. schrieb "Zahid Hasan" [email protected]:

I already have Raspbian through NOOBS installed and whenever I install the LCD-show driver, i get the following error during reboot after installation:

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

Any idea what is the issue and how I can fix it? I am installing 2017-11-29 version of NOOBS.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/goodtft/LCD-show/issues/60, or mute the thread https://github.com/notifications/unsubscribe-auth/ATJ17WSxCULY6gE34hEE468g2L-Gc6J8ks5tKAPHgaJpZM4RdC3p .

lavolp3 avatar Jan 13 '18 10:01 lavolp3

thanks @lavolp3, this fixed the issue for me!

nikomaresco avatar Jan 22 '18 22:01 nikomaresco

Hi i am new to raspberry pi. I am wondering where do you find cmdline.txt in the files

Dj-Ale-426 avatar Feb 02 '18 03:02 Dj-Ale-426

@lavolp3 i just found the cmdline.txt but there is no rootfs and mmcblk0px

Dj-Ale-426 avatar Feb 02 '18 03:02 Dj-Ale-426

The cmdline.txt is in the boot directory and can also be editet in Windows (using notepad or notepad++) What do you find in there. Can you paste it.

Another way around this issue would be to setup the system again from scratch and use my fork here. I have included a NOOBS case creating the right cmdline.txt and avoiding the kernel panic

lavolp3 avatar Feb 02 '18 08:02 lavolp3

@lavolp3 thanks for helping me

Dj-Ale-426 avatar Feb 03 '18 15:02 Dj-Ale-426

@lavolp3 I see you have a lot of code commented out at the bottom of https://github.com/lavolp3/LCD-show/blob/master/LCD35-show, can it be used if I use your repo rather then this one?

dotps1 avatar Feb 03 '18 18:02 dotps1

The reason is I don't understand what the if statement does. From my understanding the version check and resulting commands were necessary for older raspbian wheezy versions but are not anymore now. So I changed it so the necessary commands get executed w/o the check for a version. I'm not 100% sure it works so I just commented out the old code without deleting it. Please try it out if you like.

Am 03.02.2018 7:36 nachm. schrieb "Thomas Malkewitz" < [email protected]>:

@lavolp3 https://github.com/lavolp3 I see you have a lot of code commented out at the bottom of https://github.com/lavolp3/ LCD-show/blob/master/LCD35-show, can it be used if I use your repo rather then this one?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/goodtft/LCD-show/issues/60#issuecomment-362843311, or mute the thread https://github.com/notifications/unsubscribe-auth/ATJ17T0QMZi-JUJuO4NpAM8q5c9FMsC9ks5tRKc6gaJpZM4RdC3p .

lavolp3 avatar Feb 03 '18 22:02 lavolp3

@dotps1 The code works on my Pis as it is.

lavolp3 avatar Feb 03 '18 22:02 lavolp3

@lavolop3 yes I can paste in code. If it is not a bother can you type how the cmdline.txt is supposed to look so I can paste it in.

Dj-Ale-426 avatar Feb 06 '18 22:02 Dj-Ale-426

@ lavolp3 yes I can paste in code. But if it is not bother can you type how the codling.txt is supposed to look like.

Dj-Ale-426 avatar Feb 10 '18 16:02 Dj-Ale-426

@Dj-Ale-426 dwc_otg.lpm_enable=0 console=tty1 console=ttyAMA0,115200 root=/dev/mmcblk0p7 rootfstype=ext4 elevator=deadline rootwait fbcon=map:10 fbcon=font:ProFont6x11 logo.nologo

Basically the same cmdline.txt as in this git but for noobs you need mmcblk0p7 to be the root partition instead of mmcblk0p2

lavolp3 avatar Feb 10 '18 16:02 lavolp3

@lavolp3 the thing is I tried your git but it just displayed kernel panic not syncing

Dj-Ale-426 avatar Feb 10 '18 17:02 Dj-Ale-426

@Dj-Ale-426 Sorry for the long silence. Please, point out, what exactly you did: Which Raspbian did you use (jessie, strech? lite or full?)? What did you do to install the display? Step-by-step please.

lavolp3 avatar Feb 28 '18 12:02 lavolp3

Hi sorry I had noobs installed so I quickly fiqured ou the problem. Thanks for your concern. Also is it okay if I use the lite version of raspian

Dj-Ale-426 avatar Mar 01 '18 04:03 Dj-Ale-426

Also for noobs can you just adjust the cmdline.txt

Dj-Ale-426 avatar Mar 01 '18 04:03 Dj-Ale-426

This fixed it for me. Try this first.

crashflow avatar Mar 02 '18 12:03 crashflow

I feel like this needs to be posted:

dwc_otg.lpm_enable=0 console=tty1 console=ttyAMA0,115200 root=/dev/mmcblk0p7 rootfstype=ext4 elevator=deadline rootwait fbcon=map:10 fbcon=font:ProFont6x11 logo.nologo

this fixes your noob install. and why is there 52 issues for a driver for a device I can buy on amazon. maybe fix this?

dotps1 avatar Mar 18 '18 04:03 dotps1

@dotps1 will this work for noobs lite too.

Dj-Ale-426 avatar Apr 03 '18 01:04 Dj-Ale-426

Hello!!! I am new to raspberry. I have the same problem Kernel Panic: VFS : Unable to mount root fs on unknown-block 179,2 but when i open the cmdline.txt didnt find any mmcblk0p7 in there. Please help !!!

antonisss avatar May 09 '19 08:05 antonisss

can you post your cmdline.txt here?

lavolp3 avatar May 09 '19 12:05 lavolp3

i have a very similar problem; cmdline.txt - dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=43c1e3bb-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet init=/usr/lib/raspi-config/init_resize.sh splash plymouth.ignore-serial-consoles

version - April 2019 -Raspbian Stretch with desktop and recommended software kenel version - 4.14

first time using a raspberry pi, using b3+, didn't want to get noobs because of the size.

NedAckland avatar May 09 '19 15:05 NedAckland

Are you booting from an external device?

NedAckland [email protected] schrieb am Do., 9. Mai 2019, 17:55:

i have a very similar problem; cmdline.txt - dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=43c1e3bb-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet init=/usr/lib/raspi-config/init_resize.sh splash plymouth.ignore-serial-consoles

version - April 2019 -Raspbian Stretch with desktop and recommended software kenel version - 4.14

first time using a raspberry pi, using b3+, didn't want to get noobs because of the size.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/goodtft/LCD-show/issues/60#issuecomment-490962355, or mute the thread https://github.com/notifications/unsubscribe-auth/AEZHL3MIQE7AQTNXHFQ56BDPURCOVANCNFSM4ELUFXUQ .

lavolp3 avatar May 09 '19 16:05 lavolp3

no i am not booting from external device

antonisss avatar May 09 '19 16:05 antonisss

booting from the pi

NedAckland avatar May 09 '19 18:05 NedAckland

Well I don't know where it is from but the root=PARTUUID hints to a boot from an external partition. For sure it is the reason why the pi won't boot. Google it. My suggestion : overwrite the /boot /cmdline.txt with the one from this repository /usr/cmdline.txt. Make a backup of the original one first. Boot and see what happens. If it boots consider running the LCD-show script again.

lavolp3 avatar May 09 '19 18:05 lavolp3

thank you, will try this

NedAckland avatar May 09 '19 19:05 NedAckland

will try

antonisss avatar May 09 '19 21:05 antonisss

@NedAckland hi, i have the same problem as you, have you sovled this trouble?

DUANBEN avatar May 19 '19 11:05 DUANBEN

i did solve it, as long as you dont have data on the sd, you can fully over write it using sd card formatter (i did the full over write rather than then quick one) then using etcher i re put rasbian on the sd and booted it up again. this is what worked for me in the end.

On Sun, May 19, 2019 at 12:21 PM DUANBEN [email protected] wrote:

@NedAckland https://github.com/NedAckland hi, i have the same problem as you, have you sovled this trouble?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/goodtft/LCD-show/issues/60?email_source=notifications&email_token=ALRE3EGWRVNCLCFG4YQX66TPWEZ3DA5CNFSM4ELUFXU2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODVXAB7Y#issuecomment-493748479, or mute the thread https://github.com/notifications/unsubscribe-auth/ALRE3EG2MTCLOGXJ3GYYD6LPWEZ3DANCNFSM4ELUFXUQ .

NedAckland avatar May 19 '19 13:05 NedAckland

i tried it this way, but it didn't work for me....

thank you anyway :)

DUANBEN avatar May 20 '19 14:05 DUANBEN

I had the same problem and managed to fix it. I want to explain the situation and the fix. The situation occurs because of the interaction of Noobs and The LCD-show scripts. The problem is the SD card partitions which are set up by Noobs versus those set up if you put Raspbian onto an SD card without Noobs. The basic setup of operating systems disks (SD card or other) on the Raspberry Pi is to have 2 partitions - a boot partition and a root partition. If Raspbian is alone, the boot partition is partition 1 and the root partition is partition 2. With Noobs, the boot partition of the first-loaded operation system is #6 and the root partition is #7. The LCD-show scripts hard-code the root partition to be 2. The fix to this problem is mostly explained above. You will need an operating computer OS and an SD card reader-writer. You can use the Pi itself if you have a 2nd SD card with a working Linux or Raspbian OS and a USB SD card reader. If you use OSX (for the Mac) or Linux, you can use it without extra software. If you use Windows, you'll need Cygwin or other software to read and write the non-Windows filesystem ext4. You need to understand the partitioning scheme of the SD card. Typically, Noobs sets up 2 partitions per OS starting with partition6, and installs Raspbian onto partitions #6 (boot) and #7 (root). You will need to "mount" Raspbian boot partition using the CLI of Mac/Linux "mount" command and to use an editor such as nano to edit the single line of cmdline.txt, changing the "root=/dev/mmcblk0p2" to "root=/dev/mmcblk0p7", or other "mmcblk0px" where x is 1 more than the Raspbian boot partition. Then umount the SD card, put it into the Pi, and reboot.

rprior04938 avatar May 25 '19 12:05 rprior04938

hey i'm trying to install Kali in rasp pi Zero w, it's showing "end kernal panic not sync: VFS: unable to mount root fs on unknown-block(179,2)

varshan97 avatar Feb 23 '20 13:02 varshan97

can you post your cmdline.txt here?

Hello sir I am new to raspberry. I have the same problem Kernel Panic: VFS : Unable to mount root fs on unknown-block 179,2 but when i open the cmdline.txt didnt find any mmcblk0p7 in there. Please help !!! please help me

irfan12345678 avatar May 18 '20 11:05 irfan12345678

See my posting from 2018 in the GitHub discussion. The part of the line in cmdline.txt (found on the boot partition of the SD card, typically /dev/mmcblk0p6, the 6th partition of the card if the SD card was created by NOOBS) created by NOOBS, is /dev/mmcblk0p7, the 7th partition of the card. It points to the Linux root partition. If the root partition is some other place, it can't be found and you get a kernel panic.

If you don't have access to another way to access the Linux partitions of your SD card, I'd suggest that you start over with a fresh download and burn to the card of Raspbian or other pi Linux OS.

On Mon, May 18, 2020 at 7:42 AM irfan12345678 [email protected] wrote:

can you post your cmdline.txt here?

Hello sir I am new to raspberry. I have the same problem Kernel Panic: VFS : Unable to mount root fs on unknown-block 179,2 but when i open the cmdline.txt didnt find any mmcblk0p7 in there. Please help !!! please help me

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/goodtft/LCD-show/issues/60#issuecomment-630126116, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIF3RYF6QSCS3TJREYV5E7TRSENMDANCNFSM4ELUFXUQ .

rprior04938 avatar May 18 '20 13:05 rprior04938

Kernel panic-not syncing: VFS: unable to mount root fs on unknown- block(179,2) how can i fixed this error with my cmdline.txt? console=serial0,115200 console=tty1 root=PARTUUID=566d1a16-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait

jn7779 avatar May 17 '21 23:05 jn7779

Kernel panic-not syncing: VFS: unable to mount root fs on unknown- block(179,2) how can i fixed this error with my cmdline.txt? console=serial0,115200 console=tty1 root=PARTUUID=566d1a16-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait Did you find a solution?

ChrBlad avatar Dec 20 '21 12:12 ChrBlad

I have try some of the solution, but she like my SD card might be corrupted.

On Mon., Dec. 20, 2021, 7:56 a.m. ChrBlad, @.***> wrote:

Kernel panic-not syncing: VFS: unable to mount root fs on unknown- block(179,2) how can i fixed this error with my cmdline.txt? console=serial0,115200 console=tty1 root=PARTUUID=566d1a16-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait Did you find a solution?

— Reply to this email directly, view it on GitHub https://github.com/goodtft/LCD-show/issues/60#issuecomment-997899647, or unsubscribe https://github.com/notifications/unsubscribe-auth/AOJ2KPGXE4CLS3HC7NH6F53UR4RXFANCNFSM4ELUFXUQ . You are receiving this because you commented.Message ID: @.***>

jn7779 avatar Dec 20 '21 13:12 jn7779