Microsoft Azure AZ-801 — Section 12: Implement disaster recovery by using Azure Site Recovery Part 2

Microsoft Azure AZ-801 — Section 12: Implement disaster recovery by using Azure Site Recovery Part 2

77. Cleaning up to save Azure credit

I am going to clean up some of my Azure resources now. So, I’m actually going to go to Storage Count demo and I am going to tell it to delete this resource group and it is going to delete everything in it That includes the virtual machines and everything. And I’m going to do this to kind of save some of my Azure credit and all that. So, we’re just going to say delete. All right, I’m going to go and. Delete these other resource groups as well. All right. Just got to copy the name, paste it in there and delete. Some of these you may not have seen me create because I’ve just kind of done some of this on my own. But some of this you probably did see me create, but I’m going to go ahead and just get rid of all this stuff. And so this is how you can kind of clean things up and make sure, too, that you’re not that Azure is not sucking up a bunch of your Azure credit. You can just you can have these resource groups delete it. It’s kind of wiped through those. All right. Now, it does take some time, but eventually these resource groups are going to get deleted.

Now, one last thing. When it comes to deleting a recovery services vault, like you’ll notice in my storage account demo here, I’ve got this recovery vault demo in order to delete that. You go right here. You click, delete. And then it basically says to delete it manually. You have to follow each of these steps.

So, step one, go through the procedure steps right here. And then do these procedure steps, so on and so forth. And eventually you’ll be able to confirm it. Click Yes, and you’ll be able to delete it. All right.

So, that’s how you’re going to delete a recovery services vault.

78. Configure Site Recovery for Azure Virtual Machines and on-premises VMs

All right. I am going to get into the concepts now of being able to replicate for site replication, site recovery, meaning I can replicate Azure VMs to other places. I can also replicate on-premises Hyper-V, VMs to other places. And we’re going to talk about the process of doing that.

So, I’m just going to go to the menu button here and I’m going to go to virtual machine of virtual machines. There it is, click create. And pretty much been wiping out my other stuff here. But I’m going to create a new virtual machine and resource group. This resource group. I’m going to call it EastUSRG because it’s going to be tied to the East US resource group. The virtual machine is just going to be called VM1, very creative name. And no availability zone or any of that. Get rid of that. We’ll just make it a Windows 2022. Standard size is fine. Go ahead and set my admin credentials. All right. Does help if you don’t type it. There we go. All that looks fine disks. I’m going to go with standard hard disk drives. Nothing really. Here on networking. We’ll just leave all that defaults. All right. We can enable the auto shutdown. I like this just because it makes sure that I don’t leave my VMs running all the time. I’ll set that for 7:00 pm. That’s fine and not going to do any kind of diagnostics or anything and click or view and create. And once this is done validating, I’m going to go ahead and click create and I’ll just pause the recording while that’s happening.

Now, if that is done, I’m actually going to go to the menu button here and go to all services. We’re going to create a new recovery vault. So, I’m just going to do a search for the word vault. And there it is, Recovery Services Vault. And we’re going to click to create a new vault here. All right. And I’m going to also create a new resource group. This is going to be called the West US Resource Group. From there, we’re going to go we’re going to call this West us. Uh, recovery vault. All right. Just give it that name. And we’re going to choose the location is going to be west us. There it is. We’re going to click Review and create, click, create. And we’ll go ahead and pause the recording while that’s creating. Once the Recovery Vault is done creating, I can click go to Resource and that’ll bring me here. All right. And.

So, the next thing I want to do is go down here to. Site recovery. It’s right up under protected items. So, I’m going to click on sorry under getting started. So, I’m going to click on site Recovery. And so this is actually where I could, if I wanted to choose to back up an Azure virtual machine, I can do that here. I can also back up VMware virtual machines in Azure as well as on-premises Hyper-V. So, I can go through this set of steps here. It’ll have me download some software and put it on Hyper-V and I can actually backup data from my Hyper-V environment on-premises into Azure. But let’s look at Azure virtual machines. We’re going to click Enable replication and we have our East US region and our resource group. Keep in mind sometimes if you come in here really quick after you’ve just created the vault and all of that, it may not show everything. So, you might refresh your browser, but resource group here.

