Boot Win10 from an ISO-Image on a certain partition using GRUB2












2















I have bought a laptop (Lenovo ThinkPad T520) with a locked BIOS. So I can't change the boot order of the laptop. The upmost device in the boot order is the internal HDD. Fortunately there is a working Linux with Grub2 installed, which I have access to.



I also want to install Windows 10 now. How do I have to change the Grub2-configuration in order to be able to boot the Windows-installation from a Win10-Boot-Medium (ISO)?










share|improve this question



























    2















    I have bought a laptop (Lenovo ThinkPad T520) with a locked BIOS. So I can't change the boot order of the laptop. The upmost device in the boot order is the internal HDD. Fortunately there is a working Linux with Grub2 installed, which I have access to.



    I also want to install Windows 10 now. How do I have to change the Grub2-configuration in order to be able to boot the Windows-installation from a Win10-Boot-Medium (ISO)?










    share|improve this question

























      2












      2








      2


      3






      I have bought a laptop (Lenovo ThinkPad T520) with a locked BIOS. So I can't change the boot order of the laptop. The upmost device in the boot order is the internal HDD. Fortunately there is a working Linux with Grub2 installed, which I have access to.



      I also want to install Windows 10 now. How do I have to change the Grub2-configuration in order to be able to boot the Windows-installation from a Win10-Boot-Medium (ISO)?










      share|improve this question














      I have bought a laptop (Lenovo ThinkPad T520) with a locked BIOS. So I can't change the boot order of the laptop. The upmost device in the boot order is the internal HDD. Fortunately there is a working Linux with Grub2 installed, which I have access to.



      I also want to install Windows 10 now. How do I have to change the Grub2-configuration in order to be able to boot the Windows-installation from a Win10-Boot-Medium (ISO)?







      linux windows windows-10 iso-image grub2






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Sep 5 '18 at 19:48









      Arch Linux TuxArch Linux Tux

      19315




      19315






















          1 Answer
          1






          active

          oldest

          votes


















          5














          To boot the Win10-Image from your HDD:




          1. Add the below code to /etc/grub.d/40_custom

          2. Back up /boot/grub/grub.cfg with sudo cp /boot/grub/grub.cfg.bak. (Or add a number, if there already is a grub.cfg.bak.)

          3. Then run sudo grub-mkconfig -o /boot/grub/grub.cfg.


          Grub2-configuration:



          menuentry "Windows 10" --class windows --class os {
          # Insert modules needed in order to access the iso-file
          insmod part_gpt
          #insmod part_msdos

          insmod ntfs
          #insmod ext2

          # Insert module needed in order to find partition
          insmod search_fs_uuid


          # Set UUID of partition with the iso-image
          # and let grub2 find the partition
          # (save it's identifier to the variable $root)
          set uuid="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
          search --no-floppy --set=root --fs-uuid $uuid

          # Mount the iso image by addressing it with (partition)/path
          set iso=/images/Win10_English_x64.iso
          loopback loop ($root)$iso


          # boot (chain-load) the image using the cdboot.efi file located
          # on the win10-image
          chainloader (loop)/efi/microsoft/boot/cdboot.efi
          }


          Instructions:



          Replace XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX with the UUID of the partition, that holds the Windows 10 image.





          insmod part_gpt: This module is needed, if the Win10-ISO-Image lies on a drive with a GPT-partitiontable.



          insmod part_msdos: Choose this one over insmod part_gpt, if the image lies on a drive with DOS-partitiontable.





          insmod ntfs: This module is needed, if the Win10-ISO-Image lies a NTFS-partition.



          insmod ext2: Replace insmod ntfs with insmod ext2, when the image lies on a ext2/ext3 or ext4 partition.






          share|improve this answer


























          • I have a system that boots in Legacy BIOS mode. I have an iso on an ntfs partition so I chose insmod ntfs and chose insmod part_msdos (and in a separate attempt insmod part_gpt1) but I get error: invalid signature` which my research shows has something to do with UEFI. WHich seems to relate to cdboot.efi. What should I use for legacy bios mode?

            – 0fnt
            Jan 26 at 18:22













          • @0fnt Take a look at: wiki.gentoo.org/wiki/GRUB2/… Try adding insmod chain and replace the last line with chainloader (loop)+1

            – Arch Linux Tux
            Jan 27 at 15:34








          • 1





            superuser.com/users/352691/arch-linux-tux @arch-linux-tux Thanks- I tried it but I had the same error: invalid signature. I even had secure boot disabled. For now I copied ISO contents to a partition and used ntldr /bootmgr but if you do come across a solution- please do mention. Thanks

            – 0fnt
            Jan 28 at 6:16











          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "3"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1355604%2fboot-win10-from-an-iso-image-on-a-certain-partition-using-grub2%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          5














          To boot the Win10-Image from your HDD:




          1. Add the below code to /etc/grub.d/40_custom

          2. Back up /boot/grub/grub.cfg with sudo cp /boot/grub/grub.cfg.bak. (Or add a number, if there already is a grub.cfg.bak.)

          3. Then run sudo grub-mkconfig -o /boot/grub/grub.cfg.


          Grub2-configuration:



          menuentry "Windows 10" --class windows --class os {
          # Insert modules needed in order to access the iso-file
          insmod part_gpt
          #insmod part_msdos

          insmod ntfs
          #insmod ext2

          # Insert module needed in order to find partition
          insmod search_fs_uuid


          # Set UUID of partition with the iso-image
          # and let grub2 find the partition
          # (save it's identifier to the variable $root)
          set uuid="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
          search --no-floppy --set=root --fs-uuid $uuid

          # Mount the iso image by addressing it with (partition)/path
          set iso=/images/Win10_English_x64.iso
          loopback loop ($root)$iso


          # boot (chain-load) the image using the cdboot.efi file located
          # on the win10-image
          chainloader (loop)/efi/microsoft/boot/cdboot.efi
          }


          Instructions:



          Replace XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX with the UUID of the partition, that holds the Windows 10 image.





          insmod part_gpt: This module is needed, if the Win10-ISO-Image lies on a drive with a GPT-partitiontable.



          insmod part_msdos: Choose this one over insmod part_gpt, if the image lies on a drive with DOS-partitiontable.





          insmod ntfs: This module is needed, if the Win10-ISO-Image lies a NTFS-partition.



          insmod ext2: Replace insmod ntfs with insmod ext2, when the image lies on a ext2/ext3 or ext4 partition.






          share|improve this answer


























          • I have a system that boots in Legacy BIOS mode. I have an iso on an ntfs partition so I chose insmod ntfs and chose insmod part_msdos (and in a separate attempt insmod part_gpt1) but I get error: invalid signature` which my research shows has something to do with UEFI. WHich seems to relate to cdboot.efi. What should I use for legacy bios mode?

            – 0fnt
            Jan 26 at 18:22













          • @0fnt Take a look at: wiki.gentoo.org/wiki/GRUB2/… Try adding insmod chain and replace the last line with chainloader (loop)+1

            – Arch Linux Tux
            Jan 27 at 15:34








          • 1





            superuser.com/users/352691/arch-linux-tux @arch-linux-tux Thanks- I tried it but I had the same error: invalid signature. I even had secure boot disabled. For now I copied ISO contents to a partition and used ntldr /bootmgr but if you do come across a solution- please do mention. Thanks

            – 0fnt
            Jan 28 at 6:16
















          5














          To boot the Win10-Image from your HDD:




          1. Add the below code to /etc/grub.d/40_custom

          2. Back up /boot/grub/grub.cfg with sudo cp /boot/grub/grub.cfg.bak. (Or add a number, if there already is a grub.cfg.bak.)

          3. Then run sudo grub-mkconfig -o /boot/grub/grub.cfg.


          Grub2-configuration:



          menuentry "Windows 10" --class windows --class os {
          # Insert modules needed in order to access the iso-file
          insmod part_gpt
          #insmod part_msdos

          insmod ntfs
          #insmod ext2

          # Insert module needed in order to find partition
          insmod search_fs_uuid


          # Set UUID of partition with the iso-image
          # and let grub2 find the partition
          # (save it's identifier to the variable $root)
          set uuid="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
          search --no-floppy --set=root --fs-uuid $uuid

          # Mount the iso image by addressing it with (partition)/path
          set iso=/images/Win10_English_x64.iso
          loopback loop ($root)$iso


          # boot (chain-load) the image using the cdboot.efi file located
          # on the win10-image
          chainloader (loop)/efi/microsoft/boot/cdboot.efi
          }


          Instructions:



          Replace XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX with the UUID of the partition, that holds the Windows 10 image.





          insmod part_gpt: This module is needed, if the Win10-ISO-Image lies on a drive with a GPT-partitiontable.



          insmod part_msdos: Choose this one over insmod part_gpt, if the image lies on a drive with DOS-partitiontable.





          insmod ntfs: This module is needed, if the Win10-ISO-Image lies a NTFS-partition.



          insmod ext2: Replace insmod ntfs with insmod ext2, when the image lies on a ext2/ext3 or ext4 partition.






          share|improve this answer


























          • I have a system that boots in Legacy BIOS mode. I have an iso on an ntfs partition so I chose insmod ntfs and chose insmod part_msdos (and in a separate attempt insmod part_gpt1) but I get error: invalid signature` which my research shows has something to do with UEFI. WHich seems to relate to cdboot.efi. What should I use for legacy bios mode?

            – 0fnt
            Jan 26 at 18:22













          • @0fnt Take a look at: wiki.gentoo.org/wiki/GRUB2/… Try adding insmod chain and replace the last line with chainloader (loop)+1

            – Arch Linux Tux
            Jan 27 at 15:34








          • 1





            superuser.com/users/352691/arch-linux-tux @arch-linux-tux Thanks- I tried it but I had the same error: invalid signature. I even had secure boot disabled. For now I copied ISO contents to a partition and used ntldr /bootmgr but if you do come across a solution- please do mention. Thanks

            – 0fnt
            Jan 28 at 6:16














          5












          5








          5







          To boot the Win10-Image from your HDD:




          1. Add the below code to /etc/grub.d/40_custom

          2. Back up /boot/grub/grub.cfg with sudo cp /boot/grub/grub.cfg.bak. (Or add a number, if there already is a grub.cfg.bak.)

          3. Then run sudo grub-mkconfig -o /boot/grub/grub.cfg.


          Grub2-configuration:



          menuentry "Windows 10" --class windows --class os {
          # Insert modules needed in order to access the iso-file
          insmod part_gpt
          #insmod part_msdos

          insmod ntfs
          #insmod ext2

          # Insert module needed in order to find partition
          insmod search_fs_uuid


          # Set UUID of partition with the iso-image
          # and let grub2 find the partition
          # (save it's identifier to the variable $root)
          set uuid="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
          search --no-floppy --set=root --fs-uuid $uuid

          # Mount the iso image by addressing it with (partition)/path
          set iso=/images/Win10_English_x64.iso
          loopback loop ($root)$iso


          # boot (chain-load) the image using the cdboot.efi file located
          # on the win10-image
          chainloader (loop)/efi/microsoft/boot/cdboot.efi
          }


          Instructions:



          Replace XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX with the UUID of the partition, that holds the Windows 10 image.





          insmod part_gpt: This module is needed, if the Win10-ISO-Image lies on a drive with a GPT-partitiontable.



          insmod part_msdos: Choose this one over insmod part_gpt, if the image lies on a drive with DOS-partitiontable.





          insmod ntfs: This module is needed, if the Win10-ISO-Image lies a NTFS-partition.



          insmod ext2: Replace insmod ntfs with insmod ext2, when the image lies on a ext2/ext3 or ext4 partition.






          share|improve this answer















          To boot the Win10-Image from your HDD:




          1. Add the below code to /etc/grub.d/40_custom

          2. Back up /boot/grub/grub.cfg with sudo cp /boot/grub/grub.cfg.bak. (Or add a number, if there already is a grub.cfg.bak.)

          3. Then run sudo grub-mkconfig -o /boot/grub/grub.cfg.


          Grub2-configuration:



          menuentry "Windows 10" --class windows --class os {
          # Insert modules needed in order to access the iso-file
          insmod part_gpt
          #insmod part_msdos

          insmod ntfs
          #insmod ext2

          # Insert module needed in order to find partition
          insmod search_fs_uuid


          # Set UUID of partition with the iso-image
          # and let grub2 find the partition
          # (save it's identifier to the variable $root)
          set uuid="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
          search --no-floppy --set=root --fs-uuid $uuid

          # Mount the iso image by addressing it with (partition)/path
          set iso=/images/Win10_English_x64.iso
          loopback loop ($root)$iso


          # boot (chain-load) the image using the cdboot.efi file located
          # on the win10-image
          chainloader (loop)/efi/microsoft/boot/cdboot.efi
          }


          Instructions:



          Replace XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX with the UUID of the partition, that holds the Windows 10 image.





          insmod part_gpt: This module is needed, if the Win10-ISO-Image lies on a drive with a GPT-partitiontable.



          insmod part_msdos: Choose this one over insmod part_gpt, if the image lies on a drive with DOS-partitiontable.





          insmod ntfs: This module is needed, if the Win10-ISO-Image lies a NTFS-partition.



          insmod ext2: Replace insmod ntfs with insmod ext2, when the image lies on a ext2/ext3 or ext4 partition.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Jan 26 at 18:31









          0fnt

          1,24561734




          1,24561734










          answered Sep 5 '18 at 19:48









          Arch Linux TuxArch Linux Tux

          19315




          19315













          • I have a system that boots in Legacy BIOS mode. I have an iso on an ntfs partition so I chose insmod ntfs and chose insmod part_msdos (and in a separate attempt insmod part_gpt1) but I get error: invalid signature` which my research shows has something to do with UEFI. WHich seems to relate to cdboot.efi. What should I use for legacy bios mode?

            – 0fnt
            Jan 26 at 18:22













          • @0fnt Take a look at: wiki.gentoo.org/wiki/GRUB2/… Try adding insmod chain and replace the last line with chainloader (loop)+1

            – Arch Linux Tux
            Jan 27 at 15:34








          • 1





            superuser.com/users/352691/arch-linux-tux @arch-linux-tux Thanks- I tried it but I had the same error: invalid signature. I even had secure boot disabled. For now I copied ISO contents to a partition and used ntldr /bootmgr but if you do come across a solution- please do mention. Thanks

            – 0fnt
            Jan 28 at 6:16



















          • I have a system that boots in Legacy BIOS mode. I have an iso on an ntfs partition so I chose insmod ntfs and chose insmod part_msdos (and in a separate attempt insmod part_gpt1) but I get error: invalid signature` which my research shows has something to do with UEFI. WHich seems to relate to cdboot.efi. What should I use for legacy bios mode?

            – 0fnt
            Jan 26 at 18:22













          • @0fnt Take a look at: wiki.gentoo.org/wiki/GRUB2/… Try adding insmod chain and replace the last line with chainloader (loop)+1

            – Arch Linux Tux
            Jan 27 at 15:34








          • 1





            superuser.com/users/352691/arch-linux-tux @arch-linux-tux Thanks- I tried it but I had the same error: invalid signature. I even had secure boot disabled. For now I copied ISO contents to a partition and used ntldr /bootmgr but if you do come across a solution- please do mention. Thanks

            – 0fnt
            Jan 28 at 6:16

















          I have a system that boots in Legacy BIOS mode. I have an iso on an ntfs partition so I chose insmod ntfs and chose insmod part_msdos (and in a separate attempt insmod part_gpt1) but I get error: invalid signature` which my research shows has something to do with UEFI. WHich seems to relate to cdboot.efi. What should I use for legacy bios mode?

          – 0fnt
          Jan 26 at 18:22







          I have a system that boots in Legacy BIOS mode. I have an iso on an ntfs partition so I chose insmod ntfs and chose insmod part_msdos (and in a separate attempt insmod part_gpt1) but I get error: invalid signature` which my research shows has something to do with UEFI. WHich seems to relate to cdboot.efi. What should I use for legacy bios mode?

          – 0fnt
          Jan 26 at 18:22















          @0fnt Take a look at: wiki.gentoo.org/wiki/GRUB2/… Try adding insmod chain and replace the last line with chainloader (loop)+1

          – Arch Linux Tux
          Jan 27 at 15:34







          @0fnt Take a look at: wiki.gentoo.org/wiki/GRUB2/… Try adding insmod chain and replace the last line with chainloader (loop)+1

          – Arch Linux Tux
          Jan 27 at 15:34






          1




          1





          superuser.com/users/352691/arch-linux-tux @arch-linux-tux Thanks- I tried it but I had the same error: invalid signature. I even had secure boot disabled. For now I copied ISO contents to a partition and used ntldr /bootmgr but if you do come across a solution- please do mention. Thanks

          – 0fnt
          Jan 28 at 6:16





          superuser.com/users/352691/arch-linux-tux @arch-linux-tux Thanks- I tried it but I had the same error: invalid signature. I even had secure boot disabled. For now I copied ISO contents to a partition and used ntldr /bootmgr but if you do come across a solution- please do mention. Thanks

          – 0fnt
          Jan 28 at 6:16


















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Super User!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1355604%2fboot-win10-from-an-iso-image-on-a-certain-partition-using-grub2%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          flock() on closed filehandle LOCK_FILE at /usr/bin/apt-mirror

          Mangá

           ⁒  ․,‪⁊‑⁙ ⁖, ⁇‒※‌, †,⁖‗‌⁝    ‾‸⁘,‖⁔⁣,⁂‾
”‑,‥–,‬ ,⁀‹⁋‴⁑ ‒ ,‴⁋”‼ ⁨,‷⁔„ ‰′,‐‚ ‥‡‎“‷⁃⁨⁅⁣,⁔
⁇‘⁔⁡⁏⁌⁡‿‶‏⁨ ⁣⁕⁖⁨⁩⁥‽⁀  ‴‬⁜‟ ⁃‣‧⁕‮ …‍⁨‴ ⁩,⁚⁖‫ ,‵ ⁀,‮⁝‣‣ ⁑  ⁂– ․, ‾‽ ‏⁁“⁗‸ ‾… ‹‡⁌⁎‸‘ ‡⁏⁌‪ ‵⁛ ‎⁨ ―⁦⁤⁄⁕