Kernel panic - not syncing: VFS:

Started by rmario, October 13, 2016, 07:38:43 pm

Previous topic - Next topic

rmario

Hello,

I successfully partitioned a SD card like in this tutorial
https://olimex.wordpress.com/2012/09/06/imx233-olinuxino-get-started-making-the-arch-linux-sd-card/

Now I made a 3'rd partition, VFAT, but Windows isn't able to see it.
I've read that for external drivers, first partition must be VFAT.

So I re-partitioned the SD, making
/dev/sdb1          2048  8390655 8388608    4G  c W95 FAT32 (LBA)
/dev/sdb2  *    8390656  8521727  131072   64M 53 OnTrack DM6 Aux3
/dev/sdb3       8521728 15564799 7043072  3,4G 83 Linux


Now, the kernel isn't able to see the rootfs
mxs-rtc mxs-rtc.0: setting system clock to 1970-01-01 00:51:21 UTC (3081)
RAMDISK: Couldn't find valid RAM disk image starting at 0.
Waiting for root device /dev/mmcblk0p2...
mmc0: new high speed SDHC card at address 0007
mmcblk0: mmc0:0007 SD08G 7.42 GiB
mmcblk0: p1 p2 p3
List of all partitions:
b300         7782400 mmcblk0 driver: mmcblk
  b301         4194304 mmcblk0p1
  b302           65536 mmcblk0p2
  b303         3521536 mmcblk0p3
No filesystem could mount root, tried:  ext2 ext3 ext4
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(179,2)


Card is OK, I just inserted in ubuntu and /dev/sdb3 (rootfs) is mounted ok.

I presume that this is the problem:
Kernel command line: console=ttyAMA0,115200 root=/dev/mmcblk0p2 rw rootwait ....

But how can I instruct kernel to use /dev/mmcblk0p3 insetad of mmcblk0p2 ?

In U-Boot there was some option to pause the boot process and modify the args.
How can I solve here?

Thanks in advance,








swahren

You need to change the kernel command in the bootloader (U-Boot or imx-bootlets depending what your using). Since this isn't a trivial task i suggest to remove VFAT partition.

rmario

I'm using imx-bootlets

Linux-alarm-2.6.35-6-ARCH.img
ArchLinuxARM-olinuxino-latest-rootfs.tar.gz

Appreciate any guidance for this. I really need to keep VFAT as first partition since I cannot instruct client to hack windows through registry for seeing the card.

Most likely I should rebuild Linux-alarm-2.6.35-6-ARCH.img.
Maybe a silly question, can I just unpack the image, make mods then repack as a dirty fix?

lambda

I think if you keep the rootfs on the second partition and move the kernel to the third, it should work.

If it doesn't, you need to build the images yourself or get rid of windows.

HTH,
Harald