Azure Network Connectivity and Name Resolution
The course is part of these learning pathsSee 1 more
Learn how to configure Microsoft Azure connectivity and name resolution with this expertly instructed course from Cloud Academy.
In this course, you will learn two different ways to connect virtual networks together. The course starts by teaching you how to set up peering between virtual networks and then moves on to showing you how to connect two VNets using a virtual network gateway. Once you have mastered network connections, you will learn how to use Azure DNS to configure custom domain names for the resources in your VNets. Finally, we will move on to learning how to set up both public and private DNS zones.
This course is essential for those looking to train enterprise teams since, by default, Azure virtual networks are isolated from each other and only have a rudimentary form of name resolution. To build useful networks in Azure, you will need to connect these virtual networks together. To make them easier to manage, you will need to implement custom name resolution.
This course is made up 7 lectures with an introduction and conclusion to aid in reviewing what you have learned throughout the course.
Configure Azure virtual network peering
Create a virtual network gateway and use it to connect two VNets
Configure Azure DNS to handle name resolution
Those looking to become Azure cloud architects
Those preparing for Microsoft’s AZ-100 or AZ-102 exam
- Basic knowledge of Azure virtual networks
- The GitHub repository for this course is at https://github.com/cloudacademy/azure-networks-and-dns
As I mentioned earlier, Azure DNS now supports private domains that aren't accessible over the internet. In the simplest scenario, you can use Azure DNS to set up a custom domain inside a single virtual network. One advantage of using Azure DNS to do this is that it will also automatically create a DNS record for each of the VMs and other resources in the virtual network so you don't have to. At the moment, you can't create a private DNS zone in the portal, so you have to use either the Azure command-line interface or PowerShell. I'm going to use the CLI. Before we can create a private zone, we need a virtual network, and in order to create a virtual network, we need a resource group. So I've included commands to do all of these tasks in the read me file in the GitHub repository for this course.
The URL pointing to it is at the bottom of the overview below. First go into Cloud Shell. Then copy the command to create a resource group. And paste it. Good, it says it succeeded. Now copy and paste the command to create a virtual network. It's a little harder to find the status on this one, but it says it succeeded. Let's have a look at the next command before we run it. The first line is pretty straightforward. We're creating a DNS zone in the resource group we created earlier. Next it gives the name. Since this is a private zone, we're not using a .com or .net domain name.
Instead we're calling it contoso.local. Then we set the zone type option to private. The only part of the command that requires more explanation is the registration-vnets option. This says which virtual network it will automatically create records for. Since we only have one vnet, that's the one we need to specify. I'll tell you more about registration vnets in the next lesson. Okay, now copy and paste the command. It didn't need to provision anything, so there's no succeeded message, but it did work. To test the capabilities of the private zone, let's provision a couple of VMs. Copy and paste these two commands. Highlight it so the last line has a space at the end. That way it'll run the second command as soon as the first one's done. It'll take a few minutes, so I'll fast-forward. Okay, they're ready. Now unfortunately there's no way to see the DNS records that were automatically created. We'll just have to do a ping between the VMs to make sure it's working. Click on Virtual Machines.
Select Connect from the menu next to myvm1. Copy the SSH command and paste it into the shell. Okay, now we're on the VM. Type ping myvm2.contoso.local. It worked. The record for myvm2 was automatically created. Hit Control + C to stop pinging. In fact, you don't even need to use the fully qualified name. You can just type ping myvm2. It works. We could also connect to myvm2 and ping myvm1, but I don't think we need to go through that exercise. Everything's working fine. To log out from myvm1, either hit Control + D or type exit. Make sure you delete these two VMs so you don't incur any additional charges. The easiest way to do that and to delete everything else you created, too, is to go to Resource Groups and delete MyAzureResourceGroup. That's it for this lesson. In the next lesson, we'll look at more complex scenarios.
About the Author
Guy launched his first training website in 1995 and he's been helping people learn IT technologies ever since. He has been a sysadmin, instructor, sales engineer, IT manager, and entrepreneur. In his most recent venture, he founded and led a cloud-based training infrastructure company that provided virtual labs for some of the largest software vendors in the world. Guy’s passion is making complex technology easy to understand. His activities outside of work have included riding an elephant and skydiving (although not at the same time).