Jump to content











Photo
- - - - -

Install Windows 10 from iso with wimboot


Best Answer nierewa , 05 July 2019 - 11:05 AM

Many thanks to you Steve.
I would never have managed that alone.
You are the best of all     :worship:

 

   :yahoo:   :party_time:      :cheers:

Go to the full post


  • Please log in to reply
72 replies to this topic

#26 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 24 June 2019 - 09:49 AM

Hi, there.
First of all, thanks for the help. However, I have one more question on this subject. I hope I am right here.

I use AIO boot, which is very cool I think
But how can I enter the Windows 10 installation for UEFI here? I didn't find the right configuration file for the grub2 menu.

My stick looks like this:
Partition 1: AIO with all AIO-files
Partition 2: the Windows 10 iso with wimboot, startup.bat etc.

As I said legacy works great. I add root (hd0,1) for map \images\Win10_1809_x64.iso
But it doesn't work with UEFI.

Or is there a way to use bootmgr for iso installation?

Thanks again

Translated with www.DeepL.com/Translator



#27 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 24 June 2019 - 10:15 AM

I haven't got around to trying this yet,

 

but the grub2 UEFI menu would be similar to the MBR grub2 menu except it would have

insmod wimboot

to load the wimboot module (you need to copy the two files into the \boot\grub\x86_64-efi and i386-efi folders first).

 

 

then use a wimboot command line as detailed in the description, to run wimboot.

 

see http://reboot.pro/to...ot/#entry211789



#28 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 24 June 2019 - 11:10 AM

 

(you need to copy the two files into the \boot\grub\x86_64-efi and i386-efi folders first)

Which two files do you mean? The wimboot.mod I found in the given link

 

The problem is I don't know how to add an entry to grub2 menu.
With AIOCreator it is easy to edit grub4dos and bcd  menu, but I can't find a way to edit grub 2 menu



#29 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 24 June 2019 - 11:20 AM

Well I suggest you ask the author of AIOBoot.

 

Two files

\boot\grub\x86_64-efi\wimboot.mod

\boot\grub\i386-efi\wimboot.mod



#30 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 27 June 2019 - 10:46 AM

I found it.
Now I can add an entry.

 

Is this the right way

menuentry "WIN10 Install" --unrestricted --class Windows {

    set isoname=win10.iso
    loopback loop /$isoname
    linux16 /wimboot
    initrd16 newc:bcd:(loop)/boot/bcd \
    newc:Win10.iso.tag:(loop)/boot/bcd \
    newc:winpeshl.ini:/winpeshl.ini \
    newc:startup.bat.sdi:/startup.bat \
    newc:boot.sdi:(loop)/boot/boot.sdi \
    newc:boot.wim:(loop)/sources/boot.wim
    drivemap -s hd0 hd1

    boot

)

The stick looks this way

Partition 1: AIO with all AIO-files
Partition 2: the Windows 10 iso with wimboot, startup.bat etc.

 

|- images

      |-win10_1903_x64.iso

|

|- wimboot

      |-wimboot

      |-winpeshl.ini

      |-startup.bat

 

 

So I change the entry to:

menuentry "Windows 10 64bit installieren" {
	set root=(hd0,2)
	set isoname=images/Win10_1903_x64.iso
    loopback loop $isoname
    linux16 /wimboot/wimboot
    initrd16 newc:bcd:(loop)/boot/bcd \
    newc:Win10_1903_x64.iso.tag:(loop)/boot/bcd \
    newc:winpeshl.ini:/wimboot/winpeshl.ini \
    newc:startup.bat.sdi:/wimboot/startup.bat \
    newc:boot.sdi:(loop)/boot/boot.sdi \
    newc:boot.wim:(loop)/sources/boot.wim
    drivemap -s hd0 hd1
    boot
}

The booting results in a screen with black spots an nothing else happens.

 

Can you tell me what's wrong?



#31 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 27 June 2019 - 10:52 AM

