LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-03-2014, 02:12 PM   #1
slack_
Member
 
Registered: Oct 2013
Distribution: Slackware, Arch
Posts: 105

Rep: Reputation: Disabled
VFS: Kernel Panic with Slackware LUKS + LVM


I just installed Slackware 14.1 with LUKS and LVM full disk encryption. I'm running into a problem similar to this: http://postimg.org/image/3nvdh48ex/ and can't find anything that seems to resolve the problem. This is the specific error:
Code:
VFS: Unable to mount root fs on unknown-block(253,1)
Pretty much the same as in that image. Here's my lilo.conf:
Code:
boot = /dev/sda
...
image = /boot/vmlinuz-generic-3.10.17
    initrd = /boot/initrd.gz
    root = /dev/shadowvg/root
    label = Slackware
    read-only
The mkinitrd command:
Code:
mkinitrd -c -k 3.10.17 -f ext4 -r /dev/shadowvg/root -m mbcache:jbd2:ext4 -C /dev/sda2 -L -u -o /boot/initrd.gz
Then I run lilo to reinstall. Once I reboot it starts up and I get that error. Now, something I noticed is that upon startup, the menu entry still says 'Linux' even though I specified it as Slackware in /etc/lilo.conf. So it seems to be that the system isn't even using the lilo.conf that I created. Why? What lilo.conf IS it using then? How do I fix this?

EDIT: Also, if I reboot and chroot back in to try and fix things, I find that there is nothing at all in the /boot dir. Not sure if this is normal but it doesn't seem to be.

Last edited by slack_; 09-03-2014 at 02:17 PM.
 
Old 09-03-2014, 02:38 PM   #2
maciuszek
Member
 
Registered: Nov 2010
Location: Toronto, Ontario
Distribution: Slackware + FreeBSD
Posts: 165

Rep: Reputation: 40
You mounted your boot partition for the install?
 
Old 09-03-2014, 02:51 PM   #3
naitso
LQ Newbie
 
Registered: Aug 2010
Posts: 14

Rep: Reputation: 2
Have you read the README file?
http://www.slackware.at/data/slackware-14.1/README_CRYPT.TXT
 
Old 09-03-2014, 02:51 PM   #4
slack_
Member
 
Registered: Oct 2013
Distribution: Slackware, Arch
Posts: 105

Original Poster
Rep: Reputation: Disabled
Yes when it got to the part in setup where it asks where to mount everything, I created the mounts as such:
Code:
/dev/shadowvg/root    /
/dev/shadowvg/home    /home
/dev/sda1             /boot
The computer is paritioned like this:
Code:
/dev/sda1    boot         100mb
/dev/sda2    crypto_LUKS  100gb < Where system is to be installed
/dev/sda3    not used     300gb
I didn't mount /dev/sda3 anywhere because I don't want it to be part of the Linux root. I did not use /dev/sda3 at all or mount it anywhere in the fs. So that shouldn't matter at all.

EDIT: Yes, I've read the README file. I've done this before and it worked just fine. That's why I am posting here because I have no idea why it simply didn't work this time. I wrote down a bunch of notes on exactly how to do this so there doesn't seem to be much way I could screw it up if the notes worked for me the first time.

EDIT: I also noticed that everywhere it says that installing lilo the first time will fail. That doesn't happen to me. I still exit the setup but wait to reboot so I can do this: http://www.jveweb.net/en/archives/20...ypted-lvm.html

Down where it says 'Fixing lilo'.

Last edited by slack_; 09-03-2014 at 02:59 PM.
 
Old 09-04-2014, 05:44 AM   #5
michaelslack
Member
 
Registered: Feb 2013
Location: Sydney
Distribution: slackware
Posts: 110

Rep: Reputation: 36
I can't easily see a reason for the problem. But it seems unable to find and/or mount your root partition.

