You are not logged in.

#1 2024-01-21 05:01:52

gardenair
Member
Registered: 2021-08-17
Posts: 42

[SOLVED] boot partition is not mounting.

hi,
     I have just installed Arch Linux on my old desktop computer. It has a legacy BIOS option only. I have created 5 partitions of the hard disk.

root@archiso ~ # fdisk  /dev/sda


root@archiso ~# fdisk /dev/sda

Welcome to fdisk (util-linux 2.39.2).

Device    Boot  Start    End       Sector    Size                                                     ID               Type

/dev/sda1      *         2048   1026047  1024000                         500M                    83            Linux

/dev/sda2        1026048  5220351    4194304                         2G                82            Linux swap /Solaris

/dev/sda3        5220353  277850111   272629760           130G                    83                    Linux

/dev/sda4        277850112  488397167   210547056       10.4G                    5              Extended

/dev/sda5        277852160  488397167   210545008       10.4G                   83              Linux

i.e

1- /boot

2- /swap

3- /root

4- /home


Formated as

root@archiso ~ # mkfs.ext4  /dev/sda1
root@archiso ~ # mkswap  /dev/sda2
root@archiso ~ # mkfs.ext4  /dev/sda3
root@archiso ~ # mkfs.ext4  /dev/sda5

Now mounting the partitions.

root@archiso ~ #  mkdir  –p  /boot
root@archiso ~ # mount  /dev/sda1 /boot

root@archiso ~ # swapon  /dev/sda2

root@archiso ~ # mount  /dev/sda3 /mnt

root@archiso ~ #  mkdir –p  /mnt/home

root@archiso ~ # mount /dev/sda5  /mnt/home

root@archiso ~ # lsblk

sda1

sda1     8:1        0      500M        0      part      /boot

sda2     8:2        0       2G           0     part      [swap]

sda3     8:3       0      130G         0      part      /mnt

sd41     8:4        0       1K            0      part       

sda5     8:5        0      100.4G      0      part      /home



Install Arch files

root@archiso ~ # pacstrap -i /mnt base linux linux-firmware sudo vim
Generate the fstab File
root@archiso ~ # genfstab -U -p /mnt >> /mnt/etc/fstab

root@archiso ~ # lsblk

sda

sda1     8:1        0      500M        0      part     

sda2     8:2        0       2G           0     part      [swap]

sda3     8:3       0      130G         0      part      /mnt

sd41     8:4        0       1K            0      part       

sda5     8:5        0      100.4G      0      part      /home

The thing which I don't understand is why the /boot partition is not mounted when I apply genfstab command. Though I have installed complete Arch Linux with Xfce. The boot partition is not mounted and its related files are not inside /the boot partition.

Kindly guide me.
gardenair

Last edited by gardenair (2024-01-23 17:42:43)

Offline

#2 2024-01-21 05:19:59

jonno2002
Member
Registered: 2016-11-21
Posts: 700

Re: [SOLVED] boot partition is not mounting.

because you didnt mount the /boot partition in the right place, you mounted it to /boot instead of /mnt/boot.

EDIT: make sure you mount /root first before mounting /boot

Last edited by jonno2002 (2024-01-21 05:21:36)

Offline

#3 2024-01-21 05:51:58

gardenair
Member
Registered: 2021-08-17
Posts: 42

Re: [SOLVED] boot partition is not mounting.

Thanks for the reply Well first I even tried with /mnt/boot but still, it does mount the boot partition.

Offline

#4 2024-01-21 06:21:46

jonno2002
Member
Registered: 2016-11-21
Posts: 700

Re: [SOLVED] boot partition is not mounting.

did you mount root first THEN mount boot after ?
like this:

root@archiso ~ # swapon  /dev/sda2
root@archiso ~ # mount  /dev/sda3 /mnt
root@archiso ~ # mkdir  –p  /mnt/boot
root@archiso ~ # mount  /dev/sda1 /mnt/boot
root@archiso ~ #  mkdir –p  /mnt/home
root@archiso ~ # mount /dev/sda5  /mnt/home 

Offline

#5 2024-01-21 10:46:18

