2. Boot a Linux USB installation in VirtualBox
Summary
TLDRIn this tutorial, Vince demonstrates how to boot a Linux installation from a USB drive within VirtualBox. He explains the process of identifying the USB drive in Windows Disk Management and using command prompts to create a symlink for VirtualBox to locate the USB. The video also covers setting up a virtual machine to boot from the USB and adjusting settings for optimal performance. Finally, Vince shows how to achieve the same with a Linux host, guiding viewers through terminal commands and VirtualBox configurations.
Takeaways
- 😀 The video is a tutorial on booting a Linux installation from a USB drive using VirtualBox, which is useful for updating or accessing files.
- 🔍 It addresses a limitation in VirtualBox that does not allow easy booting from a USB drive and provides a workaround.
- 💾 The process involves identifying the USB drive in Windows Disk Management and noting its disk number.
- 📝 Commands are provided to create a symlink in the command prompt to tell VirtualBox where to find the USB drive.
- 🖥️ Users must run the command prompt and VirtualBox as an administrator for the method to work.
- 🔄 After creating the symlink, the user can set up a new virtual machine in VirtualBox to boot from the USB drive.
- ⚙️ The video also covers adjusting settings such as CPU, memory, and display to ensure proper booting.
- 🔑 A reboot into Linux is mentioned, suggesting the process will be demonstrated for a Linux host as well.
- 📁 In Linux, the tutorial involves identifying the USB drive using terminal commands and creating a file for VirtualBox to recognize.
- 🔄 Similar to Windows, the Linux process includes creating a new virtual machine in VirtualBox and selecting the USB drive file.
- 🎉 The video concludes with successfully booting a Linux distribution from a USB drive in VirtualBox, showcasing the final result.
Q & A
What is the main topic of the video?
-The video is about how to boot back into a Linux installation on a USB drive using VirtualBox.
Why might someone want to boot from a USB drive in VirtualBox?
-One might want to boot from a USB drive in VirtualBox to work with the Linux installation without shutting down their machine and rebooting on their hardware, or to update the installation or transfer files between Windows and Linux.
What is a limitation of VirtualBox when it comes to booting from a USB drive?
-VirtualBox does not easily allow booting from a USB drive, requiring the user to enter specific commands into the command prompt to enable this feature.
What is the first step to identify the USB drive in Windows before proceeding with the VirtualBox setup?
-The first step is to open Disk Management in Windows and identify the USB drive, usually by its size, and note down its disk number.
How do you open a command prompt with administrative privileges in Windows?
-You can open a command prompt with administrative privileges by right-clicking on 'CMD' in the Start menu and selecting 'Run as administrator'.
What command is used in the command prompt to create a symlink for VirtualBox to find the USB drive?
-The specific command used is not provided in the transcript, but it involves changing into the VirtualBox installation directory and pasting a command that includes the disk number of the USB drive at the end, replacing a hash symbol with the disk number.
What settings should be adjusted in the VirtualBox virtual machine to ensure proper booting from the USB drive?
-Settings to adjust include removing the floppy, increasing the number of CPUs to 2, setting the video memory to the maximum of 128 MB, changing the display to Vbox VGA, and enabling 3D acceleration. Also, ensure the USB section is set to USB 3.
How do you determine the location of the USB drive in a Linux system before setting up VirtualBox?
-In Linux, you can determine the location of the USB drive by typing 'sudo fdisk -l' or 'lsblk' in the terminal and identifying the drive by its size or other characteristics.
What command is used in Linux to create a file that helps VirtualBox boot from the USB drive?
-The command used in Linux is not explicitly provided in the transcript, but it involves replacing '/dev/sdX' with the correct drive letter and executing the command to create a file, which is then saved in the home directory.
What are some of the settings that need to be configured in the VirtualBox virtual machine when using a Linux host?
-When using a Linux host, settings to configure include setting the number of processes to 2, changing the USB to USB 3, and using an existing hard disk file that points to the USB drive.
What is the final step shown in the video after setting up the virtual machine in VirtualBox?
-The final step is to start the virtual machine, enter the encryption key if prompted, and log in to successfully boot into the USB drive through VirtualBox.
Outlines
📀 Booting Linux from USB in VirtualBox
In this segment, the presenter, Vince, explains how to boot a Linux installation from a USB drive within VirtualBox. He addresses the common issue of VirtualBox not supporting easy booting from a USB and provides a workaround. The process involves identifying the USB drive in Windows Disk Management, opening a command prompt as an administrator, and entering specific commands to create a symlink that VirtualBox can recognize. This allows the user to boot into the Linux installation on the USB without needing to shut down their machine and reboot from the hardware. The presenter also mentions that the steps will be demonstrated for both Windows and Linux hosts.
🔧 Configuring VirtualBox for USB Booting
This paragraph details the steps to configure VirtualBox for booting from a USB drive. The presenter instructs the user to open VirtualBox as an administrator, create a new virtual machine named 'boot USB', and select the appropriate settings for the operating system type and memory allocation. The key part of the process is to use an existing virtual hard disk file, which is the symlink created earlier pointing to the USB drive. The presenter also covers additional settings adjustments such as CPU allocation, video memory, and enabling 3D acceleration. The goal is to ensure that the virtual machine can successfully boot from the USB drive within VirtualBox.
🔄 Rebooting with Linux as the Host
In the final paragraph, the presenter demonstrates how to achieve the same USB booting process but with a Linux host system. The steps include opening a terminal, identifying the USB drive using commands like 'sudo fdisk -l' and 'lsblk', and creating a file that will inform VirtualBox about the location of the USB drive. The presenter then guides the user through creating a new virtual machine in VirtualBox with similar settings as before, but this time without needing administrator or root privileges. The successful booting of the Linux distribution from the USB drive through VirtualBox concludes the tutorial, and the presenter invites viewers to leave questions, comments, or suggestions.
Mindmap
Keywords
💡VirtualBox
💡Linux
💡USB Drive
💡Disk Management
💡Command Prompt
💡Symlink
💡Virtual Machine
💡Ext4 Filesystem
💡NTFS
💡Linux Host
💡Encryption Key
Highlights
Vince demonstrates how to boot a Linux installation from a USB drive in VirtualBox.
The tutorial explains the process of working with a Linux installation without needing to shut down the machine.
A limitation in VirtualBox is discussed, where booting from a USB drive isn't straightforward.
Instructions are provided for using command prompts to enable USB booting in VirtualBox.
The importance of identifying the correct USB drive in Disk Management is emphasized.
A detailed guide on how to open a command prompt as an administrator is given.
Commands to create a symlink for VirtualBox to find the USB drive are explained.
The process of setting up a new virtual machine in VirtualBox is outlined.
Configuration settings for the virtual machine are discussed to ensure proper booting.
The tutorial covers how to boot into the USB drive through VirtualBox successfully.
Vince shows how to reboot the system into Linux and perform similar steps on a Linux host.
Terminal commands for identifying the USB drive in a Linux system are provided.
The method for creating a file to enable booting from the USB drive on a Linux host is shown.
Instructions for setting up a new virtual machine in VirtualBox on a Linux host are given.
Final steps to successfully boot a Linux distribution from a USB drive on a Linux host are detailed.
The video concludes with a summary of the process and an invitation for viewer interaction.
Transcripts
hi Vince here again in my last video I
showed you guys how to do a full install
of Linux until USB Drive in VirtualBox
this time around I'm going to show you
how you can boot back into that USB
Drive with Linux using VirtualBox as
well now why might you want to do this
well it's say for example you want to
work with that installation you might
want to do some things like update it or
you might want to pull down some files
back onto windows because especially
Windows doesn't really handle any other
file systems very well besides NTFS and
f80 you might want to boot back into
that USB Drive using this VirtualBox if
you don't want to shut down your machine
and reboot back into the USB on your
hardware now there is a limitation in
VirtualBox where it doesn't really allow
you to easily boot from a USB Drive
you'll need to enter some commands into
the command prompt to allow this to
happen the instructions about how to do
this shown in this article here I will
show you how to do this first of all in
Windows and later in the video I'll show
you how to do the same thing in Linux as
a host now scrolling through this
article the first thing you need to do
is open up Disk Management in Windows so
the easiest way to do that is to
right-click on your Start menu and
select Disk Management in here what
you'll need to do is try to identify
which is the USB Drive and that's
usually going to be somewhere down near
the bottom the best way to probably
identify it would be with how big it is
in my case it's 120 gig Drive and you'll
see here two partitions which Windows
doesn't really recognize as anything
except a healthy partition because it
can't really read the ext4 filesystem
in my case it's disk ten
just make note of that in your head
maybe write it down somewhere because
you'll need that in the following steps
returning to the article here the next
thing we need to do is open up a command
prompt we can do that simply by going to
Start menu and typing CMD now it's
important here that you don't just click
on it to open it to what you'll need to
do is right-click it and select run as
administrator next what you'll need to
do is follow these instructions and put
in these commands into your command
prompt first you'll need to change into
the directory where your VirtualBox is
installed
next you'll need to paste this command
in now what you'll need to do is at the
end of this command where there's little
hash symbol is you will need to put in
the number that you saw in your disk
management so in my case it's dis number
10 of your USB Drive so you'll need to
replace the hash with a 10 and simply
hit enter and hopefully you'll get this
message that the disk was created
successfully what this command has done
is created a shortcut file or a symlink
to tell VirtualBox where to find a USB
Drive and in this situation it saved
that file to this C Drive of course you
can then go and find this file and move
it to where you would like to save all
your virtual machines next what we can
do is go ahead and open VirtualBox to do
so when you find VirtualBox in your
Start menu what you'll need to do is to
right-click and choose run as
administrator just like we did with
command prompt earlier otherwise this
method doesn't work now I've already got
VirtualBox I've been here as
administrator we can go ahead and
a new virtual machine will call this
boot USB choose Linux as your operating
system type and in point to 64-bit let's
bump up our ramp to four gigs and in
this section when we have to choose our
hard disk what we already have is a link
file that we created earlier to the USB
Drive so we can actually go ahead and
choose use existing virtual hard disk
file and we click this little icon here
may need to choose add now that
commander around earlier I would have
saved the file to the C Drive and here
it is here we choose open choose and we
can create we need to still adjust a few
settings to make sure this works
properly in the system we can get rid of
the floppy increase to two CPUs display
increase the video memory to the maximum
128 megabytes change the display to V
box VGA and enable 3d acceleration
importantly you'll need to go into the
USB section and choose USB 3 ok let's
start our up
enter in the encryption key that we put
in earlier we can now log in and there
you have it
we have successfully booted into our USB
Drive through VirtualBox next up I'm
going to reboot my system in to Linux
and I'll show you how to do the same
thing with a Linux host running
VirtualBox right so in Linux what you'll
first need to do is open up a terminal
window and next we need to determine
whereabouts in your system the USB Drive
that you what a boot from is that and
you can do this in a couple of ways by
first of all typing sudo if disk - L
entering your password and in my case it
appears that my USB nvme drive is at SD
k another way you can do this is to type
LS p okay and you might be able to
identify your disk again by the size of
your disk it's usually shouldn't be any
disk that's already been used here it
should be a USB Drive that's not
currently being mounted and in this
situation again I can confirm it is SDK
just remember that because we'll need
that in the next step next what we need
to do is use this command don't worry if
it's very long I will copy and paste it
into the description in the video down
below what we need to do is replace at
the NT s DX with the letter that we need
for our drive and then press Enter and
with any luck our file was created
successfully in this case in my home
directory next what we'll do is go ahead
open up VirtualBox in a desktop this
time around you actually don't need to
open as administrator or root you can
just reuse it in your normal VirtualBox
will create a new machine or called boot
USB select Linux as the top of operating
system and again in this case it was
open to 64 bits well pop it up so again
- 4 gigs of RAM and use existing hard
disk file now we may need to find the
file again
there it is in my home directory USB dot
VMDK
choose create we will just quickly sort
out some of these settings pop it up to
two processes change a USB to three that
should do us and go ahead and try and
build it up
and it appears that we have it up and
going again
there you are
we have successfully booted a fully
installed Linux distribution on a USB
Drive through VirtualBox that's all for
today thank you very much again for
watching if you have any questions
comments or suggestions please leave
them down below bye for now
تصفح المزيد من مقاطع الفيديو ذات الصلة
How to Install Windows Server 2019 in VirtualBox (Step By Step Guide)
CARA INSTALL UBUNTU 20.04.1 DI VIRTUALBOX || IT TUTORIAL
How to install Windows 10 on Asus X540 Laptop - Enable USB Boot in Bios Settings
Create VirtualBox Virtual Machine & Install Oracle Linux - Hands-On Experiments for Oracle DBAs
How To Install Windows 10 From USB (2022)
How to Create a Windows 10 Installation USB with Rufus (Tutorial)
5.0 / 5 (0 votes)