VM with ZFS raw disks over iSCSI does not boot due to missing extents in TrueNAS

linkstat

Renowned Member
Mar 15, 2015
38
20
73
Córdoba, Argentina
Hello community.

I have a small environment of two Proxmox VE nodes pve-manager/7.2-7/d0dd0e85 (running kernel: 5.15.39-1-pve) + 1 TrueNAS storage (TrueNAS-12.0-U8.1 with freenas plugin 2.2.0-0 -beta1 from theGrandWazoo). I store my VMs using ZFS over iSCSI, and backup them using NFS.

Until a few days ago, everything was perfect. But one day, after a power outage, the TrueNAS server went "unconfigured" (maybe because I didn't save the configuration, but that doesn't matter) and most of the iSCSI extents are no longer listed, although the raw disks of the VMs are still there, intact.

Of course, this causes some VMs to start without problems, but others (those that do not have their corresponding extents in TrueNAS) do not, indicating with the error message:
Code:
TASK ERROR: Could not find lu_name for zvol vm-1020-disk-0 at /usr/share/perl5/PVE/Storage/ZFSPlugin.pm line 118.


On TrueNAS, I can verify that there is no iSCSI extent for that VM, and I guess that is the cause of the problem. Because for the VMs that are listed, they can boot:
1660672133757.png



So, I decide to add an extent manually, indicating the corresponding device, for example:
1660672363575.png



Nice, now I have everything in order, I try to start the VM:
1660672492788.png



But the VM startup still fails...
1660672581048.png

So what am I missing? How do I link / edit the disk with its corresponding extent?

Now, to fix this, I'm creating new VMs with disks stored on TrueNAS via ZFS over iSCSI, and then from TrueNAS dd if=original_vm_image_disk of=new_vm_image_disk
but this takes a lot of time, and I'm sure there is a better way.

Any help will be appreciated.

Regards!
 
Now, to fix this, I'm creating new VMs with disks stored on TrueNAS via ZFS over iSCSI, and then from TrueNAS dd if=original_vm_image_disk of=new_vm_image_disk
but this takes a lot of time, and I'm sure there is a better way.
One way would be to create every disk new (exact! size) and just rename the underlying zvols on your TrueNAS server.
 

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!