So, the East US region, our resource group, and then from there, we’re not we’re not doing anything with this availability zone feature. So, we’re clicking next. And from there I can choose my virtual machine, which is called VM1. We’re going to go ahead and click Next. All right. And then the target location would be West US, right? Target Resource Group will be West US, RG. And, it’s going to create a little virtual failover network for it that will kind of match the, the virtual network that the virtual machine is on. That’s fine. You can adjust the storage for this if you want. I’m just going to keep the storage the same. You can also adjust availability options if you want availability set, which allows you to have multiple replicas of your VM in the same data center on different equipment racks. But I’m just going to leave that alone. And then capacity. This lets you confirm a reserve capacity in their data center. You can reserve guaranteed capacity. That basically means the scenario would be if for some reason the data center was full and there were no resources left, it wouldn’t fell over for you. It’s a cheaper solution to go with that. But you can also go with select a capacity. But from there, I’m going to go ahead and click Next. And it’s got a retention policy. 24-hour retention is going to keep you would be able to backtrack for the 24 hours if you wanted. All right. And I’m going to click Next. And we’re going to go ahead and click Enable replication. All right. And so that is how we can set up replication of an Azure VM between sites.

79. Implement VM replication to secondary datacenter or Azure region

All right. Now, that we have our Recovery Services vault set up with our VM to support site replication, I want to trigger a failover and just have this happen here.

So, here we are on portal.azure.com. We’re going to click on Recovery Services Vault, which again I can always get to that by going to the menu and all services and searching for it. We’ll go there. We have a recovery services vault called West US Recovery Vault, and that is where our virtual machine replication and all that’s going on. We can see that by going over here to replicated items. And then from there, there’s our VM. Everything looks healthy. Currently it’s in East US, but we can replicate it to West us. All right.

So, from there, I’m going to go ahead and click Failover. All right. And so we’re failing over from the east, us to the west, US. It says their reserve capacity is available, so there’s plenty of capacity. And then I can also tell it to shut down the machine before filling over if I want. But all right, I’m going to go ahead and click Okay and I’m going to go ahead and let this thing fell over. I’ll pause the video recording while this is happening. All right.

So, our virtual machine fell over is complete. You can see right here, it says faill over complete. Don’t think I’ve got any errors or anything. No errors. Check this out. We’ll go over here to our resource groups. And the virtual machine originally was running in the East US Resource Group, but as you can see, the virtual machine in East US is currently shut down. See? It wouldn’t give me the option to start if it was running right. Let’s go over to resource groups again. We’ll go to West us and look at VM1. And as you can see, it is started. So, the virtual machine is up and running in West US. All right. All right.

Now, hopefully that gives you a good understanding of the failover process and setting up the site recovery when it comes to VM replication.

80. Configure Azure Site Recovery policies

Now, one of the things I need to set up in order for my Azure environment to start beginning to fail over in case of a scenario to support automation to failover is I can attach what’s called an Azure Site Recovery policy, which is really just an Azure policy that can be implemented.

So, to do that, here I am on portal.azure.com, I’m just going to click the menu button here and what we’ll do is go to resource groups. All right. And we’ll go to our East US Resource group. And there is a blade called Policies. And we’re going to click on that, and then we’re going to click to assign a policy. All right. And right here, it says policy definition. We’re going to click that. We’re going to search for the word disaster and you’ll see the policy right here. Configure disaster recovery on virtual machines by enabling replication via site recovery. All right. Says right here, virtual machines without disaster recovery configuration are vulnerable to outages and other disruptions. So, we’re going to click on that click select. We’re going to click Next. And it’s going to ask us parameters.

So, we need to specify our source region, which is going to be East US and then our target region, which is our case is going to be west US. All right, so there’s West US, the resource group is West US. RG That’s where our vault is. There’s our recovery services vault, All right. And then at that point we can click Review and create, click, create. And we’ve just got to wait on the policy to be applied. It is going to apply it to our resource.

So, now if we go back over here to the menu button and we go to resource groups, we should also go right here to the West US RG, and we should see the let’s see the recovery vault. You can see the replicated information here. And then the recovery vault is right here. All right. And from there, we can look at replicated items. You can see our virtual machine. And virtual machine is healthy. There’s not been a replication occurred yet, so it hasn’t had to I’m sorry. It hasn’t had to fell over. So, everything is officially set up. It’s healthy. And we’ve set up our Azure policy now.