Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Sun Jan 10, 2010 11:22 am 
Offline
Newbie

Joined: Sun Jan 10, 2010 11:14 am
Posts: 3
I'm trying to boot an LVM-based root filesystem (btw, it's ext4 as well). I created a raw disk image out of spare space, made it a pv, created a vg from that, created a few lv inside of that, mounted them under /mnt/lvm and rsync'd -ax root over to them. I edited /etc/fstab to mount them instead of the straight partitions (/dev/root_vg/root_lv). I mkinitrd a new initrd file. I created an initrd disk image and copied my initrd to it. I put the initrd into place in the console and changed the root device to /dev/root_vg/root_lv (I tried /dev/mapper/root_vg-root_lv as well). It still doesn't appear to be able to access the root filesystem. This is all based on Fedora-11 32 bit. Any ideas? The reboot gives me this on the console:

SCTP: Hash tables configured (established 65536 bind 65536)
Using IPI Shortcut mode
registered taskstats version 1
XENBUS: Device with no driver: device/console/0
md: Waiting for all devices to be available before autodetect
md: If you don't use raid, use raid=noautodetect
md: Autodetecting RAID arrays.
md: Scanned 0 and added 0 devices.
md: autorun ...
md: ... autorun DONE.
RAMDISK: ext2 filesystem found at block 0
RAMDISK: Loading 32768KiB [1 disk] into ram disk... done.
kjournald starting. Commit interval 5 seconds
EXT3 FS on ram0, internal journal
EXT3-fs: mounted filesystem with writeback data mode.
VFS: Mounted root (ext3 filesystem) on device 1:0.
VFS: Cannot open root device "mapper/root_vg-root_lv" or unknown-block(0,0)
Please append a correct "root=" boot option; here are the available partitions:
ca00 45875200 xvda driver: vbd
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
Pid: 1, comm: swapper Not tainted 2.6.32-linode23 #1
Call Trace:
[<c05f679d>] ? panic+0x42/0xf2
[<c0787ca0>] ? mount_block_root+0x158/0x26c
[<c0787dfa>] ? mount_root+0x46/0x5a
[<c0788a4e>] ? initrd_load+0x27e/0x381
[<c0787eee>] ? prepare_namespace+0xe0/0x1a2
[<c01a040f>] ? sys_access+0x1f/0x30
[<c078738b>] ? kernel_init+0x17b/0x195
[<c0787210>] ? kernel_init+0x0/0x195


Top
   
 Post subject:
PostPosted: Thu Jan 21, 2010 10:03 am 
Offline

Joined: Wed Jan 20, 2010 4:19 pm
Posts: 1
I've tried this with Arch Linux and get the same problem.

Is anyone booting an LVM root? The profile dashboard makes it seem possible:
Quote:
Select the /dev/xvdX device to use as your root device, or provide a custom root device (useful for root LVM, etc).


Any ideas how?


Top
   
 Post subject:
PostPosted: Sat Jan 30, 2010 7:45 pm 
Offline
Newbie

Joined: Wed Jan 20, 2010 4:58 pm
Posts: 2
Initially when I started using Linode I wanted to jump right into using an LVM root, but then I realized that I had a little to learn first. So instead I decided that I should just figure out how to boot my own custom kernel.

I started with Linode source http://www.linode.com/src, built it, and boot it. All worked well. So I decided to try my own kernel sources/configs. I have a much better understanding of how Linode's Xen configuration is working, but there are still a few missing pieces.

From looking at your boot-log, I'd guess that it cannot find your root, because it cannot read from your LVM. I haven't got much further than that myself, but I'm pretty certain that we probably need to make use of an initrd file.

If I make any headway, I'll let you know.


Top
   
 Post subject:
PostPosted: Sun Feb 07, 2010 2:59 am 
Offline
Newbie

Joined: Wed Jan 20, 2010 4:58 pm
Posts: 2
I managed to figure this out. I'll try and respond again with a link to guide.

I noticed after playing around with PVGRUB, that it kept looking for '(hd0)/boot/grub/menu.lst' so I figured I'd give it that. I created a filesystem directly on a disk, then I copied my /boot to it's /boot. I had to ensure that the target file system still contained a /boot directory. Then in my /boot/grub/menu.lst, I pointed it to root (hd1,0). hd1,0 is a second drive containing my real /boot partition.

So I started up my Linode with /dev/xvda being my boot-disk and /dev/xvdb containing two slices one for /boot and one for lvm. This way I still have a bootable system if I remove /dev/xvda.

Like I said, I'll try to provide more details later.


Top
   
 Post subject: Coolio
PostPosted: Sun Feb 14, 2010 12:29 am 
Offline
Newbie

Joined: Sun Jan 10, 2010 11:14 am
Posts: 3
Thank you


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 6 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group