In this video, learn how to create a Hyper-V switch in Windows Server 2016. The first switch that’s created will be built upon by additional switches you create for your software defined network.
- [Instructor] In the previous video we demonstrated installing Hyper-V, but we did not install the virtual network switch. Let's go ahead and do that now. We'll click on our Hyper-V Manager, and then Virtual Switch Manager. We can see there's no current switch yet, so we're going to go ahead and create it. We have the three options we talked about in our previous video about the External, Internal, and Private. We're going to want to go with the External because we want this virtual machine to be able to communicate with the rest of the world.
We also have some option here for the MAC Address Range. Some people like to set this range so they can take control of what MAC Addresses are being broadcast out. Other people like to just choose the default and let it pick one randomly. Let's go ahead and choose the New virtual network switch, and Create Switch. Let's call this first one VLAN1 because we're going to be using VLAN1 on this particular network. From here we have the option of which external network connector we want to use.
We're going to choose this bottom one here because we know it's not being used for anything else. We also have the option for allowing the management operating system to share the network adapter, which I definitely agree we should do. Otherwise you'll have some difficulty in connecting to both the virtual machine and the host if you want to remote into them. If you enable the single-root I/O virtualization, then that will keep separate both the physical and the virtual network adapters so they show up as two different items. In our particular case we don't need to worry about that, so we'll just go ahead and ignore it.
Then we also have the option to set a VLAN ID tag. We're going to do that, and we're going to set it to one. And that's because our first virtual machine is going to be using the VLAN ID of one. Let's go ahead and click Apply. You will get a message that you may see some disruption. Then when it's done we'll go ahead and click OK. Now let's take a look at our two virtual machines and see the difference between assigning a virtual switch and not assigning one.
First we'll start with Server 2. Let's go ahead and choose Server 2 at the bottom. Click that. Then we'll go to our network and sharing center where we should see our network adapter. Click on Change adapter settings, and we see the network adapter has shown up; but it shows that it's disconnected. That's because we did not assign it a switch. Let's go ahead and minimize that, and we'll go to our first server. We'll do the same thing.
Once again we see that the network adapter shows up, but it shows up as unplugged. Let's go over to File, Settings, and we'll go over to our Network Adapter; and we'll choose our new virtual switch. We'll enable the VLAN identification, change it from two to one, click Apply. Now it shows our network card attaching to our computer. Since we don't have a DHCP server set up, let's go ahead and statically set this network card by right-clicking on it and choosing Properties.
From here we'll go ahead and click on the Version 4 of IP. We'll assign it an IP we know is not currently in use. Put in our router for the gateway and our DNS server. Click OK, and click OK. Now let's go down to a command prompt. We'll make sure we can communicate with the rest of the world.
Let's go ahead and ping an outside IP address. We see we are communicating. Now that only worked because our host computer is VLAN ID one as well. Otherwise, we would not get anywhere because the VLAN1 ID on the virtual machine wouldn't match the VLAN ID number on the host machine. We're going to get into that and more in upcoming videos, but we needed to create a virtual switch and bind it to our virtual machine in order for our virtual machine to be able to communicate with the outside world.
Note: This course is the first of two that will cover SDN in a Server 2016 network. This course maps to the SDN deployment objectives in Exam 70-745.
- Planning an SDN
- Configuring a Hyper-V switch
- Creating network objects in Virtual Machine Manager
- Creating IP pools and VM networks
- Creating logical switches and uplink ports
- Configuring an edge gateway
- Creating multitenant VMs