You are not logged in.

#1 2012-12-20 17:05:13

creack
Member
Registered: 2012-12-20
Posts: 4

Grub fail to boot the first time

Hello

I spent the past 2 days trying without success to install my archlinux. I am out of ideas so I come here for advise.

Grub doesn't seem to be able to load my LVM partions.

Before you ask, yes, I have the dm_mod in the module list and the lvm2 in the hook list. Yes I regenerated the image.

Here is my /boot/grub/grub.cfg (Which is loaded! Grub load correctly the config, load the initrd and everything!, the isssue comes after the menuentries)

insmod gzip
insmod part_gpt
insmod lvm
insmod ext2
set root=(lvm/lv1-boot)
linux /vmlinuz-linux root=/dev/lv1/root ro
initrd /initramfs-linux.img

I tried to use /dev/mapper/lv1-root, it does just the same.

/etc/fstab have been generated by genfstab.

# UUID=xxxxxx
/dev/mapper/lv1-root / ext4 ro #Tried also with rw and default optiions...
# UUID=xxxxxx
/dev/mapper/lv1-boot /boot ext2 rw,error=continue,user_xattr,acl

Boot log:

[    0.981237] Failed to access perfctr msr (MSR c0010004 is 0)
/dev/mapper/lv1-root: recovering journal
/dev/mapper/lv1-root: clean, 48390/655360 files, 385993/2621440 blocks

Loading lvm2 hook & enabling the lvm paritions
...
:: mountung '/dev/mapper/lv1-root' on real root
[OK] Listening on udev Control Socket
Expecting device dev-mapper-lv1\x2dboot.device...
...
[ TIME ] Timed out waiting for device dev-mapper-lv1\x2dboot.device.
[DEPEND] Dependency failed for /boot.
[DEPEND] Dependency failed for Local File Systems.
[ 184.408704] systemd-udevd[124]: worker [166] did not accept message -1 (Connection refused), kill
...
...
[ 185.625370] systemd-udevd[124]: worker [186] did not accept message -1 (Connection refused), kill
systemd-udev[121]: worker [xxx] terminated by signal 9 (Killed)

It propose me to enter recovery mode or to continue and if I continue, it works fine!!! But as it is a remote server, this happen way before the network initialization so I can't let it be sad

I must have missed something setting up grub. But what?

As I said, I am out of ideas sad. Does someone would have any?


Regards,

EDIT: additionnal infos:

GRUB2

GPT
/dev/sda1 -> bios
/dev/sda2 -> Linux LVM

pv /dev/sda2
vg lv1 /dev/sda2
lv:
root -> ext4 (I tried ext3... no luck)
boot -> ext2 (I tried ext3 and ext4... no luck)
swap -> swap (unused)

Install via bootstrap (https://wiki.archlinux.org/index.php/Install_from_Existing_Linux Method1)

EDIT2:

I tried with MBR instead of GPT, exact same issue
I tried to gensftab with UUIDs instead, changes nothings sad

Last edited by creack (2012-12-21 21:29:58)

Offline

#2 2012-12-20 18:06:56

joseperezc
Member
Registered: 2011-03-02
Posts: 80

Re: Grub fail to boot the first time

systemctl enable lvm or systemctl enable lvm-on-crypt should do the trick.


Hope to be helpfull

Offline

#3 2012-12-20 19:10:31

creack
Member
Registered: 2012-12-20
Posts: 4

Re: Grub fail to boot the first time

Already tried, without success sad

Is it possible that it is simply an utf8 issue? and that he is really waiting for lv1\x2dboot instead of lv1-boot? If yes, how can I fix this?

Last edited by creack (2012-12-20 19:25:09)

Offline

#4 2012-12-20 22:58:07

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,198

Re: Grub fail to boot the first time

In the example on the wiki, there are no parentheses around the lvm/lv1-boot:

# (0) Arch Linux
menuentry "Arch Linux" {
insmod lvm
set root=lvm/VolumeGroup-lv_boot
# you can only set following two lines
linux /vmlinuz-linux root=/dev/mapper/VolumeGroup-root ro
initrd /initramfs-linux.img
}

Note: I don't know that the wiki is correct. I'm just noting the disparity.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#5 2012-12-20 22:59:50

creack
Member
Registered: 2012-12-20
Posts: 4

Re: Grub fail to boot the first time

Thank you Cymru, however, I tried with, without, with different formats, but nothing worked sad

I think the problem does not come from there as Grub finds the vmlinuz-linux image without difficulties.

Offline

#6 2012-12-21 13:52:52

creack
Member
Registered: 2012-12-20
Posts: 4

Re: Grub fail to boot the first time

Note that the exact same thing works fine in local with install from CD..

And anyone would know why it works the 'second' time? when I do 'systemctl default'. As it is a remote server, I can't let it like this as right now I can boot only via a virtual KVM.

Offline

Board footer

Powered by FluxBB