Manually add boot options to GRUB

Hi there, recently I had to reinstall Manjaro (Gnome) because I messed up experimenting with the system (not much problem, because I made backups).
What happened is that the latest version of Manjaro ISO somehow managed to erase the Windows boot manager (It disappear from the BIOS), so I created a boot partition (Windows didn’t create different partitions during its installation) and now it appears in the BIOS, it also boots, but Grub does not detect it.

I have two SSD (SATA and NVME) and I use the SATA exclusively for Manjaro, and the NVME for Windows.
The first time I installed Manjaro, both bootmgr were in different disks and GRUB displayed them without a problem:

Manjaro (/dev/sda1/)
Windows Boot Manager (/dev/nvme0n1p2)

But now the os-prober does not find Windows. The only way I found is creating another boot partition for Windows in the SATA SSD, but I would like to know if there’s a way to make it work again like before, with both boot partitions in different SSD.
I assume one option could be editing manually the GRUB configuration or boot options, but I don’t know where to find it nor how to edit the boot options, google only provides me with the os-prober command.

This is what I already tried:

Mount the nvme disk partitions, use os-prober and then update-grub
Uncomment the os-prober option in GRUB config and then run update-grub

Here’s my system info:

  Kernel: 5.15.19-1-MANJARO x86_64 bits: 64 compiler: gcc v: 11.1.0
    Desktop: GNOME 41.3 tk: GTK 3.24.31 wm: gnome-shell dm: GDM 41.3
    Distro: Manjaro Linux base: Arch Linux
  Type: Laptop System: ASUSTeK product: ROG Strix G731GV_G731GV v: 1.0
    serial: <superuser required>
  Mobo: ASUSTeK model: G731GV v: 1.0 serial: <superuser required>
    UEFI: American Megatrends v: G731GV.309 date: 02/01/2021
  ID-1: BAT0 charge: 57.5 Wh (96.5%) condition: 59.6/66.0 Wh (90.3%)
    volts: 15.7 min: 15.7 model: ASUSTeK ASUS Battery type: Li-ion serial: N/A
    status: Not charging
  RAM: total: 31.21 GiB used: 2.71 GiB (8.7%)
  RAM Report:
    permissions: Unable to run dmidecode. Root privileges required.
  Info: 6-core model: Intel Core i7-9750H bits: 64 type: MT MCP smt: enabled
    arch: Coffee Lake rev: D cache: L1: 384 KiB L2: 1.5 MiB L3: 12 MiB
  Speed (MHz): avg: 825 high: 900 min/max: 800/4500 cores: 1: 800 2: 800
    3: 900 4: 850 5: 800 6: 800 7: 800 8: 800 9: 864 10: 800 11: 800 12: 895
    bogomips: 62431
  Flags: 3dnowprefetch abm acpi adx aes aperfmperf apic arat
    arch_capabilities arch_perfmon art avx avx2 bmi1 bmi2 bts clflush
    clflushopt cmov constant_tsc cpuid cpuid_fault cx16 cx8 de ds_cpl dtes64
    dtherm dts epb ept ept_ad erms est f16c flexpriority flush_l1d fma fpu
    fsgsbase fxsr ht hwp hwp_act_window hwp_epp hwp_notify ibpb ibrs
    ibrs_enhanced ida intel_pt invpcid invpcid_single lahf_lm lm mca mce
    md_clear mmx monitor movbe mpx msr mtrr nonstop_tsc nopl nx pae pat pbe
    pcid pclmulqdq pdcm pdpe1gb pebs pge pln pni popcnt pse pse36 pts rdrand
    rdseed rdtscp rep_good sdbg sep smap smep ss ssbd sse sse2 sse4_1 sse4_2
    ssse3 stibp syscall tm tm2 tpr_shadow tsc tsc_adjust tsc_deadline_timer
    vme vmx vnmi vpid x2apic xgetbv1 xsave xsavec xsaveopt xsaves xtopology
  Device-1: Intel CoffeeLake-H GT2 [UHD Graphics 630] vendor: ASUSTeK
    driver: i915 v: kernel bus-ID: 00:02.0 chip-ID: 8086:3e9b class-ID: 0300
  Device-2: NVIDIA TU106M [GeForce RTX 2060 Mobile] vendor: ASUSTeK
    driver: nvidia v: 510.47.03 bus-ID: 01:00.0 chip-ID: 10de:1f11
    class-ID: 0300
  Display: x11 server: compositor: gnome-shell driver:
    loaded: modesetting,nvidia alternate: fbdev,nouveau,nv,vesa
    resolution: <missing: xdpyinfo>
  Message: Unable to show advanced data. Required tool glxinfo missing.
  Device-1: Intel Cannon Lake PCH cAVS vendor: ASUSTeK driver: snd_hda_intel
    v: kernel bus-ID: 00:1f.3 chip-ID: 8086:a348 class-ID: 0403
  Device-2: NVIDIA TU106 High Definition Audio vendor: ASUSTeK
    driver: snd_hda_intel v: kernel bus-ID: 01:00.1 chip-ID: 10de:10f9
    class-ID: 0403
  Device-3: Sony WH-CH700N [Wireless Noise-Canceling Headphones] type: USB
    driver: hid-generic,usbhid bus-ID: 1-3:6 chip-ID: 054c:0c7f class-ID: 0300
    serial: <filter>
  Sound Server-1: ALSA v: k5.15.19-1-MANJARO running: yes
  Sound Server-2: JACK v: 1.9.20 running: no
  Sound Server-3: PulseAudio v: 15.0 running: yes
  Sound Server-4: PipeWire v: 0.3.45 running: no
  Device-1: Intel Cannon Lake PCH CNVi WiFi driver: iwlwifi v: kernel
    bus-ID: 00:14.3 chip-ID: 8086:a370 class-ID: 0280
  IF: wlo1 state: down mac: <filter>
  Device-2: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
    vendor: ASUSTeK driver: r8169 v: kernel port: 3000 bus-ID: 03:00.0
    chip-ID: 10ec:8168 class-ID: 0200
  IF: eno2 state: up speed: 1000 Mbps duplex: full mac: <filter>
  IP v4: <filter> type: dynamic noprefixroute scope: global
    broadcast: <filter>
  IP v6: <filter> type: noprefixroute scope: link
  Device-3: Sony WH-CH700N [Wireless Noise-Canceling Headphones] type: USB
    driver: hid-generic,usbhid bus-ID: 1-3:6 chip-ID: 054c:0c7f class-ID: 0300
    serial: <filter>
  Device-4: Microsoft XBOX ACC type: USB driver: mt76x2u bus-ID: 1-5:3
    chip-ID: 045e:02fe class-ID: 0000 serial: <filter>
  IF: wlp0s20f0u5 state: down mac: <filter>
  WAN IP: <filter>
  Device-1: Intel Bluetooth 9460/9560 Jefferson Peak (JfP) type: USB
    driver: btusb v: 0.8 bus-ID: 1-14:5 chip-ID: 8087:0aaa class-ID: e001
  Report: rfkill ID: hci0 rfk-id: 1 state: up address: see --recommends
  Message: No logical block device data found.
  Message: No RAID data found.
  Local Storage: total: 2.73 TiB used: 9.68 GiB (0.3%)
  ID-1: /dev/nvme0n1 vendor: Samsung model: SSD 980 PRO 2TB size: 1.82 TiB
    speed: 63.2 Gb/s lanes: 4 type: SSD serial: <filter> rev: 4B2QGXA7
    temp: 32.9 C scheme: GPT
  ID-2: /dev/sda vendor: Crucial model: CT1000MX500SSD1 size: 931.51 GiB
    speed: 6.0 Gb/s type: SSD serial: <filter> rev: 033 scheme: GPT
  Message: No optical or floppy data found.
  ID-1: / size: 758.05 GiB used: 9.68 GiB (1.3%) fs: ext4 dev: /dev/sda2
    label: root uuid: 9437841e-e53b-44ca-a4f3-c73d31ea0d17
  ID-2: /boot/efi size: 299.4 MiB used: 292 KiB (0.1%) fs: vfat
    dev: /dev/sda1 label: BOOT uuid: AE70-7484
  ID-1: swap-1 type: partition size: 32 GiB used: 0 KiB (0.0%) priority: -2
    dev: /dev/sda3 label: swap uuid: 7f3d5e15-e575-4b8a-a10c-e446003eeac3
  ID-1: /dev/nvme0n1p1 size: 16 MiB fs: <superuser required> label: N/A
    uuid: N/A
  ID-2: /dev/nvme0n1p2 size: 1.82 TiB fs: ntfs label: N/A
    uuid: B4C2A0F6C2A0BE4C
  ID-3: /dev/nvme0n1p3 size: 99 MiB fs: vfat label: NUEVO VOL
    uuid: 66C9-4206
  ID-4: /dev/sda4 size: 128 GiB fs: ntfs label: N/A uuid: 4A1BB1BF606783F5
  Hub-1: 1-0:1 info: Hi-speed hub with single TT ports: 16 rev: 2.0
    speed: 480 Mb/s chip-ID: 1d6b:0002 class-ID: 0900
  Device-1: 1-1:2 info: [Maxxter] Optical Gaming Mouse [Xtrem]
    type: Mouse,Keyboard driver: hid-generic,usbhid interfaces: 2 rev: 1.1
    speed: 1.5 Mb/s power: 100mA chip-ID: 18f8:0f97 class-ID: 0301
  Device-2: 1-3:6
    info: Sony WH-CH700N [Wireless Noise-Canceling Headphones] type: HID
    driver: hid-generic,usbhid interfaces: 1 rev: 2.0 speed: 12 Mb/s
    power: 400mA chip-ID: 054c:0c7f class-ID: 0300 serial: <filter>
  Device-3: 1-5:3 info: Microsoft XBOX ACC type: Network driver: mt76x2u
    interfaces: 1 rev: 2.0 speed: 480 Mb/s power: 500mA chip-ID: 045e:02fe
    class-ID: 0000 serial: <filter>
  Device-4: 1-8:4 info: ASUSTek N-KEY Device type: Keyboard
    driver: asus,usbhid interfaces: 3 rev: 2.0 speed: 12 Mb/s power: 100mA
    chip-ID: 0b05:1866 class-ID: 0301
  Device-5: 1-14:5 info: Intel Bluetooth 9460/9560 Jefferson Peak (JfP)
    type: Bluetooth driver: btusb interfaces: 2 rev: 2.0 speed: 12 Mb/s
    power: 100mA chip-ID: 8087:0aaa class-ID: e001
  Hub-2: 2-0:1 info: Super-speed hub ports: 8 rev: 3.1 speed: 10 Gb/s
    chip-ID: 1d6b:0003 class-ID: 0900
  System Temperatures: cpu: 43.0 C pch: 46.0 C mobo: N/A
  Fan Speeds (RPM): cpu: 2400
  Processes: 312 Uptime: 37m wakeups: 1 Init: systemd v: 250 Compilers:
  gcc: 11.1.0 Packages: pacman: 1152 Shell: Zsh v: 5.8
  running-in: gnome-terminal inxi: 3.3.12

