Virtual machine replication is a brand new feature that has been added from the Proxmox VE 5.0 release. This is a very useful feature for a single-node Proxmox environment where VM disk images reside locally on the same computer node the VMs actually run from. With this option, VMs can be replicated to a different node in real time should the primary node go down for any number of reasons. In such a scenario, the second node with a replica of the VMs can be brought online, thus minimizing downtime significantly.
The storage must be attached to a Proxmox cluster using the ZFS storage plugin, as shown in the following screenshot:
The replication simply will not work when the disk image is on any other storage. Even if the disk image is stored on a ZFS storage with NFS share, replication will not work. In such a scenario, when trying to create replication, the following error message will be displayed:
ZFS is needed because the replication uses ZFS snapshots to perform replication, minimizing network traffic. A new command line tool, pvesr, has been added to perform all replication tasks. When we manage replication through the GUI, it just leverages the pvesr command.