1 00:00:00,940 --> 00:00:04,620 In this demonstration, I'll teach you how to set up Hyper‑V Replica. 2 00:00:04,620 --> 00:00:07,180 We're on a Windows Server 2022. 3 00:00:07,180 --> 00:00:08,550 domain member server. 4 00:00:08,550 --> 00:00:11,040 Let me bring up Hyper‑V Manager. 5 00:00:11,040 --> 00:00:12,640 The machine we're on as MEM1. 6 00:00:12,640 --> 00:00:14,350 I've right‑clicked the root node, 7 00:00:14,350 --> 00:00:17,620 did a Connect to Server so I could bring in MEM2 as well. 8 00:00:17,620 --> 00:00:19,830 MEM2 is going to be my replica, specifically. 9 00:00:19,830 --> 00:00:23,220 And you can see I've got one machine running, 10 00:00:23,220 --> 00:00:25,450 one that's in a critical state, 11 00:00:25,450 --> 00:00:28,110 but we're just going to replicate vm02 in this example. 12 00:00:28,110 --> 00:00:31,070 You can see down in the thumbnail it looks like I haven't 13 00:00:31,070 --> 00:00:34,930 yet installed Windows on the machine, but it's ready to be installed. 14 00:00:34,930 --> 00:00:36,840 That's fine. 15 00:00:36,840 --> 00:00:39,330 We'll want to go to our replica machine and set it up. 16 00:00:39,330 --> 00:00:41,630 First though as a preliminary step. 17 00:00:41,630 --> 00:00:44,420 I want to make sure that my networking is sorted out on 18 00:00:44,420 --> 00:00:49,440 both the primary and the replica, so let me go to Virtual Switch Manager. 19 00:00:49,440 --> 00:00:53,900 I've got an external switch there, and then on the source server, same thing. 20 00:00:53,900 --> 00:00:57,400 I made sure to have an identically configured switch 21 00:00:57,400 --> 00:00:59,540 that's connected to that machine. 22 00:00:59,540 --> 00:01:02,360 I'm going to want to now go to the replica machine, 23 00:01:02,360 --> 00:01:07,640 right‑click Hyper‑V Settings, and go to Replication Configuration. 24 00:01:07,640 --> 00:01:11,000 We first enable this computer as a Replica server and then 25 00:01:11,000 --> 00:01:14,240 either use Kerberos or certificates. 26 00:01:14,240 --> 00:01:17,850 I don't have a public key infrastructure at this time, so I'm doing Kerberos. 27 00:01:17,850 --> 00:01:20,090 And then down at the bottom, 28 00:01:20,090 --> 00:01:24,240 we can either allow replication from any authenticated server 29 00:01:24,240 --> 00:01:27,430 or allow repl from only specified servers. 30 00:01:27,430 --> 00:01:29,680 I'm going to do any for now and click OK. 31 00:01:29,680 --> 00:01:32,040 So MEM2 is sorted out. 32 00:01:32,040 --> 00:01:33,190 Let's go back to MEM1, 33 00:01:33,190 --> 00:01:36,720 and let's right‑click vm02 and come down to Enable 34 00:01:36,720 --> 00:01:39,140 Replication from the shortcut menu. 35 00:01:39,140 --> 00:01:43,840 I'm going to suppress the welcome page so I don't see this ever again. 36 00:01:43,840 --> 00:01:46,220 I'm going to resolve mem2, press Enter. 37 00:01:46,220 --> 00:01:50,400 It verifies the fully qualified domain name of the replica, 38 00:01:50,400 --> 00:01:51,820 what port we're going to use. 39 00:01:51,820 --> 00:01:54,600 Now we're going to need to make sure that TCP 80 is 40 00:01:54,600 --> 00:01:57,340 allowed inbound to this machine, and, of course, 41 00:01:57,340 --> 00:01:58,290 that's the case. 42 00:01:58,290 --> 00:02:01,010 I've already sorted out my firewall stuff, 43 00:02:01,010 --> 00:02:02,370 but it's just something to think about. 44 00:02:02,370 --> 00:02:03,790 Compress the data. 45 00:02:03,790 --> 00:02:04,490 That's fine. 46 00:02:04,490 --> 00:02:05,810 Kerberos is what we're doing. 47 00:02:05,810 --> 00:02:06,220 Next. 48 00:02:06,220 --> 00:02:08,390 Verifying the VHDs. 49 00:02:08,390 --> 00:02:10,660 Note that we could omit VHDs. 50 00:02:10,660 --> 00:02:14,060 If we had a big data disk that for whatever reason we 51 00:02:14,060 --> 00:02:17,140 did not want in scope for replication, we could opt that out. 52 00:02:17,140 --> 00:02:18,660 Let's click Next. 53 00:02:18,660 --> 00:02:24,170 Our replication frequency, 30 seconds, 5 minutes, or 15 minutes. 54 00:02:24,170 --> 00:02:25,640 I'm going to choose 30 seconds. 55 00:02:25,640 --> 00:02:30,540 That's pretty aggressive, but I want my changes to move very quickly. 56 00:02:30,540 --> 00:02:33,750 It says here you can choose to store only the latest recovery point 57 00:02:33,750 --> 00:02:36,120 of the primary virtual machine on the replica, 58 00:02:36,120 --> 00:02:40,430 or we can add additional, allowing to recover to an earlier point of time. 59 00:02:40,430 --> 00:02:45,200 That, again, has echoes of Azure Site Recovery, doesn't it? 60 00:02:45,200 --> 00:02:47,770 That notion of the replication snapshot. 61 00:02:47,770 --> 00:02:52,250 So we can have additional hourly recovery points to 62 00:02:52,250 --> 00:02:54,410 give us a particular time objective. 63 00:02:54,410 --> 00:02:58,140 I'm just going to do the most recent one here and click Next. 64 00:02:58,140 --> 00:02:59,280 This is kind of cool. 65 00:02:59,280 --> 00:03:03,970 If your replica is going to be offline in an air‑gapped network or it's 66 00:03:03,970 --> 00:03:06,320 just going to be too time and bandwidth intensive, 67 00:03:06,320 --> 00:03:11,240 you can, instead of sending the initial replication over the network, 68 00:03:11,240 --> 00:03:13,240 you can use external media. 69 00:03:13,240 --> 00:03:16,390 We also can schedule that replication to take place, 70 00:03:16,390 --> 00:03:17,050 for instance, 71 00:03:17,050 --> 00:03:20,950 at a period of low network utilization so that we minimize 72 00:03:20,950 --> 00:03:24,040 impact on our services and our users. 73 00:03:24,040 --> 00:03:26,710 I'm going to do Send initial copy over the network 74 00:03:26,710 --> 00:03:28,470 and start replication immediately. 75 00:03:28,470 --> 00:03:33,740 Let's click Next and Finish, and here we go. 76 00:03:33,740 --> 00:03:37,330 Note that this process is not interrupting vm02. 77 00:03:37,330 --> 00:03:39,000 It's continuing to run. 78 00:03:39,000 --> 00:03:40,800 It's continuing to stay online. 79 00:03:40,800 --> 00:03:44,780 And if we go over to MEM2, we now see vm02, 80 00:03:44,780 --> 00:03:47,400 but notice that it's in an off state. 81 00:03:47,400 --> 00:03:51,920 We can right‑click on the replica, come down to Replication, 82 00:03:51,920 --> 00:03:56,240 and we can View Replication Health to see what's happening, 83 00:03:56,240 --> 00:03:59,020 that this machine is in a Replica state, 84 00:03:59,020 --> 00:04:01,760 replication's enabled, the health is normal, 85 00:04:01,760 --> 00:04:05,170 that's what we want to see, no errors encountered, 86 00:04:05,170 --> 00:04:11,650 last synchronization date/time, also, test failover metadata as well. 87 00:04:11,650 --> 00:04:12,570 Let's refresh that. 88 00:04:12,570 --> 00:04:15,030 So it's gradually bringing that data over. 89 00:04:15,030 --> 00:04:16,020 Click Close. 90 00:04:16,020 --> 00:04:18,840 And I had mentioned the exam alert, 91 00:04:18,840 --> 00:04:22,440 understanding what options are available on the primary, 92 00:04:22,440 --> 00:04:24,750 what options are available on the secondary. 93 00:04:24,750 --> 00:04:28,340 So if we right‑click the secondary and go to Replication, 94 00:04:28,340 --> 00:04:31,280 we can do both production and test failovers. 95 00:04:31,280 --> 00:04:35,640 We can also extend replication to yet another host. 96 00:04:35,640 --> 00:04:39,040 If we go to our source machine and go to Replication, 97 00:04:39,040 --> 00:04:40,790 all we can do is a planned failover. 98 00:04:40,790 --> 00:04:43,480 And that just makes sense logically, I hope, 99 00:04:43,480 --> 00:04:47,140 because planning is something that we do while the 100 00:04:47,140 --> 00:04:50,440 environment is in a status quo or healthy state, 101 00:04:50,440 --> 00:04:54,380 but an actual failover, we're presuming the primary is inaccessible, 102 00:04:54,380 --> 00:04:58,210 so, of course, we would configure that from the secondary. 103 00:04:58,210 --> 00:05:00,940 I hope that makes some semblance of sense. 104 00:05:00,940 --> 00:05:05,140 I also want you to see that now that we've enabled Hyper‑V Replica, 105 00:05:05,140 --> 00:05:14,000 the Hyper‑V Manager has an additional tab that can just save us a little bit of viewing when we're using the user interface.