• [gentoo-user] [offtopic] dual boot Windows 11 / Linux

    From Helmut Jarausch@21:1/5 to All on Sun Apr 10 13:20:01 2022
    Hi,

    I have purchased a new Laptop with Windows 11 pre-installed.
    I have managed to do (so far)

    - shrink the Windows partition (from within Windows since it's
    encrypted)
    - turned off secure boot to be able to boot a Linux rescue system from
    USB
    - created new partitions (boot, root and home)
    - copied a gentoo system from a similar laptop onto the root partition
    - reinstalled grub2 (after doing chroot)

    My problem now is that I can't select the Gentoo partition within BIOS
    since this partition isn't offered as a boot option.

    Many thanks for any hints or pointers,
    Helmut

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Wol@21:1/5 to Helmut Jarausch on Sun Apr 10 15:10:01 2022
    On 10/04/2022 12:14, Helmut Jarausch wrote:
    Hi,

    I have purchased a new Laptop with Windows 11 pre-installed.
    I have managed to do (so far)

    - shrink the Windows partition (from within Windows since it's encrypted)
    - turned off secure boot to be able to boot a Linux rescue system from USB
    - created new partitions (boot, root and home)
    - copied a gentoo system from a similar laptop onto the root partition
    - reinstalled grub2 (after doing chroot)

    My problem now is that I can't select the Gentoo partition within BIOS
    since this partition isn't offered as a boot option.

    Because, as Windows is installed, BIUS isn't an option?

    Look at UEFI boot. You can install grub into UEFI, but probably not here because Windows will have given you pretty much no space. If you can get
    the kernel and initramfs into the UEFI partition you should hopefully be
    okay. Your problem will be squeezing ANYthing into the space Windows has
    left.

    As for helping you do it, sorry I haven't. My two laptops that came with
    linux, one I've added Windows, the other I have yet to configure. The
    one that came with Windows still has no linux ...

    Cheers,
    Wol

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From =?UTF-8?B?0KHQtdGA0LXQs9CwINCk0LjQu@21:1/5 to jarausch@skynet.be on Sun Apr 10 16:00:01 2022
    If it's a similar laptop I assume you have grub2 installed in EFI mode.
    Check if you have grubx64.efi in your EFI partition (usually /<mounted EFI partition>/EFI/gentoo/).
    Also check if you have efi boot entry for grub with efibootmgr utility. if grub-install with EFI target was used on a new system it should call
    efibootmgr to add a Gentoo entry in UEFI).

    If you are trying to install grub in legacy mode then look in UEFI settings
    if CSM or legacy boot is enabled. But since you have win11 and you want
    dual boot I don't think that it's what you want. Os-prober will not pick up
    EFI win11 installation if grub is installed in legacy and you can't install win11 in legacy since Microsoft made win11 UEFI-only.

    On Sun, Apr 10, 2022, 15:15 Helmut Jarausch <jarausch@skynet.be> wrote:

    Hi,

    I have purchased a new Laptop with Windows 11 pre-installed.
    I have managed to do (so far)

    - shrink the Windows partition (from within Windows since it's
    encrypted)
    - turned off secure boot to be able to boot a Linux rescue system from
    USB
    - created new partitions (boot, root and home)
    - copied a gentoo system from a similar laptop onto the root partition
    - reinstalled grub2 (after doing chroot)

    My problem now is that I can't select the Gentoo partition within BIOS
    since this partition isn't offered as a boot option.

    Many thanks for any hints or pointers,
    Helmut



    <div dir="auto">If it&#39;s a similar laptop I assume you have grub2 installed in EFI mode.<div dir="auto">Check if you have grubx64.efi in your EFI partition (usually /&lt;mounted EFI partition&gt;/EFI/gentoo/).</div><div dir="auto">Also check if you
    have efi boot entry for grub with efibootmgr utility. if grub-install with EFI target was used on a new system it should call efibootmgr to add a Gentoo entry in UEFI).</div><div dir="auto"><br></div><div dir="auto">If you are trying to install grub in
    legacy mode then look in UEFI settings if CSM or legacy boot is enabled. But since you have win11 and you want dual boot I don&#39;t think that it&#39;s what you want. Os-prober will not pick up EFI win11 installation if grub is installed in legacy and
    you can&#39;t install win11 in legacy since Microsoft made win11 UEFI-only.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sun, Apr 10, 2022, 15:15 Helmut Jarausch &lt;<a href="mailto:jarausch@skynet.be">jarausch@skynet.be</
    &gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>

    I have purchased a new Laptop with Windows 11 pre-installed.<br>
    I have managed to do (so far)<br>

    - shrink the Windows partition (from within Windows since it&#39;s  <br> encrypted)<br>
    - turned off secure boot to be able to boot a Linux rescue system from  <br> USB<br>
    - created new partitions (boot, root and home)<br>
    - copied a gentoo system from a similar laptop onto the root partition<br>
    - reinstalled grub2 (after doing chroot)<br>

    My problem now is that I can&#39;t select the Gentoo partition within BIOS<br> since this partition isn&#39;t offered as a boot option.<br>

    Many thanks for any hints or pointers,<br>
    Helmut<br>

    </blockquote></div>

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Mark Knecht@21:1/5 to raxp.worm202@gmail.com on Sun Apr 10 16:40:01 2022
    On Sun, Apr 10, 2022 at 6:59 AM Серега Филатов <raxp.worm202@gmail.com> wrote:

    If it's a similar laptop I assume you have grub2 installed in EFI mode.
    Check if you have grubx64.efi in your EFI partition (usually /<mounted EFI partition>/EFI/gentoo/).
    Also check if you have efi boot entry for grub with efibootmgr utility. if grub-install with EFI target was used on a new system it should call efibootmgr to add a Gentoo entry in UEFI).

    If you are trying to install grub in legacy mode then look in UEFI settings if CSM or legacy boot is enabled. But since you have win11 and you want dual boot I don't think that it's what you want. Os-prober will not pick up EFI win11 installation if
    grub is installed in legacy and you can't install win11 in legacy since Microsoft made win11 UEFI-only.

    On Sun, Apr 10, 2022, 15:15 Helmut Jarausch <jarausch@skynet.be> wrote:

    Hi,

    I have purchased a new Laptop with Windows 11 pre-installed.
    I have managed to do (so far)

    - shrink the Windows partition (from within Windows since it's
    encrypted)
    - turned off secure boot to be able to boot a Linux rescue system from
    USB
    - created new partitions (boot, root and home)
    - copied a gentoo system from a similar laptop onto the root partition
    - reinstalled grub2 (after doing chroot)

    My problem now is that I can't select the Gentoo partition within BIOS
    since this partition isn't offered as a boot option.

    Many thanks for any hints or pointers,
    Helmut


    An example:

    root@science2:~# ls -al /boot/efi/
    total 6
    drwx------ 3 root root 1024 Dec 31 1969 .
    drwxr-xr-x 4 root root 4096 Mar 29 14:37 ..
    drwx------ 5 root root 1024 Feb 13 15:35 EFI
    root@science2:~# ls -al /boot/efi/EFI/
    total 5
    drwx------ 5 root root 1024 Feb 13 15:35 .
    drwx------ 3 root root 1024 Dec 31 1969 ..
    drwx------ 2 root root 1024 Feb 13 15:35 Boot
    drwx------ 4 root root 1024 Dec 1 20:43 Microsoft
    drwx------ 2 root root 1024 Feb 13 15:35 ubuntu
    root@science2:~# ls -al /boot/efi/EFI/Boot/
    total 1857
    drwx------ 2 root root 1024 Feb 13 15:35 .
    drwx------ 5 root root 1024 Feb 13 15:35 ..
    -rwx------ 1 root root 955656 Feb 13 15:35 bootx64.efi
    -rwx------ 1 root root 85672 Feb 13 15:35 fbx64.efi
    -rwx------ 1 root root 856232 Feb 13 15:35 mmx64.efi
    root@science2:~# ls -al /boot/efi/EFI/Microsoft/
    total 8
    drwx------ 4 root root 1024 Dec 1 20:43 .
    drwx------ 5 root root 1024 Feb 13 15:35 ..
    drwx------ 40 root root 5120 Dec 1 20:43 Boot
    drwx------ 2 root root 1024 Dec 1 20:44 Recovery
    root@science2:~# ls -al /boot/efi/EFI/ubuntu/
    total 3457
    drwx------ 2 root root 1024 Feb 13 15:35 .
    drwx------ 5 root root 1024 Feb 13 15:35 ..
    -rwx------ 1 root root 108 Feb 13 15:35 BOOTX64.CSV
    -rwx------ 1 root root 117 Feb 13 15:35 grub.cfg
    -rwx------ 1 root root 1722240 Feb 13 15:35 grubx64.efi
    -rwx------ 1 root root 856232 Feb 13 15:35 mmx64.efi
    -rwx------ 1 root root 955656 Feb 13 15:35 shimx64.efi
    root@science2:~#

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael@21:1/5 to All on Sun Apr 10 17:01:23 2022
    On Sunday, 10 April 2022 14:58:26 BST Серега Филатов wrote:
    If it's a similar laptop I assume you have grub2 installed in EFI mode.
    Check if you have grubx64.efi in your EFI partition (usually /<mounted EFI partition>/EFI/gentoo/).
    Also check if you have efi boot entry for grub with efibootmgr utility. if grub-install with EFI target was used on a new system it should call efibootmgr to add a Gentoo entry in UEFI).

    If you are trying to install grub in legacy mode then look in UEFI settings if CSM or legacy boot is enabled. But since you have win11 and you want
    dual boot I don't think that it's what you want. Os-prober will not pick up EFI win11 installation if grub is installed in legacy and you can't install win11 in legacy since Microsoft made win11 UEFI-only.

    Some UEFI firmware is buggy and may not pick up a new OS bootloader in the ESP,
    at least not pick it up initially. In these cases temporarily changing a UEFI setting to nudge the firmware to parse the ESP for boot menu entries will help.
    So /should/ running the efibootmgr to create an entry with grub's efi image. -----BEGIN PGP SIGNATURE-----

    iQIzBAABCAAdFiEEXqhvaVh2ERicA8Ceseqq9sKVZxkFAmJS/1MACgkQseqq9sKV ZxnjKw//Sf8lQW521soFj7uC0MePco0dYiozVa16VJj1X2w68ndiRQKyz0unctBk CfX9/waKjFNYCcWzaaf3pVKTFtomdslcqq10Fc0TrzKBkkRnEq68YNV5uZSZ9YYH NvplHnlR4kjT2hYj7lUyVqWxjTCcsLJmOXu+gpVOzP5dyyW3TWzN4E/ojj4jb9z8 MOQTSwD6+/7GyCeSKf6916DWQVVc9TS8BqyLKY/0G+v9juVXiNIoXKwfenKmtnIZ +htLP+bZsfGyupvuA+0QCGJeqYC1XDvBVovM40NpDPfseo0xIKVXXlvqN2f9qFIe rTwnLesTkKLjM5LoMg6FmZ1R87n0JMhI+by8PhaFMuawibFz7rY22XiHSs8IiE8Q lD+SJpTBlZkxRxGVh3I87eM0LCqm5JLRoNwZ85+mXRATvWyJB74OWfGTN8cYw/Q3 wt8YWlMIr8Izz32iUpC6jB0lFVjiJFP8blZKAVXmMNWtkJyPRpINPNl0ot7ZlSnd NwB/RRbRddU7oG2aYUJfN5E1uVROI6u/xH6mtOOfTirV09ldjKJLinyeKaUQ+pFv CGwZA+HSYa4jXTMR68puwp22iGWSJ57LuNmK9+0nIhrQmeR3xIEhwdWlc5njdc5g F2SZNUcFzvtYw/bEuCayEX9H6ha+pqzZOOW6rwyalFIGKwagnlM=
    =xBQw
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From =?UTF-8?B?0KHQtdGA0LXQs9CwINCk0LjQu@21:1/5 to confabulate@kintzios.com on Sun Apr 10 19:10:01 2022
    Also if you've booted your live media in legacy mode then efibootmgr might
    not do anything because efivars are not accessible in this mode. That could explain the situation when you have grubx64.efi but no boot entry. So check that you're booting live system in UEFI too.

    On Sun, Apr 10, 2022, 20:02 Michael <confabulate@kintzios.com> wrote:

    On Sunday, 10 April 2022 14:58:26 BST Серега Филатов wrote:
    If it's a similar laptop I assume you have grub2 installed in EFI mode. Check if you have grubx64.efi in your EFI partition (usually /<mounted
    EFI
    partition>/EFI/gentoo/).
    Also check if you have efi boot entry for grub with efibootmgr utility.
    if
    grub-install with EFI target was used on a new system it should call efibootmgr to add a Gentoo entry in UEFI).

    If you are trying to install grub in legacy mode then look in UEFI
    settings
    if CSM or legacy boot is enabled. But since you have win11 and you want dual boot I don't think that it's what you want. Os-prober will not pick
    up
    EFI win11 installation if grub is installed in legacy and you can't
    install
    win11 in legacy since Microsoft made win11 UEFI-only.

    Some UEFI firmware is buggy and may not pick up a new OS bootloader in the ESP,
    at least not pick it up initially. In these cases temporarily changing a UEFI
    setting to nudge the firmware to parse the ESP for boot menu entries will help.
    So /should/ running the efibootmgr to create an entry with grub's efi
    image.

    <div dir="auto">Also if you&#39;ve booted your live media in legacy mode then efibootmgr might not do anything because efivars are not accessible in this mode. That could explain the situation when you have grubx64.efi but no boot entry. So check that
    you&#39;re booting live system in UEFI too.</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sun, Apr 10, 2022, 20:02 Michael &lt;<a href="mailto:confabulate@kintzios.com">confabulate@kintzios.com</a>&gt; wrote:<br></div><blockquote
    class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Sunday, 10 April 2022 14:58:26 BST Серега Филатов wrote:<br>
    &gt; If it&#39;s a similar laptop I assume you have grub2 installed in EFI mode.<br>
    &gt; Check if you have grubx64.efi in your EFI partition (usually /&lt;mounted EFI<br>
    &gt; partition&gt;/EFI/gentoo/).<br>
    &gt; Also check if you have efi boot entry for grub with efibootmgr utility. if<br>
    &gt; grub-install with EFI target was used on a new system it should call<br> &gt; efibootmgr to add a Gentoo entry in UEFI).<br>
    &gt; <br>
    &gt; If you are trying to install grub in legacy mode then look in UEFI settings<br>
    &gt; if CSM or legacy boot is enabled. But since you have win11 and you want<br>
    &gt; dual boot I don&#39;t think that it&#39;s what you want. Os-prober will not pick up<br>
    &gt; EFI win11 installation if grub is installed in legacy and you can&#39;t install<br>
    &gt; win11 in legacy since Microsoft made win11 UEFI-only.<br>

    Some UEFI firmware is buggy and may not pick up a new OS bootloader in the ESP, <br>
    at least not pick it up initially.  In these cases temporarily changing a UEFI <br>
    setting to nudge the firmware to parse the ESP for boot menu entries will help.  <br>
    So /should/ running the efibootmgr to create an entry with grub&#39;s efi image.</blockquote></div>

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)