Hyper-V Replication with AD

Today I will try different method, enabling Hyper-V replication thorugh AD without HTTPS authentication, this will be much easier without needing to worry about certificate expiry. We are ignoring any advanced setup at this moment and only planned to achieve Hyper-V replication.

Here, assuming have 2 physical server hosting VM’s, which are HV01 and HV02.

  1. Edit the hosts file in C:\Windows\System32\drivers\etc\hosts
  • Add the IP address of each server vice-versa.

2. From Server Manager > Add Roles and Features, add selected 3 features for installation. Primary is mandatory to install all 3 features, the secondary server can just install Hyper-V.

3. After features has been installed, reboot the server and start configuring AD.

4. If this is a new domain, just select add a new forest.

5. Type in DSRM password, and then just click Next troughout the menus.

6. Click Install.

7. After finish installing ADDC service, Windows will automatically reboot.

8. On Replica Server (HV02) we need to join domain after the Primary Server (HV01) reboots, but before that we need to configure IP address on the Hyper-V network adapter, or other adapter you are using. DNS server should be the ADDC server vice-versa, and the secondary should be your router.

9. On HV02, after IP has been set we can join the domain.

10. Type in the administrator username and password.

11. After joining domain and reboot, we need to configure firewall on both servers to allow Hyper-V HTTP replication port 80. Make sure all profiles are allowed to avoid hassle.

12. Then we need to enable replica function on both servers. Click Hyper-V Settings.

13. Enable as replica server.

14. You can also add another server to the Hyper-V Manager panel for easier management.

15. We can now start enabling VM’s replication. Select the VM you wish to enable replication.

16. Type in the hostname of 2nd server. In my case is HV02.

17. I will select 30s for my replica interval. Which means at most if primary server fails, at most there is a 30s data lost Window.

18. I will skip through the default settings by clicking Next and then Finish the wizard.

19. If the replication is functioning normally, you will see the replication status and the VM will appear on both servers. But the VM will runs only on one physical server at a given time.

20. Optional – Promote the secondary HV02 server to domain controller

  • Not necessary needed, but it’s better for future use cases

Click promote the server.

21. Add domain controller to existing domain, type in the credentials and click next.

22. Type in the DSRM password.

23. Install the ADDC services and then reboot the secondary server and you are done.

Author

Leave a Reply

Your email address will not be published. Required fields are marked *