You are not logged in.
Hello Guys,
Today I decided to reinstall my arch installation since i wanted to have my drive encrypted, and first time i installed arch i had no idea i would like to have feature like that. Following advice from other users i had backed up home folder with pika backup tool.
I decided that system backup wont be necessary since it was mostly aur and arch repo apps. After trying to understand arch wiki on drive encryption and reinstall with all those features i stumbled upon this video (seemed to be the best from available materials):
https://www.youtube.com/watch?v=kXqk91R4RwU
So i followed the guide having Arch wiki opened and following along it, but unfortunatly i got stuck on bootloader instalation (grub instal at 18:42 in vid). Errors said that 'efi variables are not supported on this system' twice and some error that grub-install didn't succeed. (efibootmgr -v gave same err). After making sure that secure boot was not a problem, i thought that it may be bootable itself since i was running installer on grub2 through ventoy. So i downloaded arch iso through officiall mirrors on seperate usb and again deciphered disk that was encrypted, mounted partitions and got same result.
What i tried:
Making sure that in "bios" next to usb there is UEFI mark, as well as in the arch menu x86_x64 UEFI
Verifying /sys/firmware/efi/fw_platform_size -> it returns 64
If i disable legacy mode none of arch iso drives was visible:
I tested USB drives made from arch iso using rufus always UEFI only with iso hybrid and DD mode.
modprobe efivarfs which didnt throw error but trying mounting it into /mnt chroot into /sys/firmware/efi/efivars did
efivarfs doesnt work neither in bootable iso root or /mnt root
I don't really know what the problem is and following arch wiki as well as random guides on the net didn't bring expected results of solving the problem.
I don't know if it helps but i tried to install system on nvme having 2 partitions one was ( nvme0n1p2, 1.8T encrypted with cryptsetup )/mnt main root partition with other being ( nvme0n1p2, 1.8T unencrypted) /mnt/boot. I read that mobo sometimes is problematic, I am using B450-A PRO from MSI.
I hope I provided enough info for you guys to help, and I'm always here in case you have any questions.
Last edited by git000 (2025-03-24 12:30:49)
Offline
unless there is something wrong with your hardware, i think the video gave you. bad instructions or you mixed up instructions from the combo of the video and the wiki. I would only use the wiki, Many of us are not going to watch the youtube video to sift through the info to see where you went wrong, and we only trust the wiki here.
Try one more time but this time, only use the wiki
Online
Sounds like you skipped https://wiki.archlinux.org/title/Instal … _boot_mode
Offline
@Scimmia I verified the boot mode, as written in section about what i tried. it returns 64 so it should be in fact UEFI at least as it seems from wiki.
I see that video is the problem, so i will list steps here :
1. Keyboard mapping ( loadkeys pl in my case )
2 Internet connection (I used wire so all that left was ping 8.8.8.8)
3. Disk formatting with cfdisk, already gpt partition so delete all that left and create 512M boot and 1.8T root
4. Format with mkfs.fat -F 32 /dev/nvme0n1p1 (512 M)
5. Encryption, cryptsetup luksFormat /dev/nvme0n1p2 (1.8 T password input and confirmation)
6. Access encrypted drive with: cryptsetup open /dev/nvme0n1p2 <name_of_opened_partition> '\n' <passwrd>
7. Format encrypted drive insides with mkfs.ext4 /dev/mapper/<name_of_opened_partition>
8. Mount /dev/mapper/<name_of_opened_partition> /mnt
9. mkdir /mnt/boot and mount /dev/nvme0n1p1 /mnt/boot
10. change to /etc/pacman.conf to optimize downloads (ParalelDownloads=8)
11. pacstrap -K /mnt base base-devel nano vim networkmanager lvm2 cryptsetup grub efibootmgr linux linux-firmware
12. genfstab -u /mnt > /mnt/stc/fstab
13. arch-chroot /mnt
14. set timezone and syn clocks ln -sf /usr/share/zoneinfo/Poland /etc/localtime; hwclock --systohc; date;
15. locale.gen uncoment pl_PL.UTF-8 and locale.conf LANG=pl
16. hostname change to git000 in /etc/hostname
17. passwd password setup for root (ik that it is not recommended i can turn it off later i hope)
18. visudo %wheel ALL=(ALL:ALL) ALL uncoment
19. useradd -m -G wheel -s /bin/bash git000 and passwd git000 password configuration
20. Configure initcpio with adding encrypt and lvm2 to HOOKS section of /etc/mkinitcpio.conf between block and filesystems
21. Rebuild initcpio with mkinitcpio -P
22. grub-install --efi-directory=/mnt --bootloader-id=GitBootloader /dev/nvme0n1
Here on the video there is no error reported but in my case 'efi variables are not supported on this system' displays in two following line and in third some error that grub-install didn't succeed.
Any ideas on what may be the reason, having in mind what i tried to check if something went wrong?
Offline
What in the world is #22 there? That command is complete nonsense
Last edited by Scimmia (2025-03-24 02:38:14)
Offline
12. genfstab -u /mnt > /mnt/stc/fstab
the wiki shows:
# genfstab -U /mnt >> /mnt/etc/fstab
Never argue with an idiot, they will drag you down to their level and then beat you with experience.
It is better to light a candle than curse the darkness.
A journey of a thousand miles begins with a single step.
Offline
15. locale.gen uncoment pl_PL.UTF-8 and locale.conf LANG=pl
although likely not the cause - but always uncomment en_US.UTF-8
but I agree with Scimmia here: the grub-install command looks wrong
// edit
for the sake of help I watched the video - and it has at leadt two major flaws:
1) it fails to note that en_US has to be enabled always - so OP likely has pl_PL only without en_US
2) it shows that complete wrong grub-install command
@OP
such bad videos are the reason why you should never use one as a guide but stick to the wiki only!
Last edited by cryptearth (2025-03-24 04:18:35)
Offline
If you booted in legacy/bios mode by accident, you can still install uefi grub with `grub-install --target=x86_64-efi --removable ...` options. That should avoid the "efi variables not available" error. However this might not be the default boot entry, so you'd have to select it manually in your uefi boot menu.
Otherwise just boot your livecd in uefi mode properly, and also bind-mount the efi vars properly (when chrooting). arch-chroot should do it correctly...
Offline
They have a MSI board, so they most likely will need to use --removable anyway.
Offline
They have a MSI board, so they most likely will need to use --removable anyway.
depends on bios version
I use the follow-up b550-a pro and had issues with early versions as well which fortunateky were fixed in more recent versions
in fact mine works so well it keeps grub as default although windows keeps re-adding itself each time I boot it (chaining from grub)
Offline
That command makes more sense, but since you still seem to be unable to access UEFI variables and if you're certain you booted it that way (and secure boot being disabled) then it's likely this is another "lol, MSI" case, and you should rerun the grub-install command but add --removable to the set of flags.
Offline
Thanks @ V1del that actually seems to be the case, do people update arch wiki with corner-cases like that, or should i do that somehow?
Also on the side note I cant see button to set topic as solved so I modified topic name.
For lost souls that will seek help in the future grub installation command looked in my case like this:
grub-install --target=x86_64-efi --efi-directory=<place you want your boot partition. For example /boot> --bootloader-id=<your_fancy_name> --removable
Thank you all people that contributed for your help!
Offline
bootloader-id and removable are mutual exclusive:
bootloader-id is passed to efibootmgr for creating an uefi boot entry
removable skips this entirely by generating a generic binary in the fallback path
tldr: bootloader-id is not used when removable is given
also: please check bios version
latest stable is 7B86vAH from Q3/22
maybe reflash it anyway - we had a topic when a uefi got stuck somehow which was fixed by reflashing it
Offline