Trying to install... truly lost.
I'm updating this post as I make progress.
Dayum guys, thanks so much for the help. I really just expected to be downvoted and called a newb, but you've all been incredibly kind and helpful. I'm still working on it but I'm happy to take it slowly and make sure I get familiar.
At the suggestion of a few people, I'm trying to use systemd-boot instead of GRUB. It seemed to install correctly, and rebooting shows the menu, but it doesn't boot into Arch.
It finally works! Thank you for your help everyone. As I said below, I am hoping to build my theme inside the VM, build an ISO from it, and then install it onto my PC for real. I think this should work, I will just need to resize the root partition size. Let me know if you have any input on that.
Edited 18 Nov 2017. We only hold this version.
About this post
- Posted
- Archived
- Edited
- Score
- 41 · 100% up
- Kind
- Text
- ID
- 7dp7ui
77 comments
Hey, I know it can be frustrating doing it for the first time, but keep at it, it's worth it!
Anyway, to answer your question, if you're installing grub to boot with UEFI, and there's a high chance that you are, the first partition needs to be FAT32.
If you're not installing with UEFI, tell me and I'll help you with it.
Thanks for your support. My BIOS supports legacy and UEFI so I would assume UEFI. I recreated and formated sda1 as fat32 but got this error. I am installing in a VirtualBox VM for now and am hoping to pack it into an ISO at some point.
Can you look up how to check if you are booted through UEFI while using the Arch ISO? I don't quite know how to do this, perhaps doing the following might work:
I think that location only exists when booted through UEFI.
Make sure to boot in UEFI mode, not in the legacy BIOS mode. On my PC in its boot selection menu, removable media show up as two entries by default, one for booting it in UEFI mode and one for BIOS mode.
Maybe see if there's an entry somewhere in the UEFI to completely disable booting any media in BIOS mode just to make sure you can't boot like that by mistake.
Basically what u/ropid said, but you also have to make sure that the FAT32 partition has the boot flag set. I forgot to mention that. That partition is called an EFI System Partition, ESP for short, and it's used by UEFI when searching for bootloader executables.
EDIT: The method for checking if you're booted into UEFI is correct in u/ropid's post, and when you install grub, you don't have to use a device. Instead, once you're chrooted into your install, install it like this:
grub-install --target=x86_64-efi --efi-directory=esp_mount --bootloader-id=grub
esp_mount is probably /boot/efi or wherever you mounted the FAT32 partition (I recommend /boot/efi, though)
grub is the bootloader ID, and this can be anything, but the default grub is fine. I usually just put arch, though.
IIRC, EFI in VirtualBox is kind of problematic. But either way, for UEFI installs, I'd recommend systemd-boot over GRUB. The only tiny disadvantage it has is that you need to set up microcode updates manually (when running directly on hardware you should do this, in VBox it probably does nothing)
Hey, thanks for being so supportive with your response! I installed Arch a little while back and have been tinkering with it ever since but generally avoided looking at any forums as I'd gotten the impression folks were a lot more abrasive about helping beginners just because somebody, somewhere had asked a similar question previously.
^.^ It's a really nice surprise to see you and others here being so encouraging!
Thanks! I don't see a point in gatekeeping, we were all beginners once. And if I get to help someone experience this awesome distro, then it makes my day that much better.
So I had a lot of trouble figuring this out myself so I figured I'd try to help someone get it quicker. First I partitioned sdX (sda for you) into sdX1 512M and sdX2 for the rest of the hard drive as you did. The mkfs.vfat (or whatever you use, as long as it is FAT32) for sdX1, and mkfs.ext4 for sdX2. Then:
Now you're ready to
do whatever else you need to do before you install grub, and then when it's time to install grub, "
efibootmgr is what I was missing for the longest time Then all that's left is to run
Of course I skipped steps, but that's because I'm just listing the steps required strictly for grub. EDIT: Also as per the arch wiki, when you're making sdX1 make sure you make it an EFI system
I know this comment is 3 months old, but God bless, that efibootmgr error made me reinstall from scratch 4 times before realising my partitions was alright and its just that pacstrap /mnt base didn't cover it. Also thanks for mentioning the partitions thing, it goes into so much detail how to load fdisk(not even how to use) then skips straight to the next thing, whoever says to use the beginners guide(normally instead of actually helping) hasn't actually read it because it can be horrid at parts (you pretty much have to have a computer spare to look at it because using phone and having to juggle tabs(with spin off pages where it skips steps) is a nightmare)
Do you have any specific reason to use grub or was it your default choice?
I recently installed on an EFI system and grub was a nightmare. I switched to systemd-boot and everything was much easier. I know it is just avoiding a problem instead of fixing it, but that might be worth to look into.
Good luck and don't give up!
systemd-boot is actually the recommended bootloader for arch. It's much simpler and easier to manage. I still prefer grub2, though, as it's what I know and it allows me to set a password for booting certain options, which I need sometimes.
Correctly! I used systemd-boot in past but since I have encrypted boot partition I stick with grub2 because systemd-boot can‘t handle encrypted boot partitions as far as I know.
Yeah I also wonder why on Earth the OP wants to install Grub.
Yes, be sure the /boot partition is a Fat32 / vfat filesystem,
mkfs.fat -F32 /dev/sda1should take care of you there.Just tried it, but didn't work :(. I reformatted and created the partitions from scratch to be sure.
All about the wants of Legacy BIOS vs EFI.
Legacy BIOS is unionized. They don't touch filesystems. They just pick up shovel and dig at some known sector space for anything to execute. It's real work.
Executing straight off the early sectors of a drive before any filesystems are defined is something grub can prepare for, but not today.
EFI is the full stack developer. It kinda knows how to VFAT and kinda knows how to manage a system -- right out of the firmware (college).
Of course, for this convenience we pay for it by creating a whole partition to handhold and mansplain the process.
You need at least one partition in the table for the drive to be bootable and it needs to be of type EF00. Don't listen to the haters saying you need to make the EF00 partition "bootable". Come on, man. This is EFI. Very few manufacturers even know what they're doing. It MIGHT require set bootable via the extended features of gdisk.
Format it, and mount it somewhere nice, and tell grub about it.
Some folks use the same EF00 partition as the /boot mountpoint. This is kinda neat and means it needs to be big enough for grub config, initramfs, and kernel stuffs. e.g. 100MiB+
That should be enough to get you going. But, as the above wall of text suggests, read lots. It's all there on the grub wiki page.
Since you referenced GPT, I'm assuming you're trying to install for a UEFI system.
You MUST format the partition as FAT32. Also, there is no reason to make it 512MiB, you can size that down to even 100 MiB, mine is 256 MiB.
Read here: https://wiki.archlinux.org/index.php/EFI_System_Partition
Additionally, make sure when you mount the partitions, you first mount the root partition, then the boot partition, for example at /mnt and /mnt/boot respectively. Then you arch-chroot into /mnt, then point grub install to /boot.
Thanks for your reply, but I have since reformatted sda1 and am still getting issues. Please see the screenshots above.
Just an FYI I noticed you were installing it in virtual box, which doesn't play nice with a UEFI install.
What are you using to partition with? I think the install guide suggests fdisk, but if you're using gpt you'll need to use gdisk (or parted I think, but you'll be in your own for that one.) Gdisk /Dev/sda/ you need basically at least two partitions, a boot and a root. So assuming everything is blank you can just make a new partition, make it like 512mb, then I'm pretty sure you need to tell it to make it an efi partition, which is ef00 in the codes. Make whatever else you need, (swap, maybe. Which is 8200, and then at least root which can just be the default 8300) Then do the mkfs.fat -F32 /Dev/sda1 and mkfs.ext4 /Dev/sda2 or 3, wherever root ended up. Then write that to disk, mount the root to /mnt; mkdir /mnt/boot and then mount boot to it. Then carry on from that point on the guide. And you should be golden.
Btw, fdisk fully supports gpt now.
Well. I honestly had no idea. You learn something new etc... It's been so long since I used fdisk I don't I remember how...
You're having the same problem I did, and I also consider myself a (semi) intermediate Linux user.
The boot partition needs to be fat32.
Yup, honestly people consider the Beginner's guide the holy bible for installing but it completely cuts out important stuff like this(like it might have it on a spinoff article but its a pretty vital step considering you only learn it won't work all the way to when you need to install a bootloader
Regardless of your root problem, this was very likely unnecessary.
You will get help here if your provided info is sufficient. Is your computer setup for MBR or UEFI? Good luck.
Since grub says it can't find the BIOS boot partition when you install it to
/dev/sda, how about making one? When partitioning, create a 1MB partition of type BIOS boot (ef02ingdisk) and leave it unformatted. Then proceed to make other necessary partitions.AFAIK it's a grub quirk, so you can try another bootloader like rEFInd.
EDIT: WTF autocorrect
In your
grub-installline are you definitely doing/dev/sdaand not/dev/sda1?I have been trying both sda and sda1. Using sda1 gives me an error about FAT not being usable. Using sda gives me this.
Deleted before we saved it.
didn't see this mentioned here clearly. first of all, you must understand that for uefi you must use the GPT partition table, for bios you want to use the DOS one. second, for uefi the /boot, or /boot/EFI partition must be fat32 with ef02 partition type, for dos it may be any linux compatible one. for uefi you want to use gdisk, not fdisk.
I have never installed Arch with UEFI or GPT, but I have with other distributions. Grub cannot install directly to the gpt of sdX. You usually need a 1mb partition at the beginning of the drive to install grub onto. It is called biosboot usually.
It is easier to install Arch with the MBR partition table and legacy if your motherboard allows it.
Deleted before we saved it.
I’ll just leave it here in case you get absolutely frustrated with the installation but still want to try using Arch:
Try the Antergos distro. It’s basically Arch with an easy GUI installer.
But I recommend doing the manual installation first, because you’ll learn a lot.
or Manjaro.
If you just wanna get Arch installed quickly, I'd highly recommend Arch Anywhere, it does all the dirty work for you. However I'd still recommend doing a manual install, you do learn a lot from it.
Why are you using grub? Sorry but it's apparent you don't have a great depth of knowledge of how bootloaders and boot records work. If you're using UEFI anyway just use systemd boot. It's really simple.