You are not logged in.

#1 2017-09-04 18:13:10

Miafps
Member
Registered: 2017-09-04
Posts: 2

Having fstab, mount, and efivars problems

Hi, I’m new to Arch (sorry if this post should be in the Newbie Corner) and am getting stuck at the the step where # genfstab -U /mnt >> /mnt/etc/fstab.  I followed the wiki and everything worked awesomely except for this.

From a week of digging through all the forums and internets, I'm still stuck with the following:  sad

I think my fstab file is missing.  I tried to mkdir and touch the fstab, but there is no fstab.  When I found the file, it was empty.

When I’m doing grub-install grub-mkonfig -o /mnt/boot/grub/grub.cfg or mkdir for mount space, I get the error message
failed to get canonical path of 'airootfs'

grub-install --root-directory=/mnt /dev/sda
grub-install: error: /mnt doesn’t look like an EFI partition

(I had repartitioned my drive to include a boot EFI drive after that, and went through the installation process again after wiping everything, but the problem is still not fixed)

arch-chroot /mnt /bin/bash
mount: /mnt/proc: mount point does not exist.
error: failed to setup chroot /mnt

modprobe efivars
modprobe: FATAL: Module efivars not found in directory /lib/modules/4.12.3-1-ARCH     yikes

NOoOooo x(    I have no clue how to even begin fixing efivars, but at this point when I try to reinstall efibootmgr it says Partition too full ... same goes for anything else I tried to upgrade, although I got through Pacman -Syu.

Tried to mount/dev/sda1 /mnt again, but the same problem, mount point does not exist...

I even tried to manually nano-write the fstab file based on a number of wiki resources about stab, but it didn’t work either.   sad

My fdisk -l looks like:

DEVICE             Type
/dev/sda1               Linux
/dev/sda2            Linux swap/Solaris
/dev/sda3    *        EFI (FAT-12/16/32)       
    —> boot drive is also known as sr0

On a sidenote (although I think this may be fixed if i can figure out mounting etc), Pacman -Syu Problem occurred while upgrading perl


I really appreciate your help!!


PS:   I just wanted to share a helpful tip for anyone who had the same dumbery problems as me at the beginning.   If your ethernet and wifi cards/firmware are loaded but no ping was coming out of them, despite correct input of Wifi_suppicant etc., the following script will fix everything and reassign the ip addresses that you may have manually assigned:

# dhcpcd -4 interface       
from this thread https://bbs.archlinux.org/viewtopic.php?id=209648   It reset my IP assignments and my internet was finally working

Last edited by Miafps (2017-09-04 18:13:50)

Offline

#2 2017-09-04 18:55:57

Blasphemist
Member
From: Colorado
Registered: 2013-01-17
Posts: 160

Re: Having fstab, mount, and efivars problems

So let's walk through this and try to clear things up. 1st you determine your boot mode and you are in UEFI mode right? Then you connect to the internet, update the system clock and partition the disk. Create at least a / and a ESP partition. What size did you make the ESP? How much of that partition is now used? So then you format the partitions.

Next comes mounting the partitions. This applies for during install and for doing arch-chroot to fix something. You mount the new / partition on /mnt of the installation disk you have booted into. Then you create the /mnt/boot directory to mount the ESP to, IF this is a new install. IF you are using arch-chroot to fix something, you don't need to create that directory because it already exists on the / partition that now mounted on /mnt. Now you mount the ESP on /mnt/boot. Assuming you don't also have a home partition or something else to mount, you can now run arch-chmount.

If you just run efibootmgr with the verbose option you can see the UEFI variables in a readable way, as opposed to looking at the efivars as code.

# efibootmgr -v

The fstab file is normally generated using genfstab but maybe the mounting issue kept it from being created at the right path. Since it is created before using arch-chroot but after the partitions for install have been mounted, the correct command is:

# genfstab -U /mnt >> /mnt/etc/fstab

This generates fstab relative to the partitions mounted at /mnt and puts the file in your new /etc directory. That complete path is still /mnt/ect/fstab since arch-chroot has not yet been run to change your root.

The perl upgrade issue is discussed on the Arch home page, in the G+ Arch community, on the mailing list and probably here in the forums.


Simple and Open

Offline

#3 2017-09-04 21:21:33

Miafps
Member
Registered: 2017-09-04
Posts: 2

Re: Having fstab, mount, and efivars problems

OHHH FIXED!!  I had neglected to format my sda3 partition as vfat.   I have now mounted /dev/sda3 to /mnt boot and now genfstab works!! big_smile   

Thank you so much for explaining!

Yes I am in UEFI mode.   I have sda1 as 580g  ext4  part /mnt   ; sda2 7.3g as swap ; sda3 1g partition (set as boot and formatted EFI /ESP) and I see a sr0 516M rom /run/archiso/bootmnt.  I am mounted into sda1.

Right now I'm seeing the Boot order is 0004, 0003, 0000, 0001

0000* Realtek PxE B03 D00     BBS (22,,0x0)
0001* P2: TSSTcorp CDW         BBS (19,,0x0)
0002* P0:  Samsung HM641J1    BBS (18,,0x0)
0003*  HD(3,MBR,0x282bad86,0x0,0x0)/file(\efi\boot\bootx64.efi)
0004*  UEFI: TSSTcorp CDW  PciRoot(0x0)/Pci(0x1f,0x2) and such

I remade the swap directory, reran pacstrap /mnt base, checked my fstab file and everything is there.

Went thru the rest of the steps, inserted my intel code etc

Despite the system telling me this is a BAD idea, I went ahead and ran this script

# grub-install --target=i386-pc --debug --force /dev/sda3

I could not run the chattr command, as it says inappropriate ioctl (inputoutputcontrol) for device while reading flags on /boot/grub/i386-pc/core.img, but I did use the option to Generate core.img alone.

Just a quick question, could this possibly cause irreparable damage to my system later?  A separate boot partition can be more secure or efficient or something but if it's going to really destroy my system from being unsupported and I always hate using a --force dialog..., I can always go back and delete my boot partition and run in from the main again...

Offline

#4 2017-09-05 03:37:20

Blasphemist
Member
From: Colorado
Registered: 2013-01-17
Posts: 160

Re: Having fstab, mount, and efivars problems

Having the ESP is required with UEFI so no it's not a bad thing. I'm never solid with using a force option and I don't like to even use the scripts to install boot managers or boot loaders. I like to use the manual steps to ensure each item is done without error. Scripts can make it hard to be sure you see any errors or issues. Don't ever delete the ESP unless you have a real good plan to re-create and re-build it. I did that once but it can be complicated to be sure.


Simple and Open

Offline

Board footer

Powered by FluxBB