It should work for MBR booting. For UEFI booting it is totally wrong though.



#32 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 27 June 2019 - 11:07 AM

I give up. That's to hard for me.

May you tell me how it work with UEFI please :white_flag:



#33 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 27 June 2019 - 12:11 PM

It doesn't! The pre-compiled wimboot.mod module does not work with any standard release of grub2 (only the special build by alive).

The special build by alive downloaded from https://github.com/a...ub2-filemanager only seems to Secure UEFI boot but does not non-Secure UEFI boot (at least in my tests using Z87 PC and VBox).

If you use the Secure-Boot a1ive grub2 then you have to run MokManager to get it to work because it is not signed. MokManager does not run on my Z87 PC or VBox so I can't get grub2 to load.

A1ive says I am welcome to compile my own special version of the wimboot module, but I am reluctant to try to get his/her special version compiling and test it as there are always issues with this sort of problem. If a new wimboot.mod was made, it would only non-Secure UEFI-boot but it could be used with any standard version of grub2 and use by many 1000s of people, but he/she seems unwilling to spend 30 mins of his/her time compiling a version for us.

 

My (untested) menu entry looks like this:

 

  loopback loop /WINDOWS/${filename}
  set pp=
  if test -f (loop)/x64/sources/boot.wim; then set pp=/x64; fi
#  if $MBR32; then
#   if test -f (loop)/x86/sources/boot.wim; then set pp=/x86; fi
#  fi
  insmod wimboot
  wimboot \
  @:startup.bat://wimboot/startup.bat \
  @:winpeshl.ini:/wimboot/winpeshl.ini \
  @:$filename.tag:(loop)${pp}/boot/bcd \
  @:bootmgfw.efi:/wimboot/bootmgfw64.efi \
  @:boot.sdi:(loop)${pp}/boot/boot.sdi \
  @:boot.wim:(loop)${pp}/sources/boot.wim \
  @:bcd:(loop)${pp}/boot/bcd
  #drivemap -s hd0 hd1
  boot

 

 

It is suggested to use a standard Win7 \EFI\BOOT\Bootx64.efi boot file for the bootmgfw.efi boot file - but I haven't got that far in testing.

 

Chinese blog here. YTvideo here.


Edited by steve6375, 27 June 2019 - 01:46 PM.


#34 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 28 June 2019 - 08:10 AM

Nothing happens either.

No error or something else.

 

The entry changed in that way:

menuentry "Windows 10 64bit installieren" {
 set root=(hd0,2)

//the pp is obsolete for me I think, because I only have one version to install
  so I set pp to (loop)/sources

 loopback loop /images/Win10_1903_x64.iso
  insmod wimboot
  wimboot \       --> I don't now if this is right with the constelation I have
  @:startup.bat://wimboot/startup.bat \
  @:winpeshl.ini:/wimboot/winpeshl.ini \
  @:Win10_1903_x64.iso.tag:(loop)/sources/boot/bcd \
  @:bootmgfw.efi:/wimboot/bootmgfw64.efi \
  @:boot.sdi:(loop)/sources/boot/boot.sdi \
  @:boot.wim:(loop)/sources/sources/boot.wim \
  @:bcd:(loop)/sources/boot/bcd
  #drivemap -s hd0 hd1
  boot

Thanks for your help



#35 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 28 June 2019 - 01:21 PM

I have had some success!

I use a Win10 ISO as the source Windows file.

 

Be sure to use the correct version of bootfmx64.efi !!!

 

The order that the files are loaded in is critical! If they are in the wrong order I get a 0xc000000f BSOD!

menuentry "${filenamex} EFI" {
  set isoname="${filename}" ; CHECK_MNU_FOLDER
  loopback loop ${ifp}/WINDOWS/${filename}
  set pp=
  if test -f (loop)/x64/sources/boot.wim; then set pp=/x64; fi
  if $EFI32; then
   if test -f (loop)/x86/sources/boot.wim; then set pp=/x86; fi
  fi
  echo Using ${pp}/sources/boot.wim...

#NOTE: ORDER IS IMPORTANT! May get 0xC000000f error if order is wrong!
  wimboot \
  @:startup.bat:/wimboot/startup.bat \
  @:winpeshl.ini:/wimboot/winpeshl.ini \
  @:$filename.tag:(loop)${pp}/efi/microsoft/boot/bcd \
  @:boot.wim:(loop)${pp}/sources/boot.wim \
  @:bootmgfw.efi:(loop)${pp}/efi/boot/bootx64.efi \
  @:bcd:(loop)${pp}/efi/microsoft/boot/bcd  \
  @:boot.sdi:(loop)${pp}/boot/boot.sdi
  drivemap -s hd0 hd1
  boot

For instance, if the boot.wim is loaded last then you get a BSOD!

 

Attached is a screenshot of the \EFI\BOOT files which are used for UEFI64. Bootx64 is a shim which loads grubx64 which then loads grubfmx64.efi.

 

grubfmx64.efi is some sort if file manager, it allows you to navigate to \boot\grub\grub.cfg and then select 'Grub2' to load your grub.cfg file.

 

Once that is done you can use your own grub2 menu as above.

 

The winpeshl.ini and startup.bat worked and loaded the ISO as a virtual drive so I could choose an Edition and I got through to the Windows Setup 'Where do you want to install Windows' screen so it should now work OK.

 

I have not tried Secure Boot.

 

I do not know how to get rid of the file manager and just get it to run the grub.cfg file yet though....

Attached Thumbnails

  • UEFIWIMBOOT2.JPG
  • UEFIWIMBOOT1.JPG

Edited by steve6375, 04 July 2019 - 09:31 AM.

  • nierewa likes this

#36 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 29 June 2019 - 05:10 AM

Here is a link to download for the files I use in \EFI\BOOT folder  (loads the default \boot\grub\grub.cfg file)

 

https://1drv.ms/u/s!...W-RDHY?e=iK0FnZ

 

bootx64.efi is a stub

grubx64.efi is a loader

grubfmx64.efi is grub2 which will load your \boot\grub\grub.cfg file

 

It is based on A1ive's grub2 build for filemanager.

32-bit UEFI should also work.

Secure Boot is untested.


Edited by steve6375, 29 June 2019 - 05:31 AM.

  • wimb likes this

#37 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 29 June 2019 - 08:17 AM

More info on wimboot and grub2 here with updated grub2 files.

Note that you must keep the filename of the ISO short!

Edited by steve6375, 29 June 2019 - 08:36 AM.

  • wimb likes this

#38 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 29 June 2019 - 09:55 AM

First of all, many Thanks Steve.
I'll give many tries :D :D



#39 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 29 June 2019 - 01:38 PM

I have updated Tutorial 145 again.

There was a problem when using more than one .iso file in the same folder. If you are not using the E2B grub2 menu you might not have the issue anyway.

Also, I have improved the passing of the name and path of the ISO by using a null.cfg file (which is now added to the \wimboot folder). It uses save_env to write a variable value to a file on the USB drive using

save_env -f /wimboot/null.cfg installiso

This is picked up later by startup.bat (save_env is one of the few commands that actually writes to a disk - the file must exist however and be a special size).

 

UEFI booting seems to work well now.

 

Unfortunately, for some strange reason, I cannot now MBR boot using \wimboot\wimboot. I have tried old images as well as new and they all hang after loading bootmgr. It is really annoying as it was working before and I have no idea what has caused it to no longer work as the grub2 legacy files have not changed and the wimboot file has not changed!

 

Anyway, hopefully you will be able to get the UEFI working.

 

If you have got the MBR wimboot working, please let me know. Perhaps I changed something subtle and broke it. Wimboot seems very sensitive to boot order, file name lengths, etc.!

 

P.S. Just got MBR + wimboot to work on an HP laptop using exactly the same USB drive (but it hung the first 3 times!) so it doesn't seem to like my Z87 or VBox for some reason (maybe memory map issues?).



#40 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 30 June 2019 - 09:15 AM

update: my problems with MBR wimboot booting no longer working seems to be due to the late addition of the 

drivemap -s hd0 hd1

line into the menu.

 

I think I added this because the boot code was being installed onto the USB drive instead of the internal hard disk.

 

When test under VBox (where USB drive = 0 and virtual HDD=1) this seems to prevent bootmgr from booting but it is OK on a real system or if I remove the line then it boots under VBox OK.

 



#41 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 30 June 2019 - 03:34 PM

P.S. Tutorial 145 files have been updated again!



#42 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 01 July 2019 - 10:57 AM

I changed the menuentry to:

menuentry "${filenamex} EFI" {
  loopback loop (hd0,msdos2)/images/Win10_1903_x64.iso

  echo Using /sources/boot.wim...

#NOTE: ORDER IS IMPORTANT! May get 0xC000000f error if order is wrong!
  wimboot (hd0,2)/wimboot/wimboot
  @:startup.bat://wimboot/startup.bat \
  @:winpeshl.ini:/wimboot/winpeshl.ini \
  @:Win10_1903_x64.iso.tag:(loop)/efi/microsoft/boot/bcd \
  @:boot.wim:(loop)/sources/boot.wim \
  @:bootmgfw.efi:(loop)/efi/boot/bootx64.efi \
  @:bcd:(loop)/efi/microsoft/boot/bcd  \
  @:boot.sdi:(loop)/boot/boot.sdi
  drivemap -s hd0 hd1
  boot
 }

The  pp= Entry I don't need, because I've got two images. One for x86 and one for x64.
There is no folderstructur with x64 or x86 in it.

 

Booting results in:

load (hd0,2)/wimboot/wimboot...Please wait...

Nothing happens.
I think the problem I have are the two partitions.

 

Partition 1: AIO with all AIO-files
Partition 2: the Windows 10 iso with wimboot, startup.bat etc.

 

|- images

      |-win10_1903_x64.iso

      |-win10_1903_x86.iso

|

|- wimboot

      |-wimboot

      |-winpeshl.ini

      |-startup.bat

 

Don't know how to fit the entry to this.
 



#43 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 01 July 2019 - 11:20 AM

use

FOR MBR wimboot (hd0,2)/wimboot/wimboot pause

FOR UEFI  wimboot --pause \

to see any errors in wimboot

 

drivemap -s hd0 hd1   doesnt work so delete it

 

use ls to see drive names (mine was (hd0,msdos1) (hd0,msdos2) etc.)

 

keep length of the iso filename short - e.g.  Win10.iso

 

There is  a new version which allows longer names - see my tutorial for latest download.

 

if problems , try commenting out the  bootmgfw.efi line - wimboot should find it

 

latest version does not use a .tag file - I use a null.cfg file and new startup.bat - see latest download for files.


Edited by steve6375, 04 July 2019 - 09:14 AM.


#44 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 04 July 2019 - 09:03 AM

After many tests and things to try out, it doesn't work :(

 

If downloaded GRUB2_WIMBOOT file and GRUB2_WIMBOOT_EFI_BOOT_FILES.
I extract the GRUB2_WIMBOOT_EFI_BOOT_FILES to wimboot folder on second partition.
The GRUB2_WIMBOOT files also to the wimboot folder. wimboot file is date 18.05.2017

 

I made a folder _ISO\MAINMENU\WINDOWS where I put the isos in (win10_1903_x64.iso and win10_1903_x32.iso)

 

The menu entry for e.g. 64bit is:

menuentry "${filenamex} EFI" {
  loopback loop (hd0,msdos2)/images/Win10_1903_x64.iso

  echo Using /sources/boot.wim...

#NOTE: ORDER IS IMPORTANT! May get 0xC000000f error if order is wrong!
  wimboot (hd0,2)/wimboot/wimboot --pause
  @:startup.bat://wimboot/startup.bat \
  @:winpeshl.ini:/wimboot/winpeshl.ini \
  @:Win10_1903_x64.iso.tag:(loop)/efi/microsoft/boot/bcd \
  @:boot.wim:(loop)/sources/boot.wim \
  @:bootmgfw.efi:(loop)/efi/boot/bootx64.efi \
  @:bcd:(loop)/efi/microsoft/boot/bcd  \
  @:boot.sdi:(loop)/boot/boot.sdi
  boot
 }

Nothing happens. In VirtualBox the message appears "load (hd0,2)/wimboot/wimboot...Please wait..."

On real PC it shows a screen with black dots an then restarts.



#45 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 04 July 2019 - 09:09 AM

Your menu is wrong!  (sorry didnt notice this before - my menu is in post #35 and was correct!)

wimboot (hd0,2)/wimboot/wimboot --pause

\wimboot\wimboot is the Legacy\MBR program - we dont use this for UEFI.

 

For UEFI, the grub2 wimboot module is used and the parameters are passed to it on the command line.

 

it should be

wimboot --pause \

no path is needed because we use the UEFI grub2 module which is already loaded.


Edited by steve6375, 04 July 2019 - 09:17 AM.


#46 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 04 July 2019 - 09:25 AM

Ah, I see...
Same problem, well, not quite.

 

Now you can see

Load --pause... Please wait



#47 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 04 July 2019 - 09:26 AM

Can you show your menu ...

Compare it with mine in post #35

 

did you forget the \ at the end of the line?



#48 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 04 July 2019 - 09:30 AM

also, you said the ISO file is in \_ISO\MAINMENU\Windows, but you have

loopback loop (hd0,msdos2)/images/Win10_1903_x64.iso

???



#49 nierewa

nierewa

    Frequent Member

  • Advanced user
  • 107 posts
  •  
    Germany

Posted 04 July 2019 - 09:39 AM

I have to change the iso location to /images of second partition.
With _ISO/MAINMENU/WINDOWS the legacy Installation doesn't work anymore.

 

So the menu looks like this:

menuentry "Install Windows 10 x64" {
  loopback loop (hd0,msdos2)/images/Win10_1903_x64.iso

  echo Using /sources/boot.wim...

#NOTE: ORDER IS IMPORTANT! May get 0xC000000f error if order is wrong!
  wimboot --pause \
  @:startup.bat://wimboot/startup.bat \
  @:winpeshl.ini:/wimboot/winpeshl.ini \
  @:Win10_1903_x64.iso.tag:(loop)/efi/microsoft/boot/bcd \
  @:boot.wim:(loop)/sources/boot.wim \
  @:bootmgfw.efi:(loop)/efi/boot/bootx64.efi \
  @:bcd:(loop)/efi/microsoft/boot/bcd  \
  @:boot.sdi:(loop)/boot/boot.sdi
  boot
 }


#50 steve6375

steve6375

    Platinum Member

  • Developer
  • 7566 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 04 July 2019 - 09:53 AM

You must UEFI-boot. It wont work if you MBR boot.

 

try adding read lines...

 

press ENTER to continue with next command.

menuentry "Install Windows 10 x64" {
  loopback loop (hd0,msdos2)/images/Win10_1903_x64.iso

read

  echo Using /sources/boot.wim...

read
#NOTE: ORDER IS IMPORTANT! May get 0xC000000f error if order is wrong!
  wimboot --pause \
  @:startup.bat://wimboot/startup.bat \
  @:winpeshl.ini:/wimboot/winpeshl.ini \
  @:Win10_1903_x64.iso.tag:(loop)/efi/microsoft/boot/bcd \
  @:boot.wim:(loop)/sources/boot.wim \
  @:bootmgfw.efi:(loop)/efi/boot/bootx64.efi \
  @:bcd:(loop)/efi/microsoft/boot/bcd  \
  @:boot.sdi:(loop)/boot/boot.sdi
  boot
}





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users