You are not logged in.

#1 2022-12-16 13:54:48

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

[SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

nvme0n1p1 = bootloader
nvme0n1p2 = Arch root
nvme0n1p3 = Kubuntu root
I don't create separated /home and root for both.
I've read about this post but not works.

After install Arch:
Boot into Arch, remember that os-prober is not installed yet and install it immediately.
Check if kernel (linux and linux-lts), grub, and efibootmgr is already installed.
Boot to Kubuntu 22.04 with USB bootable.
Install it using automatic partition (I also tried manual partition before).
Reboot, Kubuntu works, but Arch not (stuck on Asrock logo, which is my motherboard)
Boot to Archlinux in USB bootable.

mount /dev/nvme0n1p2 /mnt
mount /dev/nvme0n1p1 /mnt/boot
arch-chroot /mnt
pacman -Syu
pacman -Ss linux linux-lts efibootmgr grub os-prober

I see all of those packages is already installed.
Trying to reinstall them

pacman -Syu linux linux-lts
pacman -Syu grub efibootmgr os-prober
grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=GRUB
grub-mkconfig -o /boot/grub/grub.cfg
reboot

I still can't boot into ArchLinux. Please help. And how to get the log?

Last edited by mom_please_help (2022-12-18 02:30:16)

Offline

#2 2022-12-16 13:59:58

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

And how I can find the log?

Offline

#3 2022-12-16 14:09:45

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 24,857

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

https://wiki.archlinux.org/title/System … al_to_view for accessing the journal from the mounted system.

In your trail above minimally your grub-install invocation has the wrong --efi-directory and it should be /boot.

That said post

lsblk -f
efibootmgr -uv

aas well as the journal of the last boot of your installed system: https://wiki.archlinux.org/title/List_o … n_services

Offline

#4 2022-12-17 03:20:40

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

Log is in 0x0.
Output of lsblk -f:

NAME        FSTYPE   FSVER            LABEL        UUID                                 FSAVAIL FSUSE% MOUNTPOINTS
loop0       squashfs 4.0                                                                      0   100% /run/archiso/airootfs
sda                                                                                                    
├─sda1      btrfs                     Daki Balmond 202abb91-2bbb-4c32-bdbc-5550c982f561  854.8G     7% /media
└─sda2      vfat     FAT32            432          532D-DC22                                           
sdb                                                                                                    
├─sdb1      exfat    1.0              Ventoy       049E-75A9                                           
│ └─ventoy  iso9660  Joliet Extension ARCH_202212  2022-12-01-11-52-20-00                              
└─sdb2      vfat     FAT16            VTOYEFI      ADC2-5F11                                           
nvme0n1                                                                                                
├─nvme0n1p1 vfat     FAT32                         0810-D9AF                             386.2M    24% /mnt/boot
├─nvme0n1p2 ext4     1.0                           e3b8ad02-7646-4989-ad05-2702094982b4  216.2G     2% /mnt
└─nvme0n1p3 ext4     1.0                           271c38bf-4b78-40ce-818c-6c2f9a4439f3                

Output of efibootmgr -uv:

BootCurrent: 0003
Timeout: 1 seconds
BootOrder: 0002,0001,0003
Boot0001* UEFI OS	HD(1,GPT,27bc3658-8ca5-48e1-90de-f71e28a1c06e,0x800,0xff800)/File(\EFI\BOOT\BOOTX64.EFI)
      dp: 04 01 2a 00 01 00 00 00 00 08 00 00 00 00 00 00 00 f8 0f 00 00 00 00 00 58 36 bc 27 a5 8c e1 48 90 de f7 1e 28 a1 c0 6e 02 02 / 04 04 30 00 5c 00 45 00 46 00 49 00 5c 00 42 00 4f 00 4f 00 54 00 5c 00 42 00 4f 00 4f 00 54 00 58 00 36 00 34 00 2e 00 45 00 46 00 49 00 00 00 / 7f ff 04 00
    data: 00 00 42 4f
Boot0002* ubuntu	HD(1,GPT,27bc3658-8ca5-48e1-90de-f71e28a1c06e,0x800,0xff800)/File(\EFI\UBUNTU\SHIMX64.EFI)
      dp: 04 01 2a 00 01 00 00 00 00 08 00 00 00 00 00 00 00 f8 0f 00 00 00 00 00 58 36 bc 27 a5 8c e1 48 90 de f7 1e 28 a1 c0 6e 02 02 / 04 04 34 00 5c 00 45 00 46 00 49 00 5c 00 55 00 42 00 55 00 4e 00 54 00 55 00 5c 00 53 00 48 00 49 00 4d 00 58 00 36 00 34 00 2e 00 45 00 46 00 49 00 00 00 / 7f ff 04 00
Boot0003* UEFI:  USB, Partition 2	PciRoot(0x0)/Pci(0x1,0x2)/Pci(0x0,0x0)/USB(10,0)/USB(0,0)/HD(2,MBR,0x1380078d,0x7289000,0x10000)
      dp: 02 01 0c 00 d0 41 03 0a 00 00 00 00 / 01 01 06 00 02 01 / 01 01 06 00 00 00 / 03 05 06 00 0a 00 / 03 05 06 00 00 00 / 04 01 2a 00 02 00 00 00 00 90 28 07 00 00 00 00 00 00 01 00 00 00 00 00 8d 07 80 13 00 00 00 00 00 00 00 00 00 00 00 00 01 01 / 7f ff 04 00
    data: 00 00 42 4f

Last edited by mom_please_help (2022-12-17 05:34:17)

Offline

#5 2022-12-17 03:57:57

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,168

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

You have to be logged in to view the file you pasted. Why would you have to use that because you can't access fpaste.org?

<command> | curl -F 'file=@-' 0x0.st 

Did you correct the grub-install command?


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

#6 2022-12-17 05:30:21

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

Thanks. this is the log

Offline

#7 2022-12-17 05:57:01

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

cfr wrote:

Did you correct the grub-install command?

I don't really sure. Is this

grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=GRUB

correct?
Or should I use

grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=GRUB

instead?

Offline

#8 2022-12-17 08:46:09

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 69,995

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

https://wiki.archlinux.org/title/GRUB#Installation

Mount the EFI system partition and in the remainder of this section, substitute esp with its mount point.

# grub-install --target=x86_64-efi --efi-directory=esp --bootloader-id=GRUB

Ftr also https://bbs.archlinux.org/viewtopic.php?id=282101 - not sure whether https://archlinux.org/news/grub-bootloa … ibilities/ might cause issues here hmm

Offline

#9 2022-12-17 16:04:18

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

I still don't know what's wrong with my command

grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=GRUB

.
I also commented os_prober in grub recently. Then I reboot. The problem is still sitting on my eyes and this is the latest log.

Last edited by mom_please_help (2022-12-17 16:04:45)

Offline

#10 2022-12-17 16:12:59

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 69,995

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

Where did you mount the esp?

Edit: srsly?

V1del wrote:

In your trail above minimally your grub-install invocation has the wrong --efi-directory and it should be /boot.

Last edited by seth (2022-12-17 16:14:56)

Offline

#11 2022-12-17 22:15:27

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

V1del wrote:

In your trail above minimally your grub-install invocation has the wrong --efi-directory and it should be /boot.

Even with /boot for the efi directory, I still can't boot to Arch

Offline

#12 2022-12-17 23:19:03

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,168

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

Post a log after installing grub correctly. Judging by the last log you posted, you should be able to boot without the GUI anyway. See https://wiki.archlinux.org/index.php/Sy … _boot_into (link shamelessly stolen from seth's signature).

X dies, but only after a shutdown is issued.

Dec 16 17:01:08 Banteng-Racing dbus-daemon[609]: [session uid=1000 pid=609] Successfully activated service 'org.kde.Shutdown'
Dec 16 17:01:08 Banteng-Racing kaccess[954]: The X11 connection broke (error 1). Did the X11 server die?

Are you starting a KDE session in Wayland or X? (It looks like Wayland?)


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

#13 2022-12-18 02:28:49

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

Problem solved. After I installed fuse-exfat, exfat-utils, and ntfs-3g, I reinstall GRUB again with efi-directory in /boot/efi (I've tried with /boot and I can boot to Arch, but Arch never detected Ubuntu even after those 3 packages installed), and grub-mkconfig, I can boot to Arch or Ubuntu.
Perhaps, the conclusion is:

mount /nvme0n1p2 /mnt
mount /nvme0n1p1 /mnt/boot
arch-chroot /mnt
pacman -Syu linux os-prober ntfs-3g exfat-utils fuse-exfat
grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=GRUB
grub-mkconfig -o /boot/grub/grub.cfg
exit
umount /mnt/boot
umount /mnt
poweroff

and unplug the USB flashdrive before turning on the PC again (in my case, if I just reboot and not unplug the USB, I can't boot to Arch in my bootable USB)
Thank you for everyone that join in this post. Now I know how to print journal log, upload it, listing partition in terminal, etc.
I don't know why I need exfat-utils, fuse-exfat, and ntfs-3g. I don't even have a ntfs partition in this device. Can someone explain?

Offline

#14 2022-12-18 02:52:50

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,168

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

I don't know how you are booting, but that grub-install command is wrong. If you mount your EFI partition at /mnt/boot, you need --efi-directory=/boot. Whatever is working, it is not thanks to the grub-install command you used.

Why do you think installing those three packages made any difference? Installing os-prober would be necessary for grub-install to find Ubuntu elsewhere. Re-installing linux might be necessary. That's all vastly more likely than that the three packages you named have anything to do with successfully booting.


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

#15 2022-12-18 09:56:46

mom_please_help
Member
Registered: 2022-12-16
Posts: 9

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

cfr wrote:

I don't know how you are booting, but that grub-install command is wrong. If you mount your EFI partition at /mnt/boot, you need --efi-directory=/boot.

Both /boot/efi and /boot are detected in BIOS. In BIOS, --efi-directory=/boot/efi detected as "UEFI OS" and --efi-directory=/boot detected (or named) as "GRUB".

cfr wrote:

Why do you think installing those three packages made any difference? Installing os-prober would be necessary for grub-install to find Ubuntu elsewhere. Re-installing linux might be necessary.

This accident is mad. I can't boot to Arch even after reinstall linux kernel and reinstall GRUB. And after I install those 3 packages, they give me a miracle. Should I reinstall my GRUB to /boot next week? Or how to mount ESP that make me can install GRUB to /boot/efi?

Offline

#16 2022-12-18 15:16:57

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,168

Re: [SOLVED] Can't boot to Arch after dualboot with Ubuntu 22.04

mom_please_help wrote:

Both /boot/efi and /boot are detected in BIOS. In BIOS, --efi-directory=/boot/efi detected as "UEFI OS" and --efi-directory=/boot detected (or named) as "GRUB".

You are using UEFI rather than BIOS, but the firmware doesn't detect /boot/efi or /boot. The ESP is only at one of those locations after it is mounted and that is long after the firmware finds your bootloader (or doesn't). If you mount your ESP to /boot in Arch, --efi-driectory=/boot in Arch. If you mount it somewhere else in Arch, the value will be that somewhere else. If you mount it elsewhere in Ubuntu, the value will be elsewhere in Ubuntu. What matters is just the match between where you mount the ESP and the path you give grub as --efi-directory.

mom_please_help wrote:

This accident is mad. I can't boot to Arch even after reinstall linux kernel and reinstall GRUB. And after I install those 3 packages, they give me a miracle. Should I reinstall my GRUB to /boot next week? Or how to mount ESP that make me can install GRUB to /boot/efi?

I'm not saying you should or shouldn't do anything. I'm just explaining that the packages you believe were crucial to making things work can't be the crucial thing. os-prober, on the other hand, would certainly be needed to detect Ubuntu, just as you need os-prober installed and functioning in Ubuntu for its grub to detect Arch (if you used Ubuntu's grub rather than Arch's).


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

Board footer

Powered by FluxBB