You are not logged in.
Pages: 1
I'm trying to create a manual entry for Arch in rEFInd, and I just can't get it to boot properly.
When rEFInd auto detects the kernel, it boots fine, but it won't boot with my manual entry.
Can someone tell me what I am missing?
Here is my refind.conf:
timeout 5
showtools shell, about, reboot, exit
scanfor internal,external, manual
#menuentry "Arch-ck" {
# volume Arch
# loader vmlinuz-linux-ck
# initrd initramfs-linux-ck.img
# options "root=PARTUUID=09ddc567-20ad-4391-81db-e9965795b0d2 rootfstype=ext4 ro elevator=bfq add_efi_memmap systemd.unit=graphical.target"
#}
menuentry "Arch" {
ostype Linux
volume Arch
loader vmlinuz-linux
initrd initramfs-linux.img
options "root=PARTUUID=09ddc567-20ad-4391-81db-e9965795b0d2 rootfstype=ext4 ro add_efi_memmap systemd.unit=graphical.target"
}
When i try to boot from this, I get the error: "Error: Not Found while loading vmlinuz-linux."
My partitions are GPT and labeled as such:
Part # GPT Label Description
/dev/sda1 <blank> (EFI Partition)
/dev/sda2 Microsoft Reserved Partition
/dev/sda3 System (Windows 7)
/dev/sda4 Arch (Arch root where the vmlinuz-linux is)
/dev/sda5 Swap
For comparison, here is my refind_linux.conf for the auto detection:
"Boot to X" "root=PARTUUID=09ddc567-20ad-4391-81db-e9965795b0d2 ro rootfstype=ext4 add_efi_memmap systemd.unit=graphical.target"
"Boot to console" "root=PARTUUID=09ddc567-20ad-4391-81db-e9965795b0d2 ro rootfstype=ext4 add_efi_memmap systemd.unit=multi-user.target"
The only thing uncommented in /boot/efi/EFI/refind/refind.conf is
timeout 5
scan_all_linux_kernels
Thank you for your help,
Matt
Last edited by mattbarszcz (2013-04-29 23:19:49)
Offline
Probably the volume label is wrong. You want the label from /dev/disk/by-label and not /dev/disk/by-partlabel. At least, that's what I was using when EFI STUB worked for me this way.
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
Probably the volume label is wrong. You want the label from /dev/disk/by-label and not /dev/disk/by-partlabel. At least, that's what I was using when EFI STUB worked for me this way.
For which section? The volume= or root= ?
Volume matches what I have in /dev/disk/by-label, and root= is the PARTUUID (although it doesn't work any better with /dev/sda4).
Offline
Don't use the volume parameter, and then change root=/dev/sda4. If you have more than one disk, this might not be the best idea. But in that case I would recommend you use filesystem labels not part labels.
Offline
Don't use the volume parameter, and then change root=/dev/sda4. If you have more than one disk, this might not be the best idea. But in that case I would recommend you use filesystem labels not part labels.
No luck, here is what I used:
timeout 5
showtools shell, about, reboot, exit
scanfor internal,external, manual
#menuentry "Arch-ck" {
# volume Arch
# loader vmlinuz-linux-ck
# initrd initramfs-linux-ck.img
# options "root=PARTUUID=09ddc567-20ad-4391-81db-e9965795b0d2 rootfstype=ext4 ro elevator=bfq add_efi_memmap systemd.unit=graphical.target"
#}
menuentry "Arch" {
ostype Linux
loader vmlinuz-linux
initrd initramfs-linux.img
options "root/dev/sda4 rootfstype=ext4 ro add_efi_memmap systemd.unit=graphical.target"
}
Offline
Souldn't the "loader" and "initrd" sections be actual paths to the files. For example, I keep all my arch stuff on /boot/EFI/arch (where the ESP is mounted directly the /boot). So I would have:
menuentry "Arch Linux (CK Kernel)" {
icon EFI/refind/icons/os_linux.icns
loader \EFI\arch\vmlinuz-linux-ck.efi
initrd \EFI\arch\initramfs-linux-ck.img
options "root=/dev/mapper/volgrp0-root_arch add_efi_memmap quiet libahci.ignore_sss=1 acpi_osi=""!Windows 2012"" "
}
Also tere is no need for ostype now that I compare mine to yours.
Edit: also BTW, you can ignore the acpi_osi=""!Windows 2012"" as that is to fix a bug with Intel GPUs.
Edit2: I just tested the above, as I hadn't used it in a while because I am a gummiboot user. I had to change the root since I changed some things on my system, but it works just fine.
Last edited by WonderWoofy (2013-04-30 02:41:07)
Offline
I see two possible problems with your entry:
As WonderWoofy says, rEFInd uses filesystem labels, not partition labels. You can certainly give a label to your Arch filesystem and use it with the "volume" token in refind.conf, and if you're not mounting the ESP at /boot, that's what I'd do. Alternatively, you could use "fs#:" notation (probably "fs1:" for your Arch partition, but I can't be sure of that). The trouble with numbering is that it can change in unpredictable ways. Booting with a USB flash drive attached might throw it off, for instance. If your Arch filesystem doesn't currently have a label, you can give it one with a filesystem-specific tool, such as "tune2fs". IIRC, you can usually do this with the filesystem mounted, although GParted is stricter and requires that filesystems be unmounted before changing their labels.
You must specify the complete path to your kernel file (and the initrd file). If rEFInd is reading them off of the Arch root (/) partition, you'd need to add "/boot" to the path, as in "loader /boot/vmlinuz-linux" and "initrd /boot/initramfs-linux.img"
My suspicion is that you've currently got an EFI filesystem driver installed for whatever filesystem you're using on the Arch root (/) partition and that rEFInd is auto-detecting your Arch kernel on that partition, hence the working auto-detection. If so, making the above two changes should get your manual boot stanza working. OTOH, if you've mounted the ESP at /boot, what you had in post #5 should have worked. The fact that it didn't makes me think that you don't have the ESP mounted at /boot, but I may have overlooked something.
Loading the kernel from the ESP's EFI/arch directory, as WonderWoofy suggests in post #6, will do the trick, but it also creates more work, since you'll need to copy the kernel every time it's updated -- either copy it manually or do it via a script that runs as part of the kernel update process. Either way, it's not as elegant as either reading the kernel directly from the root (/) partition with the help of an EFI filesystem driver or mounting the ESP at /boot and then reading the kernel from the ESP's root directory.
Offline
^^^Listen this this guy. (Its his program)
Offline
I see two possible problems with your entry:
As WonderWoofy says, rEFInd uses filesystem labels, not partition labels. You can certainly give a label to your Arch filesystem and use it with the "volume" token in refind.conf, and if you're not mounting the ESP at /boot, that's what I'd do. Alternatively, you could use "fs#:" notation (probably "fs1:" for your Arch partition, but I can't be sure of that). The trouble with numbering is that it can change in unpredictable ways. Booting with a USB flash drive attached might throw it off, for instance. If your Arch filesystem doesn't currently have a label, you can give it one with a filesystem-specific tool, such as "tune2fs". IIRC, you can usually do this with the filesystem mounted, although GParted is stricter and requires that filesystems be unmounted before changing their labels.
You must specify the complete path to your kernel file (and the initrd file). If rEFInd is reading them off of the Arch root (/) partition, you'd need to add "/boot" to the path, as in "loader /boot/vmlinuz-linux" and "initrd /boot/initramfs-linux.img"
My suspicion is that you've currently got an EFI filesystem driver installed for whatever filesystem you're using on the Arch root (/) partition and that rEFInd is auto-detecting your Arch kernel on that partition, hence the working auto-detection. If so, making the above two changes should get your manual boot stanza working. OTOH, if you've mounted the ESP at /boot, what you had in post #5 should have worked. The fact that it didn't makes me think that you don't have the ESP mounted at /boot, but I may have overlooked something.
Loading the kernel from the ESP's EFI/arch directory, as WonderWoofy suggests in post #6, will do the trick, but it also creates more work, since you'll need to copy the kernel every time it's updated -- either copy it manually or do it via a script that runs as part of the kernel update process. Either way, it's not as elegant as either reading the kernel directly from the root (/) partition with the help of an EFI filesystem driver or mounting the ESP at /boot and then reading the kernel from the ESP's root directory.
That worked perfectly. Thank you so much for your everyone.
I had my ESP parition mounted at /boot/efi, so as you suggested, I put /boot/ in front of the loader and initrd and it worked
For the record, here's what I ended up with.
timeout 5
showtools shell, about, reboot, exit
scanfor external, manual
menuentry "Windows 7" {
loader \EFI\Microsoft\Boot\bootmgfw.efi
}
menuentry "Arch-ck" {
volume Arch
loader /boot/vmlinuz-linux-ck
initrd /boot/initramfs-linux-ck.img
options "root=PARTUUID=09ddc567-20ad-4391-81db-e9965795b0d2 rootfstype=ext4 ro elevator=bfq add_efi_memmap"
submenuentry "Terminal Mode" {
add_options "systemd.unit=multi-user.target"
}
}
menuentry "Arch" {
volume Arch
loader /boot/vmlinuz-linux
initrd /boot/initramfs-linux.img
options "root=PARTUUID=09ddc567-20ad-4391-81db-e9965795b0d2 rootfstype=ext4 ro add_efi_memmap"
submenuentry "Terminal Mode" {
add_options "systemd.unit=multi-user.target"
}
}
Offline
Pages: 1