Multi-boot Full Install to a USB

Jarret B

Active Member
Staff member
Sometimes you may need a ‘Fix Stick’ to repair to test a system. But what if there is a mix of Distros you deal with? For instance, some systems are Ubuntu based and others are Red Hat. You may want to have specific programs for each type. What if Windows is thrown into the mix? Maybe you have Windows diagnostic programs which do not work under WINE. Now what should you do?
Well, we can make a dual boot or multi-boot USB stick to manage these troubles.
We can accomplish what is seen in Figure 1 on a USB Stick.

Figure 01.jpg

FIGURE 1

NOTE:
I definitely suggest a USB stick that is 64 GB or more to do this (for dual-boot) and 128 GB or more for a multi-boot stick. A 32 GB stick is passable for dual-booting, but barely because of speed issues. As a USB Stick becomes full it slows down. Part of the empty space is used for caching. With prices dropping a 128+ GB stick would be preferable for a multi-boot stick (three or more Operating Systems). For my installation in this article I used a 128 GB USB 3.0 stick rated at over 100 Mb/s even though I have USB 2.0 ports.

Pre-installation Planning

To start we need to know how the space will be used. I planned for the partitions to be equal in size, but you may require more space for one distro over another because of special programs to be installed.
The USB stick is listed as being 128 GB. In reality is only 114 GB total space. The following is how it will be split up:

Windows 10 33 GB
Ubuntu 19.04 33 GB
Fedora 30 33 GB
Swap 2 GB
Unused 13 GB

You may be thinking that 13 GB is a lot of unused space. When I performed an install and used every bit of space I noticed that the installation slowed down immensely. If I left unused space then everything ran at a nice speed.
The partition sizes can be divided differently as you need. I do suggest that once the Operating Systems are in place that you do not adjust the sizes especially Windows.

Installing Windows

If you need to have windows as one of your Operating Systems then it MUST be installed first (very critical). If Windows is not installed first then anything you previously installed will be erased.
The first thing to do is to install a program called “Hasleo WinToUSB Free” and it can be downloaded at https://www.easyuefi.com/wintousb/index.html. The program must be run from a Windows system. Once you have created a USB stick with Windows on it you can use that stick to create more. You can also create an ISO image from the USB stick and simply restore it to other USB sticks.

NOTE: A setting may be required to be added to the ‘WinToUSB.ini’ file. It may not hurt to add it before you begin. After installation simply go to ‘\Program Files\Hasleo\WinToUSB\bin\’ on the installation target drive. Change the permissions for ‘Users’ to ‘Full Access’ for the file ‘WinToUSB.ini’. Edit the file and add the line ‘StorageLegacyMode=1’ to the ‘Settings’ section at the beginning of the file. Save and exit from the editor.

Other than the Hasleo program you will also need a Windows ISO installation file. These can be found throughout the Internet. You can use Windows 7, 8 or 10 in either 32 or 64-bit editions. Do not worry about looking for Home, Pro or other editions. The Hasleo program can create them all from the ISO (in most cases). I suggest you install the Starter Edition so it does not require such a larger overhead on the hardware as the Pro Edition would. The Starter Edition uses less resources and will run faster.
After you have Hasleo installed and the ISO file available you can start Hasleo. Once started you will be asked for the ISO image and given a choice as to which Edition should be installed as shown in Figure 2.

Figure 02.JPG

FIGURE 2

The next screen will ask you to select the USB Stick to install Windows. Once selected you will be asked to make the USB stick MBR, UEFI or both as shown in Figure 3. The screen is only present on some versions of Windows. Unless you buy the professional version you cannot select both. I selected MBR and then clicked ‘Yes’.

Figure 03.JPG

FIGURE 3

The next process is that the USB stick will be formatted and the partition created. The whole drive is used and this is why Windows must be installed first. Do not worry that the whole partition is being used, we will adjust it later.
After the drive is partitioned and formatted we will be allowed to select the Installation Mode. This is an imperative step. Select ‘Legacy’ mode. The ‘VHD’ and ‘VHDX’ Modes keep the OS in a read-only mode so you cannot update the OS. If your USB stick is not compatible, then you may have to try a different one.

