Renaming ZFS pools (in use)

robnavrey

New Member
Oct 21, 2020
9
1
3
Valencia, Spain
Hi,

I have a 2 node cluster with local ZFS pools.

Until today, I had 2 active NICS:

- first for the virtual machines network access
- other dedicated for the cluster

Today, I added a third NIC I intended to use for zfs replication. Everything went fine, until I tried to start the first replication task. It complained that the storage name is not the same:

2020-10-21 18:05:03 100-0: (remote_prepare_local_job) storage 'SATA_pool_PVE1' is not available on node 'pve2'

What I currently have is:

- pve1:
- SSD_POOL_PVE1 -> 1 vm
- SATA_pool_PVE1 -> 3 vm
- pve2:
- SSD_POOL_PVE2 -> 0 vm
- SATA_pool_PVE2 -> 4 vm

How could I enable replication, without losing data (and the minimum downtime)?

Regards,
 

Attachments

  • storage.cfg.txt
    740 bytes · Views: 29
If you want to rename a pool, you can do so by exporting and then importing it under a different name. But to do this the pool can't be in use.
Both the PVE Storage name, as well as the ZFS pool name have to match on both nodes for replication.
 
Hi,

already did that for the pool that wasn't in use:

- deactivaded the pool through the web gui
- zpool export SSD_POOL_PVE2
- zpool import SSD_POOL_PVE2 SSD_POOL_PVE1

After a couple of tries, I understood the changes to be made in the storage.cfg, and this pool is already OK.

But what could I do with the pools already in use? Turn off the virtual machines, follow the same procedure and then edit their config files (located at /etc/pve/nodes/pve*/qemu-server/*.conf) and change the disk locations?

Thanks in advance,
 
Last edited:
Yes, make sure nothing is using/accessing the pool. Then you should be able to export the pool.
Once the pool is imported under the right name you can update the storage definition as well as the VM configs to use the new one.
 

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!