edit /etc/default/grub as root - save and rebuild grub config

# grub-mkconfig -o /boot/grub/grub.cfg

That’s where I checked if GRUB_DISABLE_OS_PROBER was uncommented, and it was ok. Apart from that, I just see cosmetic options for GRUB

I actually find where the boot entries are stored: /boot/grub/grub.cfg
But it has a big comment “DO NOT EDIT THIS FILE”, so maybe I should not touch that. It will be replaced once I use grub-mkconfig anyways.

Still don’t find how to manually add an entry for Windows stored in a different SSD

unless you know what you’re doing.

After removing the comment from os prober you need to update grub(sudo update-grub). Have you done this?

If you want to manually add entries to Grub, it is best to add them in


This way they should appear each time Grub gets update (e.g. installing a new/updated kernel).

1 Like

Yes, this is better because it preserves the original grub.conf. However changes introduced in grub.conf are also updated with each kernel update.

if you want to avoid os-prober go hunting for where windows is, you can manually put a grub entry for windows as follows;
in aforementioned;



Now the only left problem is that I get this output when I’m trying to get the fs_uuid

grub-probe --target=fs_uuid /run/media/zxstem/B4C2A0F6C2A0BE4C/EFI/Microsoft/Boot/bootmgfw.efi 
grub-probe: warning: disk does not exist, so falling back to partition device /dev/nvme0n1p2.
grub-probe: warning: disk does not exist, so falling back to partition device /dev/nvme0n1p2.
grub-probe: warning: disk does not exist, so falling back to partition device /dev/nvme0n1p2.
grub-probe: error: disk `hostdisk//dev/nvme0n1p2' not found.

Just want to ask, this is mounted? I “mount” the partition using nautilus and it is technically mounted in “/run/media/zxstem/B4C2A0F6C2A0BE4C”. Or the error I got is because I didn’t do it properly using mount in terminal?

That should be enough to solve my problem.

Apart from that, the last week I tried to re-create the boot files for Windows inside the Manjaro boot partition. Just then the os-prober was able to find the Windows Boot Manager, but I feel that maybe I shouldn’t do that. Will I have a problem in the future because of this?

no you dont need to remount EFI partition, it should already be mounted. if the setup is still in the state it was when you got “inxi -Fazy” extract,

the command to get $fs_uuid;

sudo grub-probe --target=fs_uuid /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi

the command to get $hints_string;

sudo grub-probe --target=hints_string /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi

its not clear what you meant by “re-create the boot files for Windows”. os-prober is meant as a support tool for GRUB to auto-detect other installed OS(including windows) so that when kernels get updated or you execute “update-grub” manually, those detected OS would have their own entries in the GRUB menu. manually putting an entry like above is;

  1. safe unless windows chooses to alter the location of its bootloader(unlikely). it is more probable that windows 10 and later will overwrite GRUB though.
  2. os-prober is resource intensive, it will definitely make running update-grub take more time than having a set entry like above.

Oh, I used the bcdboot command

bcdboot d:\windows /s w: /f ALL

(‘w’ being the letter I assigned to an specific partition)

The first time I used this was when I accidentally deleted the boot partition a couple of years ago in an old pc, and did it in a separated partition.

This time, when doing it in it’s own partition, grub wasn’t able to find it regardless of which disk I was using to create the boot partition (It was still listed in bios). But somehow executing that command with ‘w’ being the boot partition for manjaro made it possible for grub to find the bootmgfw.