NOTE: The fix mentioned above should allow the Legacy option to always be available for selection.

The next step is for the files to be copied to the USB stick. This process may take quite a while. On some USB sticks it has taken an hour or more. Wait for the screen to display the process is 100% done and you can close the program as well remove the USB stick.
To cut down on the lengthy process of creating the Windows To Go (WTG) USB stick you can make a backup of the stick for use later to be restored to another USB stick.
Now you have a Windows system ready for initial setup to be completed once it is started, but first we need to make adjustments.

NOTE: Do NOT boot from the USB stick yet. Make the following adjustments first.

On a Linux system (everything else will be done from Linux now) you need to start GParted with the USB stick inserted.
Once GParted is opened you need to select the proper drive which should be labeled as ‘WinToUSB’. Right-click on it an select ‘Unmount’. After the partition is unmounted you can right-click on it again and select ‘Resize/Move’. You should see a window similar to Figure 4.

Figure 04.jpg

FIGURE 4

In the ‘New Size’ box enter the amount of space you want to allocate for the Windows partition. Remember that the value must be multiplied by 1024. For example, to have 33 GB you would take 33 * 1024 for a total of 33792. Hit the TAB key and all of the values should change to match the value you entered. Keep the ‘Free Space Preceding’ at 0 so the Windows partition remains at the beginning of the USB Stick. Once the changes have been made then you can click on the ‘Resize/Move’ button so the partition will be modified to the new settings. The process may take a while. Do not make the partition too small or the Windows system cannot grow after you perform the initial setup as well as adding any software you may need.
Once the ‘WinToUSB’ partition has been resized then you are ready to install a Linux partition.

NOTE: Do not install all of your Operating Systems before you perform the Windows Setup. If anything should fail you may have to redo the Windows installation. Make sure you resize the Windows partition before you perform the Windows Setup process. If you need to create a ‘WinToUSB’ partition on another USB Stick then you can use this USB Stick to do so. Put Hasleo on the Windows stick after you booted from it and have performed the Setup process. Have access to the Windows ISO file and perform the installation to a blank USB Stick.

Installing Linux

Now that Windows is ready to go you can install your first Linux OS. If you are going to install a second or even a third OS then the process will be the same as installing the first Linux distro.
The steps are similar to those from the article ‘Linux Full Install to a USB Stick’ (https://www.linux.org/threads/linux-full-install-to-usb-stick.20921/).
The difference will be that you will select to install Linux with Windows so you do not overwrite Windows. Create a drive to mount as Root (/) and a drive to mount as Swap. The Root should be what you need it to be, I chose 33 GB or 33792 MB. The swap file is 2 GB or 2048 MB. Allow the install to proceed as normal once the settings have been made.
After the installation you should close the VirtualBox machine and start another for the next distro if you wish to install another. If the USB stick has room for more then add another if you wish. Each Linux distro will add another option to GRUB.
If you install a Red Hat distro or Kali you will need to edit Grub which is located on the second partition. The FSTAB entry will be on the partition where Red Hat or Kali was installed. The instructions for this edit is found on the article mentioned above.

Booting the USB Stick

Restart your computer and choose the appropriate key to press to allow you to choose the USB stick to be the boot device. Once it starts loading you should see something similar to Figure 1. Choose the OS you wish to boot (be sure to fix any Red Hat systems or Kali before you boot them). When you choose Windows you will have to go through a simple setup process. After Windows has started you can perform a Windows Update (since you used the Legacy option when creating it). You will notice too that some Windows versions will mess up the time at every start. You can fix this by running Regedit from the box ‘Ask me anything’. Once started you can add the following entry:

‘HKEY_Local_Machine\system\CurrentControlSet\Control\Timezone Infromation’

Right-click and select ‘New’ then ‘DWORD(32-bit)-Hex’. The name should be ‘RealTimeIsUniversal’ with a value of ‘00000001’. After a reboot the system time should work better.

NOTE: If you plan on using 32-bit system then you will want to use 32-bit versions of Windows and Linux.

You should now have a fully functional multi-boot USB stick.
 
Last edited:

Staff online

Members online


Latest posts

Top