One question: did you run alienBOB's mkinitrd script to get that mkinitrd command? One thing it does is work out all the kernel modules you need to mount your root partition. I see you put a few modules there. Maybe more are needed though?

I use LVM + LUKS on external USB drives and it took me a while to get it working. One thing I needed was to add -w 5 to the mkinitrd command to give the machine time to mount the external disk. Now it ought not be needed for you (using /dev/sda) but before I did that it would give this kind of error. Maybe adding a short wait will help?

Sorry I can't think of anything else immediately.

Michael

Last edited by michaelslack; 09-04-2014 at 05:46 AM.
 
Old 09-04-2014, 07:04 PM   #6
maciuszek
Member
 
Registered: Nov 2010
Location: Toronto, Ontario
Distribution: Slackware + FreeBSD
Posts: 165

Rep: Reputation: 40
Check if your boot partition is truly empty if so the partition was not mounted for the install thereby leaving the boot in your encrypted root partition.
you can move the files to the unencrypted boot and have fstab handle the mounting of it.

there won't be an issue of the kernel-* packages or any other package that include this folder since all management will be post fstab.

In the case where it is populated did you generate your initrd including all such arguments: -c -k <kernel version> -m <modules> -f <root fs type> -r /dev/<volume group name>/<root lv name> -C /dev/<physical encrypted block> -L

and of course did you add the initrd to whatever bootloaders conf?
 
Old 09-05-2014, 03:09 PM   #7
yozh
Member
 
Registered: Apr 2009
Posts: 32

Rep: Reputation: 0
Hi Slack..

Facing the same problem right here, right now, funny thing is that it worked once, but couldt type the disks unlock passphrase because module usbhid hid and ehci, so i rebuilt initrd.gz but got the same error youre having.

I was wondering that maybe we need to add crypto/luks and required lvm modules into the initrd.gz
i dont know the name of the modules, so if someone can hook us up with the kernels modules name would be great, anyway those are just my 2 cents, i actually dont know if it can be accomplished or not.

yozH

Last edited by yozh; 09-05-2014 at 05:45 PM. Reason: typo
 
Old 09-05-2014, 04:46 PM   #8
maciuszek
Member
 
Registered: Nov 2010
Location: Toronto, Ontario
Distribution: Slackware + FreeBSD
Posts: 165

Rep: Reputation: 40
Oh.. did you add your root partition to crypttab?

Edit: wait we're talking about lvm right.. hrm i honestly just played with lvm crypt a few years back and dont use it anymore. sadly i cant remember if i added
Code:
slackluks /dev/<physical encrypted blockk> none luks
to crypttab

*slackluks being the naming used in README_CRYPT.TXT

or if it's even needed.. i can assume how it mighhht be needed, but i know nothing about the crypt lvm internals

Last edited by maciuszek; 09-05-2014 at 04:49 PM.
 
Old 09-06-2014, 03:45 AM   #9
yozh
Member
 
Registered: Apr 2009
Posts: 32

Rep: Reputation: 0
Slack__:

Try replacing your root device "/dev/shadowvg/root" with "/dev/sda2" in mkinitrd command, for me it worked.

The problem is that initrd looks for a non existent root device in that stage yet.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Gentoo, LUKS, LVM - kernel panic - not syncing /init not found mechman422 Linux - Kernel 1 10-23-2010 01:15 AM
[SOLVED] Kernel update on LUKS and LVM encrypted Slackware, mount fails KMBS Slackware 15 02-08-2010 01:23 PM
Kernel panic after slackware 12.0 installation (VFS not mounted) itz2000 Slackware 6 08-19-2007 04:30 PM
kernel panic : VFS : Unable to mount root fs on 03:03 (Slackware Distro) tolits Linux - General 13 01-20-2005 10:52 PM
Dual-booting Mandrake & Slackware: Kernel panic: VFS: Unable to mount root fs vasudevadas Linux - General 5 08-22-2004 04:43 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:21 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration