1

I'm trying to make a USB Windows 8.1 bootable from a Windows 8.1 ISO file. My problem is that I don't have any OS on my PC, I just have a live-usb Ubuntu. And it is the problem, every tutorial, everything I tried requires to install a program (such as grub, unetbootin, mkusb, WinUSB, WieUSB etc...) : 1) Here, it is not the same problem, because he's not in a Live-USB Ubuntu How can I create a Windows bootable USB stick using Ubuntu?

2) I tried the dd method, but it doesn't work. This guy tried it and has the same problem How can I create a Windows 10 boot usb from ubuntu?

3) That tutorial is well detailed, but there is a problem, I don't know whether I have to use GTP or DOS partition table, it is unclear and everyone seems not to be sure about what is right https://onetransistor.blogspot.ch/2014/09/make-bootable-windows-usb-from-ubuntu.html

4) I want a EFI boot because I'm sure that the BIOS could not work with my computer. My ISO take in account the EFI because there is a directory called EFI.

5) I don't have any Windows machine to use Rufus or WIN32.

6) I CAN'T install program, because I'm in a live USB mode, anyway, I've tried to install (for using the programs that must be installed) Ubuntu on my SSD but at the end, it tells me that there is a problem with GRUB (my Ubuntu boot is in EFI mode), and I think that I can't install grub because I'm in a liveUSB...

I think that my only hope is mkusb-nox, which is a command-line tool, but I need to install it too if I have understood?? How can I use it without installing. Is there any solutions to my problem?

I'm sure that I have read everything possible but the problem is really that I can't install in /root a program, because I'm in a LiveUSB mode. I'm really lost and out of solutions.

PS : I've tried the solution consisting in formatting the USB in NTFS, put the "boot" flag and copy (using cp -r /mountpoint/* USBKEY) but it doesn't work, I really don't understand why. Do I need to install Grub on the USBkey? If yes,how can I do it knowing that grub can't be installed because of the live mode.

Sorry for the long message but I try to give everything to you. As you have understood, it is my non-persistent live USB that is really the problem

thanks a lot for your help!

J. PS : My goal is to install Windows on that computer, not making a dual boot. PS2 : I use Ubuntu 16.04 live USB

muru
  • 197,895
  • 55
  • 485
  • 740
  • I have an error when I tried that. I do :
    1. audo apt update (after adding the repo)
    2. sudo apt-get install WinUSB (I have added the repo before)
    3. I get an error : package WinUSB is not available, but is referred by an another package,unable to correct problem , you have held brken packages.

    Every time I tried to install a program I get that, even form official repository. What did I do false?

    – polo16v190 Jan 10 '18 at 08:36
  • 2
    This is the only method that works with the new ISOs Microosft has been releasing (and it explains why): https://help.ubuntu.com/community/mkusb#Windows_USB_install_drive –  Jan 10 '18 at 09:02
  • Si if I understand, I need to install mkUSB on my live USB to get my USB Windows bootable and usable? – polo16v190 Jan 10 '18 at 09:05
  • 1
    If you want to it in Ubuntu, installed or live, now you must use MKUSB. If you have access to a Windows PC (7 or newer) you can use the Microsoft's official tool for that. –  Jan 10 '18 at 09:12

3 Answers3

1

In your question you wrote:

6) I CAN'T install program, because I'm in a live USB mode, anyway, I've tried to install (for using the programs that must be installed) Ubuntu on my SSD but at the end, it tells me that there is a problem with GRUB (my Ubuntu boot is in EFI mode), and I think that I can't install grub because I'm in a liveUSB...

Fortunately things are better than what you thought. It is possible to install a program in a live system, and it can be used.

The installed program will survive as long as the live system is running. If you shutdown or reboot the live system, the installed program will be gone (but can be installed again). In other words, this is a useful option, if you intend to do something once. So it is possible to install mkusb or some other tool and use it to create a USB install drive for Windows 8.1.

There is also an alternative, that should work without installing anything.

See the following link to a 'Do It Yourself' method,

https://help.ubuntu.com/community/Installation/iso2usb/diy

If there are problems with this 'diy' method, mkusb could still work, due to the copying method via a tarball, as described by @MichaelBay in a comment and at this link.

sudodus
  • 46,324
  • 5
  • 88
  • 152
1