gardenair
Member
Registered: 2021-08-17
Posts: 42

Re: [SOLVED] boot partition is not mounting.

I mount the /boot partition first then swap at third I mount / i.e root partition then at last /home.

root@archiso ~ #  mkdir  –p  /mnt/boot
root@archiso ~ # mount  /dev/sda1 /mnt/boot

root@archiso ~ # swapon  /dev/sda2

root@archiso ~ # mount  /dev/sda3 /mnt

root@archiso ~ #  mkdir –p  /mnt/home

root@archiso ~ # mount /dev/sda5  /mnt/home

Offline

#6 2024-01-21 10:52:31

Head_on_a_Stick
Member
From: Belsize Park
Registered: 2014-02-20
Posts: 8,248
Website

Re: [SOLVED] boot partition is not mounting.

Follow jonno2002's steps instead. You're covering up /mnt/boot/ when you mount /dev/sda3 under /mnt. Confirm that with `ls /mnt`.

I have to ask though: why do you think you need 3 separate partitions? That just looks like trouble waiting to happen. A single root partition is fine for a non-UEFI system and you won't have to worry about space requirements for the root, /home/ & /boot/ partitions.

And please use code tags rather than quote tags when posting terminal output.


"The nation-state domesticates the society in the name of capitalism and alienates the community from its natural foundations."
Democratic Confederalism, Abdullah Öcalan.

Offline

#7 2024-01-22 09:58:39

gardenair
Member
Registered: 2021-08-17
Posts: 42

Re: [SOLVED] boot partition is not mounting.

Thanks for the reply. Well I know instead to create a new /boot partition I can keep it  with root ,make swap and home partition. I can even create a single " / " partition and enjoy Arch.
The query  is, what is the proper order and mounting technique (Legacy BIOS)  if someone want  separate  boot partition, swap partition , root partition and home partition ?
Thanks in advance.

Offline

#8 2024-01-22 10:41:28

d.ALT
Member
Registered: 2019-05-10
Posts: 943

Re: [SOLVED] boot partition is not mounting.

Just follow the steps in order they're represented in 1.11 > https://wiki.archlinux.org/title/Instal … le_systems
Root partition (eg.: /dev/sda1) is mounted onto /mnt, then go for remainings (mkdir, mount then, mkdir, mount then, and so on...)

Last edited by d.ALT (2024-01-22 10:41:47)


<49,17,III,I>    Fama di loro il mondo esser non lassa;
<50,17,III,I>    misericordia e giustizia li sdegna:
<51,17,III,I>    non ragioniam di lor, ma guarda e passa.

Offline

#9 2024-01-22 11:47:00

gardenair
Member
Registered: 2021-08-17
Posts: 42

Re: [SOLVED] boot partition is not mounting.

"d.ALT"I also tried  as write down . With your kind direction still I can't see separate  root partition  mounted  asfter "genfstab" command.

Offline

#10 2024-01-22 13:41:48

d.ALT
Member
Registered: 2019-05-10
Posts: 943

Re: [SOLVED] boot partition is not mounting.

Just follows the steps suggested by jonno2002: https://bbs.archlinux.org/viewtopic.php … 7#p2145197


<49,17,III,I>    Fama di loro il mondo esser non lassa;
<50,17,III,I>    misericordia e giustizia li sdegna:
<51,17,III,I>    non ragioniam di lor, ma guarda e passa.

Offline

#11 2024-01-23 04:47:30

gardenair
Member
Registered: 2021-08-17
Posts: 42

Re: [SOLVED] boot partition is not mounting.

"jonno2002" Thanks for the valuable guidance. Well I should be thankful if you kindly elaborate it.  The think Which I understand is for Legacy BIOS option always mount /mnt first then rest of the partitions. The partitions are now mounting account to your reply. Thanks for it.

Just adding more if you allow me  in my past in case of UEFI systems may I mount the EFI system partition as following order ?

sda1   /boot/efi
sda2   swap
sda3   /
sda4   /home

