UEFI: Manjaro is missing

No, you need to get to the point you can run

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

Have a good read of the wiki page and if you have any questions post back.

I’m stuck to
mount -t devpts pts /mnt/dev/pts/
It says/mnt/dev/pts/ does not exist. Is it critical?

Likely not critical, but might indicate you don’t have a /mnt/devm or that it should be

mount -t devpts pts /mnt/dev/pts

(no trailing /).

1 Like

Sounds to me like he wiped the UEFI entry from his machine and just needs to re-acquire/reconfigure it in hardware…

The command listed by @jonathon will add the entry back to his BIOS settings.

1 Like

If all else fails, boot up manjaro install media, you should get to manjaro grub.cfg using configfile.

When booted up to Manjaro, check (should be) /boot/efi is still valid.

findmnt /boot/efi

and do

sudo grub-install

And if you had installed any new OS since, do

sudo update-grub

Not necessary if no new OS installed.

note: no chroot needs to be done and no need to boot up install media OS.

Note - since you have a HP [1] you can additionally do after ‘grub-install’

sudo cp /boot/grub/x86_64-efi/core.efi /boot/efi/EFI/boot/bootx64.efi

But I think there is no need as your HP was fine before the 'reset’
but there is no harm in doing it.

[1] - There have been reports of HP not able to set bootorder other than the factory default.

1 Like

To my frustration I cannot do sudo mount /dev/sda8 /boot/efi as it says "special device /dev/sda8 does not exist"
I also tried sudo grub-install as you suggested later, and got “cannot find EFI directory”.
I’m chrooted [root@manjaro manjaro]#

PS: I’m pleased how fast you respond

I think you’re not responding to me as my post did not say anything about mounting sda8 and does not need chroot.

Please address reply to person as @person_name.
It would help if, at livecd boot, you can provide

sudo parted -l        (# small 'L')
efibootmgr -v

& contents of installed manjaro OS (sda8?) /etc/fstab

I was talking in the context of the Restore GRUB page
/dev/sda8/ - is my boot partition.

So in this context, you should
mount sda8 as boot. ( not /boot/efi)
and mount $esp as /boot/efi
before doing the chroot.

And of course, mount root before all these.

[manjaro@manjaro ~]$ sudo parted -l
Model: ATA SAMSUNG MZNLN256 (scsi)
Disk /dev/sda: 256GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags: 

Number  Start   End    Size    File system     Name                          Flags
 1      1049kB  473MB  472MB   ntfs            Basic data partition          hidden, diag
 2      473MB   577MB  104MB   fat32           EFI system partition          boot, esp
 3      577MB   593MB  16.8MB                  Microsoft reserved partition  msftres
 4      593MB   163GB  162GB   ntfs            Basic data partition          msftdata
 8      163GB   163GB  419MB   fat32                                         boot, hidden, esp
 5      163GB   206GB  43.0GB  ext4
 7      206GB   208GB  2154MB  linux-swap(v1)                                hidden
 6      256GB   256GB  268MB   fat32           Basic data partition          diag


Model: UFD 2.0 Silicon-Power4G (scsi)
Disk /dev/sdb: 3880MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type     File system  Flags                                                                                                                                                                                  
 1      32.8kB  2120MB  2120MB  primary               boot                                                                                                                                                                                   
 2      2120MB  2124MB  4194kB  primary               esp  


[manjaro@manjaro ~]$ efibootmgr -v                                                                                                                                                                                                           
BootCurrent: 000D                                                                                                                                                                                                                            
Timeout: 0 seconds                                                                                                                                                                                                                           
BootOrder: 000D,000E,000B,000A,0000,0001,0002,0003,0004,0005,0006,0007,0008,0009,000F                                                                                                                                                        
Boot0000  Startup Menu  FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)....ISPH                                                                                                                     
Boot0001  System Information    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                           
Boot0002  Bios Setup    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                                   
Boot0003  3rd Party Option ROM Management       FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                           
Boot0004  System Diagnostics    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                           
Boot0005  System Diagnostics    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                           
Boot0006  System Diagnostics    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                           
Boot0007  System Diagnostics    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                           
Boot0008  Boot Menu     FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                                   
Boot0009  HP Recovery   FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                                   
Boot000A* SAMSUNG MZNLN256HMHQ-000H7    BBS(HD,SAMSUNG MZNLN256HMHQ-000H7 ,0x400)/PciRoot(0x0)/Pci(0x17,0x0)/Sata(2,0,0)......ISPH                                                                                                           
Boot000B* UFD 2.0 Silicon-Power4G 12031382028E60023D4DECEA46F   BBS(HD,UFD 2.0 Silicon-Power4G 12031382028E60023D4DECEA46F,0x900)/PciRoot(0x0)/Pci(0x14,0x0)/USB(255,255)......ISPH                                                          
Boot000D* UFD 2.0 Silicon-Power4G 12031382028E60023D4DECEA46F   PciRoot(0x0)/Pci(0x14,0x0)/USB(0,0)N.....YM....R,Y.....ISPH                                                                                                                  
Boot000E* Windows Boot Manager  HD(2,GPT,30bf9063-5f72-422d-a3df-6c5f98548da9,0xe1800,0x31800)/File(\EFI\Microsoft\Boot\bootmgfw.efi)WINDOWS.........x...B.C.D.O.B.J.E.C.T.=.{.9.d.e.a.8.6.2.c.-.5.c.d.d.-.4.e.7.0.-.a.c.c.1.-.f.3.2.b.3.4.4.d.4.7.9.5.}...b....................ISPH                                                                                                                                                                                                      
Boot000F  Network Boot  FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH                                                                                                                   
Boot0011* IPV6 Network - Intel(R) Ethernet Connection (4) I219-V        PciRoot(0x0)/Pci(0x1f,0x6)/MAC(48ba4ef930b2,0)/IPv6([::]:<->[::]:,0,0)N.....YM....R,Y.....ISPH



# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a device; this may
# be used with UUID= as a more robust way to name devices that works even if
# disks are added and removed. See fstab(5).
#
# <file system>             <mount point>  <type>  <options>  <dump>  <pass>
UUID=E0E4-7927                            /boot/efi      vfat    defaults,noatime 0 2
UUID=347e17db-1cff-4674-9fc2-9362341c2271 /              ext4    defaults,noatime,discard 0 1
UUID=c098224b-4dc7-4238-ad23-f242ba1bb6ad swap           swap    defaults,noatime,discard 0 2
tmpfs                                     /tmp           tmpfs   defaults,noatime,mode=1777 0 0

To get fstab contents I chrooted before to /mnt
Sorry, but I don’t fully understand what I’m doing.

Good. In the sense your partitions and fstab are okay.
UUID=E0E4-7927 should be UUID of sda2 not sda8 (if unsure recheck with 'sudo ‘blkid’).

Now just follow my first post (post #9)
See the link in that post.

Remember, no chroot & no booting up livecd OS
And make sure you start up the livecd in uefi.

Use the configfile method to boot up your installed Manjaro OS in sda5.

And do the last cp command (after grub-install command)…
(because you do not have a manjaro listed in your efibootmgr).
sudo cp /boot/grub/x86_64-efi/core.efi /boot/efi/EFI/boot/bootx64.efi

Good luck.

ps: it is much easier than chroot method and much less dangerous than chroot (while in chroot and not exited properly it can cause unintended changes in chrooted OS if chroot procedure not done well)

1 Like

Writing separately…

Now, your fstab does not show a /boot entry.
You said sda8 is your "boot’ partition. [1]

If, in the case that UUID=E0E4-7927 is in fact sda8 and not sda2, first change your fstab to uuid of sda2. Then mount that sda2 to /boot/efi. then grub-install.

  1. change uuid at fstab to sda2

sudo mount /dev/sda2 /boot/efi
sudo grub-install
sudo cp /boot/grub/x86_64-efi/core.efi /boot/efi/EFI/boot/bootx64.efi

Good luck.

[1] - Since you said sda8 is “boot” partition, you must check if you have a “boot directory” in sda5, your Manjaro root partition. And that kernels and initramfs files are all there.

I think they are all there - just that you ‘misspoke’ that sda8 was your boot partition when in fact it was your /boot/efi or $esp partition.

1 Like

UUID=E0E4-7927 - is sda8. Is Mangaro /boot/efi partition. I know it by it’s start sector and size. sda2 (is closer to beginning of the disk) is efi partition of Windows.
I’ve read your two last posts and not sure which to follow.

Follow this. Remember, no chroot operations needed below.

  1. Take the manjaro livecd and start it up in uefi.
  2. Do not boot up to live OS, but press ‘c’ at the menu and we’ll get to the grub prompt (grub>).
  3. At grub prompt, check output of
    grub> echo $grub_platform
    If output is “pc”, reboot the livecd media, this time making sure it is booted up in uefi.
    If output is “efi”, continue below to step ‘4.’.
  4. grub> search -f /boot/intel-ucode.img --set=root
    grub> configfile /boot/grub/grub.cfg
  5. You will be presented with your original manjaro grub menu.
    Use this and boot to manjaro.
    If you do not see this manjaro boot menu, you may have messed up during your chroot earlier.
    Operations during chroot can be mess things up if not done properly. Let us know if you cannot get to this step (manjaro boot menu) and do not continue below.
  6. If you can boot up to manjaro installed OS, at terminal
sudo grub-install
sudo update-grub
sudo cp /boot/grub/x86_64-efi/core.efi /boot/efi/EFI/boot/bootx64.efi
  1. Done. Hope this is clear.
7 Likes

Thank you! It worked!
@gohlip can you suggest me some book to understand all this things better (partitions, boot loaders, efi)?

I have my restored Manjaro loading half time on my HP (what initially made me try to reset the UEFI). Shall I create a separate question for it?

1 Like

Good to hear and you’re welcome.

The grub documentation can be found at
https://www.gnu.org/software/grub/manual/grub/grub.html

It can also be assessed at the terminal, start at this section

info -f grub -n ‘Simple configuration’

press ‘q’ to exit.

Cheers, take care.

1 Like

Thank you very much, solved my problem posted to the german part of the forum too.

Greetings,
Andreas

Bitte. :slightly_smiling_face:

After I updated my BIOS/UEFI on my Lenovo Y700, I had this issue where it would just boot straight to windows without showing the GRUB menu.

This fixed it. This should get posted to the wiki, it is much easier than the steps outlined here.

Plus, it actually worked, unlike the guide above.

1 Like