First, thanks to all. I have done many things to try it to run. I've tried to install mkusb and it worked. I was sur that it was not possible because I've tried earlier to install woeUSB and WinUSB, but that packages are not maintened anymore or maybe I use the wrong repo.

Anyway, it worked and I could boot on my USBkey without problem, install Windows and configure it as I wanted. I tried to make it manually (extract iso in a tarfile and extract it to USB key) and it worked too! Now I will make a Dual Boot with Ubuntu to be fully operational or Archlinux like my rpi.

Thanks to all for your help! PS : Ubuntu 16.04 seems to have problem to connect to wifi, I didn't get any problem with Ubuntu 12.04. If you need Wifi, use 12.04 edition instead of 16

  • Congratulations and thanks for sharing your solutions :-) Please ask a new question for the wifi problem. – sudodus Jan 11 '18 at 07:45
0

I suggest you try the dd command.

  1. start your computer with the live-usb ubuntu.

  2. copy the windows iso to the home directory in ubuntu os.

  3. link another u drive to the computer.

  4. use the dd command. sudo dd if=windows.iso of=/dev/sdb

hope that will work.

  • I've tried but it doesn't work. I've done that :
    1. start computer
    2. mount Hard disk containing the iso image
    3. Mount USB
    4. sudo dd if=windows.iso of /dev/sdc (which was the USBkey)
    5. My computer doesn't want to go in Windows installer.

    Is it possible to install a packet in the liveUbuntu non persistent configuration? Everytime I tried I get that : Package WinUSB is not available, but is referred by an another package,unable to correct problem , you have held brken packages

    Do I have to put the "boot" flag on the USB written by dd?

    – polo16v190 Jan 10 '18 at 08:45
  • 1
    https://help.ubuntu.com/community/mkusb#Windows_USB_install_drive Quoting: It was not possible to extract the content from the Windows iso file directly to a USB pendrive. The files were not copied correctly (with any of the standard copying tools: cp, rsync, dd) in Ubuntu 16.04.1 LTS (the current Ubuntu version, when this feature was added to mkusb-nox). But it works in a reliable way to extract to a tarfile, and then extract from the tarfile to the USB pendrive. –  Jan 10 '18 at 09:04
  • Ok thanks if the installation of MKUSB doesn't work, I will use that method with the tarefil. Keep in touch if smething work tonight. Thanks a lot! – polo16v190 Jan 10 '18 at 09:26
  • mkusb uses the method with a tarfile ;-) – sudodus Jan 10 '18 at 09:30
  • Ok so I need to extract my iso to a tarfile and then extract the tarfile to my USB. Do I need to make a last operation ? I see in th image that mkusb do an operation with bootloader. Do I have to do that ? (I think that tI have to put the flag boot too to my USB) https://help.ubuntu.com/community/mkusb/v7#Making_a_USB_drive_to_install_Windows Sorry to ask it to you but it is just to be very precise and and trying every possibilities – polo16v190 Jan 10 '18 at 10:03
  • mkusb does it automatically, you need not do it manually. But you must have a drive with enough free drive space for the tarfile (5 GB is enough). This can be a partition in any drive, internal or external. – sudodus Jan 10 '18 at 10:07
  • @sudodus Ok for the automatic version, but if I can't install mkusb for any reasons, and I want to extract the iso in a tar file what are the commands? 1) mount iso in a folder (example : folder_of_the_iso) 2) cp -r folder_of_the_iso/* iso.tar ? Is it sufficiant? – polo16v190 Jan 10 '18 at 14:22
  • Have you got two USB pendrives? In that case, when booted from whatever system, you can download and install a system with mkusb into a USB pendrive (directly from an iso file or image file). The size of the 'second pendrive' will make a difference; there are more options, if the size is 8 GB and even more if 16 GB. So please tell me if you have a second USB pendrive, and in that case what size it is. That way you need not do the tarfile thing manually. – sudodus Jan 10 '18 at 15:47
  • 1
    The commands how to write to a tarfile and from a tarfile are available in clear text in the shellscripts of mkusb. You can download them and use them manually, but it is much more complicated compared to using mkusb as a tool without bothering about the details. See the following link, where you find the files mkusb-nox and dus-live (with two versions of these commands), http://phillw.net/isos/linux-tools/mkusb/ – sudodus Jan 10 '18 at 16:01