You are not logged in.
Pages: 1
Hi,
I have grub.cfg:
menuentry "Arch iso" {
insmod lvm
set isofile=/archlinux-2015.12.01-dual.iso
set root=(lvm/laptop-data)
loopback loop $isofile
linux (loop)/arch/boot/x86_64/vmlinuz archisobasedir=arch archisolabel=ARCH_201512 earlymodules=loop img_loop=$isofile
initrd (loop)/arch/boot/x86_64/archiso.img
}
Kernel gets booted but arch can't be mounted because /dev/disk/by-label/ARCH_20512 doesn't exist (in fact /dev/disk/by-label doesn't exist). What am I doing wrong?
Gnome - The weakest link!
Linux, *not* GNU/Linux!
Offline
You don't need these:
archisobasedir=arch archisolabel=ARCH_201512 earlymodules=loop
but either img_dev or img_loop: https://projects.archlinux.org/archiso. … bootparams
For example:
...
probe -u $root -s uuid
linux (loop)/arch/boot/x86_64/vmlinuz img_loop=$isofile img_dev=/dev/disk/by-uuid/$uuid
...
or
...
probe -l $root -s label
linux (loop)/arch/boot/x86_64/vmlinuz img_loop=$isofile img_dev=$label
...
if you have set a filesystem label for the logical volume. You can also choose to have static UUID/LABEL specified in grub.cfg instead of using the probe command in grub shell.
Last edited by tom.ty89 (2015-12-26 09:57:59)
Offline
Thank you for answer. Unfortunately I'm still unable to get it working. You said that I should use probe root, I changed it to probe $root as without that grub2 was complaining that it can't find root device. This is fine, but arch still is not mounted. It says that it tries to mount /dev/disk/by-uuid/UUID-HERE, but after 30 seconds of waiting I get prompt. When I ls /dev/disk/by-uuid there is no uuid that Arch tried to mount.
The uuid that grub detects is correct, it is the same as result of blkid /dev/mapper/laptop-data.
Maybe initrd on the iso file is not prepared to detect LVM?
Gnome - The weakest link!
Linux, *not* GNU/Linux!
Offline
Oh sorry yeah it should be $root. Corrected in the original post.
Hmm you're probably right. Apparently archiso does not include the lvm install and runtime hook:
https://projects.archlinux.org/archiso. … o/initcpio
as the lvm2 provides:
https://projects.archlinux.org/svntogit … kages/lvm2
https://projects.archlinux.org/svntogit … kages/lvm2
Last edited by tom.ty89 (2015-12-26 10:05:48)
Offline
Maybe I'll fill bug report with feature request
Gnome - The weakest link!
Linux, *not* GNU/Linux!
Offline
Gnome - The weakest link!
Linux, *not* GNU/Linux!
Offline
Pages: 1