Question about replication (newbie)

tzzui0

New Member
Oct 23, 2020
2
0
1
31
I'm completely new to IT and Proxmox (started an apprenticeship 2 month ago) and I was asked to test Proxmox' replication feature and see how it works.

I have 2 test servers with 1 node each in a cluster. I want to create a replication job from ServerA to ServerB and then restore the VM from ServerB to ServerA.

I created "virtual" (I'm probably going to use wrong terminology more than once) zPool drives on both servers, since those servers only have 1 drive each by creating files with "fallocate -l 15G filename" and then "zpool create zPoolx /home/filename". "zpool list" shows those drives.

Then I went to Datacenter>Storage>Add>ZFS and chose zPoolA from ServerA. Let's call it StorageA.
I also successfully installed a VM on the ZFS storageA. I then wanted to create StorageB on ServerB, but it wont let me choose zPoolB.

After that I just tried to create a replication job. VmA>Replication>Add>Target=ServerB. I then get following error:

2020-10-23 13:51:01 101-0: (remote_prepare_local_job) storage 'StorageA' is not available on node 'ServerB'
2020-10-23 13:51:01 101-0: end replication job with error: command '/usr/bin/ssh -e none -o 'BatchMode=yes' -o 'HostKeyAlias=ServerB' root@xxx.xxx.xxx.xxx -- pvesr prepare-local-job 101-0 StorageA:vm-101-disk-0 --last_sync 0' failed: exit code 255


I hope my post is somewhat comprehensible. Any help would be appreciated.

Kind regards
tzzui0
 
Last edited:
Storage names need to be the same on both hosts.
Thanks for your reply, but if i try to create another storage with the same name it just says: "create storage failed: error during cfs-locked 'file-storage_cfg' operation: storage ID 'mkiZfsTest' already defined (500)"

EDIT: Never midn I got the replication to work. I now wanted to test wether it works, but I'm not sure how to do it. I wanted to just delete the VM, but it asks me to delete the replication job first. How can i test the "Restore" function?
 
Last edited:
@tzzui0 how did you get replication to work? I have the same issue. My setup has local ZFS storages on both nodes, i can't create two storages with the same name...
 
Hi,
@tzzui0 how did you get replication to work? I have the same issue. My setup has local ZFS storages on both nodes, i can't create two storages with the same name...
the storage configuration is shared in the cluster, so you need to configure only one ZFS storage and make it available on both nodes. When editing the storage configuration (also via UI), you can choose on which nodes it's expected to be available.

Of course the pool name needs to be like referenced in the config on both nodes. A pool can be "renamed" with using zpool export/import commands, but be aware that you'll need to adapt existing VM configs on the node where the pool is renamed.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!