- [Instructor] Virtualization basics.
What is the purpose of a virtual machine or a VM?
The purpose is to run another operating system
or an application internally on a hosting platform.
So you might have a regular PC computer
and that might be running Windows 8.1 or Windows 10
or what have you.
But inside of that, you could run the virtual machine,
a separate operating system that is stored
as a file as a virtual machine on the computer
on the hosting computer.
And these virtual machines are known as guests.
You might have wished in the past
that you had a couple extra computers lying around
so that you could run additional versions of Windows
and run Linux, and maybe a Windows server
with virtual software, with virtualization
and virtual workstations, you can do this
and you do this with Virtual Machine Manager software,
such as Hyper-V or VirtualBox or VMware.
And remember the two types you've got the type one
which is native.
And that means that the hypervisor
or the Virtual Machine Manager runs directly
on the host computers hardware.
That's also known as bare metal and you've got type two.
That type two hypervisor
or Virtual Machine Manager is one that runs
inside of the operating system.
And so guests run within that hypervisor instead of
directly on the bare metal directly on the hardware.
So type two is not gonna be as quick
but it'll usually be cheaper if not free
and a little bit if an easier solution.
But if you're in a high tech situation
you wanna go with the type one.
Resource requirements.
You have to make sure
that the system that will host
the Virtual Machine Manager software
has the right virtualization extensions.
So you need to make sure that you have
the extensions for the CPU
and for Intel that's VT-x and for AMD CPUs, that's AMD-V.
Those need to be enabled in the firmware
within your BIOS or UFI and most new UFI systems have this.
Also, you have virtualization extensions for the chip set.
For Intel that's VT-d
and VT-c.
VT-d is for input output memory management
and VT-c is for network virtualization.
And on the AMD side for the chip set
you have the AMD-Vi extension.
So you wanna make sure that those are
enabled in the firmware.
Now different machine managers will have
different requirements.
And this also depends on the amount of hosts
that you'll be supporting within that software.
If you look here, I have an older system
from Microsoft Virtual Machine Manager 2007
and this shows what types of requirements you need
if you have five to 10 hosts, or if you have 11 to 20 hosts
and you can see the recommended processor is about the same
but the RAM goes up and the hard drive space goes up.
Now newer systems will need even more.
Hyper-V recommends that you have even more memory available
per guest operating system.
If we take a look at Windows 10 Hyper-V
we'll see that you can easily find out
if you meet the Hyper-V requirements
by typing systeminfo.exe
and we'll do that later in the lesson.
And you can see here, the VM monitor mode extensions,
the firmware needs to be enabled,
the second level address translation,
and DEP or data execution prevention.
All these have to say yes for you to run Hyper-V.
So you wanna check that before you actually do that
on a Windows 8.1 or 10 system.
So different requirements, depending on the amount of hosts
and it's different based on which program you use.
A type two hypervisor or a type two VMM
such as VirtualBox won't have as much
as far as resource requirements
as say Hyper-V for Windows server 2012.
Then there's the network requirements.
And you need to make sure that your
Virtual Machine Manager can work with your network card,
your network adapter on your system
because not all network adapters are compliant
with virtualization software.
So you wanna make sure the virtual network adapter
is compatible with your VMM.
And then as a kind of, as a general rule of thumb
you wanna make sure that you have 20 megabits per second
per virtual machine, as a bare minimum
for that connectivity through the network.
Because you can throttle this
by the virtual machine, if you need to.
And you want to have more than that
if high data transfer or multimedia is involved.
But generally I like to go with 20 megabits per second,
as connectivity for one particular guy
as just a basic connection.
Now, if you're gonna be transferring video or what have you,
that number's gonna get a lot higher.
So you're gonna want to check this on your systems
and verify that you have the amount of bandwidth
that you need 20 megabits per second, per VM
as a bare minimum.
And then also you can calculate the typical amount of data
that will be transferred.
You might have a server system
or a powerful Linux system running as a virtual machine
or you might have a
separate Windows 10 system running as virtual machine
that has to constantly move data back and forth.
And you wanna think about how long it takes
to move that data.
For example, if you have 10 gigabytes of data
that will take approximately two minutes
on a one gigabyte per second network
if the entire channel is available
but if you have other guest operating systems
then you wanna make sure that you're calculating properly.
You're gonna have to divvy up the total bandwidth,
the total network throughput
amongst the different guest operating systems
and the hosts that are using that system.
The physical hosts that are using that system.
So you wanna think about those network requirements.
And if we go over here to VMware, VMware has a page
where you can calculate the bandwidth requirements
for vSphere and for other types of
virtual machines that you might use with them.
And it really gets into depth with that.
And so you wanna take into account your link speed.
You wanna take into account
what type of hardware you're using, how many hosts there are
on the physical side and on the virtual side
and put that all together to think about, okay
what are our network requirements?
Do we need a new switch?
Do we need a new router to control all these
virtual machines that'll be sending data?
How much data will the virtual machines be sending?
And finally for the hosting computer or computers
that are running the Virtual Machine Manager software again
make sure the virtual network adapter is compatible
with that software.
Next is security requirements.
The security of the virtual machine should be similar
to the physical host security.
So the actual PC or server that you have
the physical box is gonna have a certain level of security.
You wanna make sure that that device is secure
but also the security
of the virtual machines running inside of that guy
they should be similar to that security
or equivalent to that physical machine's operating system.
The virtual machine should be updated to the latest patches,
the latest service pack, whatever version of Windows it is,
the latest updates.
If you have multiple virtual machines
especially ones that are going to interact with each other
you make sure that they're updated in the same manner.
They should be at the same point release
of the operating system or the same service pack.
And that ensures patch compatibility
between the virtual machines.
The virtual machine should have the latest
antivirus definitions.
Perhaps it should have a firewall enabled.
It should have strong passwords.
All of the security that you would do
with the regular physical host.
And we'll be talking more about security
as we move on through the course.
But there are a lot of other things to watch for
that if not addressed could really cause problems
with your virtual machines and even your hosting computer.
So first you wanna make sure you update that
virtual machine software.
If you're running VirtualBox or if you're running Hyper-V
or you're running VMware
you wanna make sure that guy is updated
because that's gonna patch some security holes
and have it perform better
with the latest OS within the virtual system.
Configure any applicable security settings
and options within that virtual machine software as well.
Watch out for network shares within the virtual machine.
You might have network shares between the virtual machine
and the physical computer or between two virtual machines.
And by default malicious software and attacks
cannot travel between one virtual machine and another.
But if you create a network share between the two malware
and attacks could easily go from one system to the other.
So you have to be careful with network shares.
If a network share is needed, map it
then use it and then disconnect it when you're finished
and document where those network shares are.
If you're done with it you should just disconnect it
or better yet when you set up the mapped network drive
in Windows you'll see that option reconnect at logon
and just go ahead and deselect that this way
when you log off and log back on
or restart the virtual machine
that mapped network drive will be gone.
So watch out for a mapped network drives.
Disable any unnecessary hardware
and you could do this from within the virtual machine.
Optical drives USB ports.
If there's any type of removable media
that you need to use enable the device,
make use of it, and then disable it immediately afterwards.
Now you can disable these devices within the OS,
the virtual OS, say within the device manager
but quite often, devices can also be disabled
within the Virtual Machine Manager software as well.
And if you have a virtual BIOS
or UFI check the boot priority
and make sure that it sets a hard drive first
just like you would with a physical computer.
Limit the resources a virtual machine can use.
A compromised virtual machine can be a threat
in the form of a denial of service attack.
But if you limit the amount of resources
especially on the network side of things
you could eliminate that possibility.
And you want to throttle this network activity.
To mitigate this you could just set a limit
on the amount of resources
any particular virtual machine can utilize.
The better the hypervisor,
the better the Virtual Machine Manager
the more power you'll have with this.
So if you're using Hyper-V or VMware
you can easily throttle this.
Also periodically monitor the usage of the virtual machine.
But you wanna be careful with monitoring.
Enable it only for authorized users, admins,
and disable the monitoring whenever it's not necessary.
Next protect the raw virtual machine files.
The virtual machine is just one big file.
It's almost, you could consider an image,
a file on the hard drive.
So you wanna protect that raw virtual disc file
because if something was to go wrong with that file
the whole virtual machine is gone.
So look into setting permissions
for who can access the folder where the VM files are stored.
And if your virtual machine software supports logging
or auditing, consider implementing that
and see exactly who
started or stopped the virtual machine and when.
Otherwise in Windows
you can audit the folder where the VM files are located.
And finally, you can make a copy
of the virtual machine file.
You know, every once in a while, you should back it up,
make a snapshot of that guy.
You can also encrypt the disc file and digitally sign it
and validate that signature prior to usage.
And last comment protect the hosting computer as well.
The virtual machine should be as secure as possible
but it's only as secure as the hosting computer
that's in the controlling position
the computer that's running the VMM software.
So harden that computer
and then harden the virtual machines in a similar manner.
Let's show a quick example of a virtualization program.
This is Oracle VirtualBox
and this is the VirtualBox manager.
This is the Virtual Machine Manager software.
This is a type two hypervisor.
It runs within the operating system.
It's not bare bones, but it's good for my purposes
for training and it's good for testing.
So this works pretty well,
but if you're gonna have systems in production,
then you want to have a type one hypervisor of some sort.
And you could see the list of
virtual machines that I'm running here, I have Ubuntu,
I've got Windows Server 2012,
I've got an old version of Windows XP,
just in case a question comes up on it.
Windows 7, Windows 10, Windows 8,
everything is here and all of these are separate
virtual machine files,
but they're all stored in the same place on a drive.
So you gotta be careful with this.
You wanna make sure that you protect those files.
And then you can see the settings for each of these.
You can see the amount of memory that I've assigned
to the virtual machine,
and you can see how much video memory it's using.
You can find out information about the audio,
the network, the USB.
If we were to click on one and then go to settings
we'd get even more information about this.
Where the file is stored,
how much memory we're using, which we can modify here.
The boot order, as I mentioned before
make sure that hard disc is first in the list.
Chip set compatibility,
the mouse or pointing device that you're using,
additional features.
For example, EFI, which we definitely would want to enable
on say Windows Vista or higher
and some other operating systems.
There's tons of stuff here to look at
as far as what you're doing with the system.
Audio network, serial ports, USB.
And again, if you're not gonna use something like USB
on this system then disable it all together,
right from here.
Just get rid of it.
No need to go ahead and disable it in the device manager
within the virtual machine operating system
because we've disabled it right here
from the Virtual Machine Manager.
So that could be very powerful more higher level control.
Shared folders, we mentioned this can be,
this could be deadly when it comes
to malware and when it comes to attacks.
So monitor these shared folders within here as well.
So you can see all this stuff from here.
And this is just a very basic example
of a virtualization program
but something that you can download for free.
So I would say,
go and check out the latest version of VirtualBox,
download it, and you could download Ubuntu for free
and there's plenty of other types of Linux
you could download for free.
Install that directly to a virtual machine
and see how it works.
And we'll show a little bit more with this
and other Virtual Machine Manager software programs
in the last sub lesson of this lesson.
So that's about it for this one.
Again, make sure that you're checking your requirements
your network requirements, your system requirements
and your security requirements,
and make sure that they will all work
with the software you wanna run
within the virtual machine and make sure that
your hosting computer can support all this as well.