Add windows to linux grub

How can I add Windows 11 to grub menu?

My issues started when I partitioned my Ubuntu 22.04 LTS drive to add Windows 11 (I used my Ubuntu bootable to partition the drive). Once Windows 11 was installed, my computer began to boot Windows 11 instead of showing me the grub menu. I fixed this by entering the BIOS and moving Ubuntu to the top. My computer was booting into Ubuntu now, but I still wasn’t seeing the grub menu. After looking at this post, Why is Grub menu not shown when starting my computer?, I was able to get my grub menu to show again (@Akalgnotum). But Windows 11 was not included in the menu. With the guidance of this post, GRUB does not detect Windows I ran: sudo os-prober which returned /dev/nvme0n1p1@/EFI/Microsoft/Boot/bootmgfw.efi:Windows Boot Manager:Windows:efi . I then ran sudo update-grub which gave me this «warning»:

Sourcing file `/etc/default/grub' Sourcing file `/etc/default/grub.d/init-select.cfg' Generating grub configuration file . Found linux image: /boot/vmlinuz-5.15.0-46-generic Found initrd image: /boot/initrd.img-5.15.0-46-generic Found linux image: /boot/vmlinuz-5.15.0-43-generic Found initrd image: /boot/initrd.img-5.15.0-43-generic Memtest86+ needs a 16-bit boot, that is not available on EFI, exiting Warning: os-prober will not be executed to detect other bootable partitions. Systems on them will not be added to the GRUB boot configuration. Check GRUB_DISABLE_OS_PROBER documentation entry. Adding boot menu entry for UEFI Firmware Settings . done 

From what I gather, Windows won’t be added by sudo update-grub because it won’t run and use the information given by os-prober. I have no idea how to fix this. Any suggestions would be extremely helpful. If more information is needed, I’ll be happy to provide it. Thanks!

Читайте также:  Сколько linux нужно оперативной памяти

Источник

How to add Windows 10 to grub boot loader?

Also, I have tried to change grub config with this answer https://askubuntu.com/questions/661947/add-windows-10-to-grub-os-list#answer-977251 — But in this case, There is Windows 10 — but when I chose — I will recursively going to grub

And with this answer https://askubuntu.com/questions/661947/add-windows-10-to-grub-os-list#answer-890562 I have an error message when chose Windows 10 — There is no bootmgr directory

Thanks @Kinnectus for help

/dev/sda1:FreeDOS:FreeDOS:chain /dev/sda2:FreeDOS:FreeDOS1:chain 
Generating grub configuration file . Found linux image: /boot/vmlinuz-4.10.0-38-generic Found initrd image: /boot/initrd.img-4.10.0-38-generic Found memtest86+ image: /boot/memtest86+.elf Found memtest86+ image: /boot/memtest86+.bin Found FreeDOS on /dev/sda1 Found FreeDOS on /dev/sda2 done 

Unfortunately — there is not Windows 10 in grub menu

Device Boot Start End Sectors Size Id Type /dev/sda1 2048 16779263 16777216 8G c W95 FAT32 (LBA) /dev/sda2 * 16779264 33556479 16777216 8G c W95 FAT32 (LBA) /dev/sda3 33556480 770219115 736662636 351,3G 7 HPFS/NTFS/exFAT /dev/sda4 770220030 976771071 206551042 98,5G 5 Extended /dev/sda5 770220032 976771071 206551040 98,5G 83 Linux Partition 4 does not start on physical sector boundary. 

There is an issue. Maybe the problem is with this issue?

Please, help me, I am stucking with this a whole day. I completely have no idea, what am I doing wrong.

Источник

How to add Windows to GRUB

I have my encrypted Archlinux installed on my SSD. Now I have one HDD with Windows installed. But in my GRUB just Archlinux is shown (no Wonder, because I just installed Windows on the other HDD, GRUB doesn’t know of that by now.). My Question is, how do I properly add my Windows-HDD to GRUB, so that I can choose which to boot when starting? I am a little bit afraid of destroying my GRUB so I can’t boot my encrypted Archlinux anymore. Thanks!

Читайте также:  Либре офис альт линукс

Look at your grub config file grub.cfg and add a menu entry to chain load windows. Search terms: ‘chain boot’ ‘grub.cfg’

1 Answer 1

Save a backup of your all your grub configuration files.

There are two methods I have used in the past:

1) Install ntfs-3g (which should allow your installation to see the windows partition automatically) using your package manager. It was available in the EPEL repo for me, but you’ll have to find a different repo for it on Arch.

Then sudo grub2-mkconfig . This worked for me while trying to get my centos7 dual boot to work with windows.

2) Alternately, you’d be best off adding a custom entry by adding a file to /etc/grub.d/

For example, on my current system which is a Centos7 + Windows 10 dual boot:

$ sudo cat /etc/grub.d/40_custom #!/bin/sh exec tail -n +3 $0 # This file provides an easy way to add custom menu entries. Simply type the # menu entries you want to add after this comment. Be careful not to change # the 'exec tail' line above. menuentry "Windows 10"

Where the menuentry parameter is the name that will appear in the grub menu. The (hd0,1) will change depending on what hard disk and what partition you have windows on.

Источник

Как добавить windows 10 в меню загрузки grub?

На ssd стояла windows 10.
Разбил hdd под установку linux mint, но после его установки загружалась только windows 10. Решил это чистой установкой Linux, установщик разбил диск как ему надо. Как итог linux грузится, windows 10 — нет, и кроме того не могу войти в настройки bios: меню загрузки там пустое, bios setup не открывается.
В меню загрузки grub есть только linux.
Есть ли способ добавить windows в меню загрузчика grub, как убедиться, что она сможет запуститься, и это не убьет работающий Linux?

Читайте также:  Дефолтный пароль kali linux

5d113880dae20436574156.jpeg

Grub выглядит так:

По команде lsblk результат такой:

NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 465,8G 0 disk ├─sda1 8:1 0 512M 0 part /boot/efi └─sda2 8:2 0 465,3G 0 part / sdb 8:16 0 118G 0 disk ├─sdb1 8:17 0 117,2G 0 part └─sdb2 8:18 0 790M 0 part
Device Boot Start End Sectors Size Id Type /dev/sdb1 * 2048 245839254 245837207 117,2G 7 HPFS/NTFS/exFAT /dev/sdb2 245839872 247457791 1617920 790M 27 Hidden NTFS WinRE
/dev/sdb1: LABEL="M-PM-^TM-PM-8M-QM-^AM-PM-:" UUID="2EE6EE17E6EDDF59" TYPE="ntfs" PARTUUID="d7209484-01"

upd
Добавил руками пункт загрузки в grub как написано в статье.

При выборе — error: invalid EFI file path.

ps. Если бы была возможность зайти в bios, с удовольствием бы снес все и накатил заново винду (или восстановил с загрузочной флешки). С проблемой столкнулся не впервые, но в прошлый раз пришлось прибегнуть к прошивке bios на программаторе. Хотелось бы обойтись без такой хирургии, тк не желательно отдавать ноут на несколько дней.

Простой 2 комментария

Источник

Оцените статью
Adblock
detector