Assuming you can actually format some drive/partition with NTFS on your Ubuntu machine or some other machine, you can extract and copy the content (i.e. files, directories inside) of the Windows ISO to the drive and boot it with grub. It does not matter whether the drive is the same drive where grub is installed on.
On (modern) Windows, you can mount the ISO by simply double clicking it. You should then see it attached as some sort of virtual drive where you can select all, copy and paste the content from the ISO to the NTFS-formatted drive.
On Linux, you can mount it with the mount
command. For example:
mkdir -p /tmp/src/
mount path/to/iso/file /tmp/src/
The command should succeed as long as your distro ships a kernel that has the loop device driver and UDF driver enabled. (Might even work if it has only ISO9660 driver but not the UDF one.)
Then also mount the NTFS formatted drive. For example:
mkdir -p /tmp/dst/
mount /dev/sdXY /tmp/dst/
Again, this requires your distro ships either a kernel with NTFS driver or ntfs-3g, the userspace/FUSE driver, in their package repo. For the latter should be able to install it with your package manager, if it is not installed yet.
If the drive is a USB drive, it might be automatically mounted by your desktop environment (DE) via udisks2. If that's the case, you probably need to find out where it is mounted, instead of mounting it again with mount
. (Often it would be somewhere under /media
or /run/media
. And you might not even need to know where exactly the path is if you can see it in your file manager and are going to perform the file copying with it.)
Then you simply copy the content of the ISO to the drive with e.g.:
cp -rv /tmp/src/* /tmp/dst/
or
rsync -rv /tmp/src/ /tmp/dst/
(Make sure you know that trailing slash matters a lot for the source path if you are going to use rsync
.)
Certainly you can perform the file copying with GUI file manager in the "Windows manner" instead. (But well, GUI file copying has been surprisingly problematic for a long time, like stalling / cannot finish for no reasons even long after the expected flushing time. Maybe things have become better. Maybe not. I have no idea since CLI works perfectly fine for me.)
Then unmount the USB drive and the ISO:
umount /tmp/dst/
umount /tmp/src/
UEFI firmware from many vendors do not have "extra" support for NTFS. AFAIK AMI Aptio is the only implementation that ships its own NTFS DXE driver.
Fortunately, you don't even have to side load that like the Rufus approach does. You can have a grub menu entry that leads you to the Windows installer:
menuentry 'Install Windows' {
search -u 49EA0D032930D9B5 -s
chainloader /efi/boot/bootx64.efi
}
49EA0D032930D9B5
in the example is the volume serial number of the NTFS filesystem (where the content of the ISO have been copy to). It is treated as the filesystem UUID (note: NOT PARTUUID
) in Linux so you should be able to find it out with lsblk -f
or blkid
easily.
IIRC you have to make sure /efi/boot/bootx64.efi
is all in small letter as it is in the ISO/UDF (and because the content is now in an NTFS).
You might find some similar example which ask you to have a bunch of insmod
. In my experience with the grub shiped in Arch Linux, none is necessary. But you can probably have it for part_msdos
, part_gpt
and ntfs
anyway just in case.
(Note that this works only if your have efi grub. If you have bios grub that has been booted through CSM, this won't work. I think you'll get an error from grub in that case. It probably won't just give you a black screen or reset. I don't know for sure though.)
P.S. Since I personally haven't been generating grub.cfg for a long time, I don't have an exact idea where you should put the menu entry so that grub-mkconfig
/ update-grub
will add it to grub.cfg (and hence your grub boot menu). It's probably some file under /etc/grub.d
or so. Do your own research. Also, since you probably need it for a while only, you may even just put it to the end of your grub.cfg (under /boot/grub
).