[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
GRUB2, GPT, mdadm & LVM
From: |
Sander Smeenk |
Subject: |
GRUB2, GPT, mdadm & LVM |
Date: |
Thu, 18 Jul 2013 13:56:21 +0200 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Hi,
I'm having issues getting GRUB to boot from my setup. It drops to an
rescue shell stating it can't find the LVM root for my system. Similar
'stacked' setups (md raid5/6 lvm, root on lvm) work fine: difference
seems to be GPT.
Setup is:
16x 3TB disks with GPT partitions:
| 1 2048 4095 1024.0 KiB EF02 BIOS boot partition
| 2 4096 5860533134 2.7 TiB FD00 Linux RAID
Next i created an mdadm /dev/md0 with raid6:
| md0 : active raid6 sda2[0] [ .. ] sdp2[2]
| 41021865472 blocks super 1.2 level 6, 64k chunk, algorithm 2 [16/16]
[UUUUUUUUUUUUUUUU]
| [==>..................] resync = 10.1% (296747044/2930133248)
finish=985.3min speed=44540K/sec
The entire /dev/md0 is a Physical Volume for LVM on which two Logical
Volumes were created, one for / and one for swap. This setup works just
fine when activated from within a LiveCD like GRML:
| # lvdisplay | grep "LV Name"
| LV Name host_root
| LV Name host_swap
|
| # mount /dev/mapper/fdi-host_root /tgt
|
| # ls /tgt/boot/
| System.map-3.8.0-26-generic abi-3.8.0-26-generic config-3.8.0-26-generic
| grub/ initrd.img-3.8.0-26-generic vmlinuz-3.8.0-26-generic
During installation no errors are logged. GRUB embeds fine in the BIOS
boot partition and the generated grub.cfg shows 'insmod lvm' and 'insmod
raid6rec' amongst others. The BIOS starts GRUB just fine, it's GRUB
where it seems to fail:
During boot, GRUB starts and drops to 'grub rescue>' stating "Error:
disk lvm/fdi-host_root not found". Typing 'ls' in the rescue shell shows
the '(md/0)' device, but LVM is never started by GRUB.
Much more than 'ls' isn't available in the rescue shell. Typing 'insmod
lvm' just returns without error, typing 'insmod thisdoesnotexist'
complains GRUB can't find the disk 'lvm/fdi-host_root'.
Could someone please advise where i am going wrong?
I tried (re)creating the core.img like so:
| # grub-mkimage -o /boot/grub/core_lvm.img -O i386-pc \
| part_gpt part_msdos mdraid09 mdraid1x raid6rec \
| diskfilter lvm ext2
And put that in all the disks:
| # grub-bios-setup -b i386-pc/boot.img -c core_lvm.img /dev/sdX
Alas, to no avail.
Thanks!
-Sndr
--
| A bicycle can't stand alone; it is two tired.
| 4096R/20CC6CD2 - 6D40 1A20 B9AA 87D4 84C7 FBD6 F3A9 9442 20CC 6CD2
- GRUB2, GPT, mdadm & LVM,
Sander Smeenk <=
- Re: GRUB2, GPT, mdadm & LVM, Chris Murphy, 2013/07/18
- Re: GRUB2, GPT, mdadm & LVM, Sander Smeenk, 2013/07/18
- Re: GRUB2, GPT, mdadm & LVM, Andrey Borzenkov, 2013/07/18
- Re: GRUB2, GPT, mdadm & LVM, Sander Smeenk, 2013/07/18
- Re: GRUB2, GPT, mdadm & LVM, Chris Murphy, 2013/07/18
- Re: GRUB2, GPT, mdadm & LVM, Andrey Borzenkov, 2013/07/19
- Re: GRUB2, GPT, mdadm & LVM, Sander Smeenk, 2013/07/19
- Re: GRUB2, GPT, mdadm & LVM, Andrey Borzenkov, 2013/07/19
- Re: GRUB2, GPT, mdadm & LVM, Sander Smeenk, 2013/07/19
- Re: GRUB2, GPT, mdadm & LVM, Chris Murphy, 2013/07/19