root@archiso ~ # mkdir  –p  /mnt/efi
root@archiso ~ # mount  /dev/sda1 /mnt/efi
root@archiso ~ # swapon  /dev/sda2
root@archiso ~ # mount  /dev/sda3 /mnt
root@archiso ~ #  mkdir –p  /mnt/home
root@archiso ~ # mount /dev/sda4  /mnt/home 

Thanks a lot  for your valuable guidance for helping me.

Last edited by gardenair (2024-01-23 04:54:22)

Offline

#12 2024-01-23 04:49:16

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,043

Re: [SOLVED] boot partition is not mounting.

You're not getting it. You can't mount /mnt/efi then mount /mnt. You're hiding the ESP completely.

Offline

#13 2024-01-23 05:17:01

gardenair
Member
Registered: 2021-08-17
Posts: 42

Re: [SOLVED] boot partition is not mounting.

well nothing is hiding. The

root@archiso ~ # genfstab  -U -p  /mnt >> /mnt/etc/fstab

  shows all the  mounted partitions which is a good sign  for me.

Remaining in the arch help there is also UEFI mounting help with that reference i get question in my mind that in case of UEFI how may I may mount it .
Though in my post I ask about the legacy partition mounting but I added  other query which is  separate from my post/question.

Offline

#14 2024-01-23 07:18:07

d.ALT
Member
Registered: 2019-05-10
Posts: 943

Re: [SOLVED] boot partition is not mounting.

gardenair wrote:

sda1   /boot/efi

root@archiso ~ # mkdir  –p  /mnt/efi
root@archiso ~ # mount  /dev/sda1 /mnt/efi

Typo?

Anyway, as you correctly understood, the # mount /dev/sda4  /mnt/home step you've done was preformed after an mkdir (on the mounted $ROOT) and after you mounted your $ROOT. Same approach has to be done for all other mountpoints which are below $ROOT (as Scimmia already told you).
At this point I'm not understanding why you've done a step in the right direction, but the other not.


<49,17,III,I>    Fama di loro il mondo esser non lassa;
<50,17,III,I>    misericordia e giustizia li sdegna:
<51,17,III,I>    non ragioniam di lor, ma guarda e passa.

Offline

#15 2024-01-23 07:53:32

Head_on_a_Stick
Member
From: Belsize Park
Registered: 2014-02-20
Posts: 8,248
Website

Re: [SOLVED] boot partition is not mounting.

gardenair wrote:

well nothing is hiding

Yes it is.

Look:

# mkdir -p /mnt/efi
# mount /dev/sda1 /mnt/efi
# mount /dev/sda2 /mnt
# ls /mnt
# findmnt /mnt
TARGET SOURCE    FSTYPE OPTIONS
/mnt   /dev/sda2 btrfs  rw,relatime,space_cache=v2,subvolid=5,subvol=/
# umount /mnt
# ls /mnt
efi
#

"The nation-state domesticates the society in the name of capitalism and alienates the community from its natural foundations."
Democratic Confederalism, Abdullah Öcalan.

Offline

#16 2024-01-23 16:59:44

gardenair
Member
Registered: 2021-08-17
Posts: 42

Re: [SOLVED] boot partition is not mounting.

Thanks for the guidance. Well, the gist which I understood is  "/" root should always mounted first and the rest whatever partitions are should be mounted under " /mnt" .  So in short /mnt is the base for all. It is a basic concept which I was neglecting in the installation process.   This approach applies both to  "Legacy" and "UEFI".  Appreciate "jonno2002"," d.ALT" " Head_on_a_Stick" and " Scimmia " for the valuable guidance.

Offline

#17 2024-01-23 17:27:33

seth
Member
Registered: 2012-09-03
Posts: 58,095

Re: [SOLVED] boot partition is not mounting.

The gist is that the order of layered mounts matter

mount /dev/sda /mnt/foo
mount /dev/sdb /mnt

/mnt will now reflect /dev/sdb - whatever was there before is hidden by that - whether you're doing this w/ the root partition or a bind mount into your /home partition does not matter at all.

Please always remember to mark resolved threads by editing your initial posts subject - so others will know that there's no task left, but maybe a solution to find.
Thanks.

Offline

Board footer

Powered by FluxBB