freenas-proxmox
freenas-proxmox copied to clipboard
Truenas: Dragonfish-24.04.0 - Proxmox: 8.2.2 - Disk Creation on Truenas OK, but Proxmox plugin return error
trafficstars
Hi,
Using the stable version of your plugin from the repos source as your documentation. The connection between proxmox and truenas trough your plugin seems working fine. When i create a new VM, the disk creation from promox return and error:
Use of uninitialized value $target_id in concatenation (.) or string at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 787.
Use of uninitialized value $target_id in numeric eq (==) at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 753.
Use of uninitialized value $target_id in numeric eq (==) at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 753.
Use of uninitialized value $target_id in numeric eq (==) at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 753.
Use of uninitialized value $target_id in concatenation (.) or string at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 787.
Use of uninitialized value $target_id in concatenation (.) or string at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 787.
TASK ERROR: unable to create VM 1000 - Unable to find the target id for iqn.2023-07.xxx.truenas01:vm at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 259.
But the zvol is created on truenas. the bug seems more on a return condition of the script, than the disk process creation. I'm working on a test bench, so i can make patching for test if you need. let me know if more logs are required.
Truenas: Dragonfish-24.04.0
root@truenas01[~]# zfs list | grep vm-1000
Prod1/PromoxZvol/vm-1000-disk-0 81.4K 25.9T 81.4K -
latest Proxmox version on 18 of May 2024, apt update/upgrade as today:
proxmox-ve: 8.2.0 (running kernel: 6.8.4-3-pve)
pve-manager: 8.2.2 (running version: 8.2.2/9355359cd7afbae4)
proxmox-kernel-helper: 8.1.0
proxmox-kernel-6.8: 6.8.4-3
proxmox-kernel-6.8.4-3-pve-signed: 6.8.4-3
proxmox-kernel-6.8.4-2-pve-signed: 6.8.4-2
ceph-fuse: 17.2.7-pve3
corosync: 3.1.7-pve3
criu: 3.17.1-2
glusterfs-client: 10.3-5
ifupdown2: 3.2.0-1+pmx8
ksm-control-daemon: 1.5-1
libjs-extjs: 7.0.0-4
libknet1: 1.28-pve1
libproxmox-acme-perl: 1.5.1
libproxmox-backup-qemu0: 1.4.1
libproxmox-rs-perl: 0.3.3
libpve-access-control: 8.1.4
libpve-apiclient-perl: 3.3.2
libpve-cluster-api-perl: 8.0.6
libpve-cluster-perl: 8.0.6
libpve-common-perl: 8.2.1
libpve-guest-common-perl: 5.1.1
libpve-http-server-perl: 5.1.0
libpve-network-perl: 0.9.8
libpve-rs-perl: 0.8.8
libpve-storage-perl: 8.2.1
libspice-server1: 0.15.1-1
lvm2: 2.03.16-2
lxc-pve: 6.0.0-1
lxcfs: 6.0.0-pve2
novnc-pve: 1.4.0-3
proxmox-backup-client: 3.2.2-1
proxmox-backup-file-restore: 3.2.2-1
proxmox-kernel-helper: 8.1.0
proxmox-mail-forward: 0.2.3
proxmox-mini-journalreader: 1.4.0
proxmox-offline-mirror-helper: 0.6.6
proxmox-widget-toolkit: 4.2.3
pve-cluster: 8.0.6
pve-container: 5.1.10
pve-docs: 8.2.2
pve-edk2-firmware: 4.2023.08-4
pve-esxi-import-tools: 0.7.0
pve-firewall: 5.0.7
pve-firmware: 3.11-1
pve-ha-manager: 4.0.4
pve-i18n: 3.2.2
pve-qemu-kvm: 8.1.5-6
pve-xtermjs: 5.3.0-3
qemu-server: 8.2.1
smartmontools: 7.3-pve1
spiceterm: 3.3.0
swtpm: 0.8.0+pve1
vncterm: 1.8.0
zfsutils-linux: 2.2.3-pve2
Proxmox LOG:
May 18 08:40:45 proxint03 pvedaemon[1079]: <root@pam> starting task UPID:proxint03:00000827:00004B2C:6647F90D:qmcreate:1000:root@pam:
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::run_lun_command : create_lu(/dev/zvol/Prod1/PromoxZvol/vm-1000-disk-0)
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_check : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : REST connection header Content-Type:'text/html'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : Redirecting to HTTPS protocol
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : REST connection header Content-Type:'text/html'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : Changing to v2.0 API's
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : REST connection header Content-Type:'application/json; charset=utf-8'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : REST connection successful to '10.168.30.41' using the 'https' protocol
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_check : successful : Server version: TrueNAS-SCALE-24.04.0
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_check : TrueNAS-SCALE Unformatted Version: 24040000
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_check : Using TrueNAS-SCALE API version v2.0
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_globalconfiguration : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : called for host '10.168.30.41'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_globalconfiguration : target_basename=iqn.2023-07.com.xxx.truenas01
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::run_create_lu : called with (method=create_lu; param[0]=/dev/zvol/Prod1/PromoxZvol/vm-1000-disk-0)
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_get_first_available_lunid : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_get_targetid : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : called for host '10.168.30.41'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: Use of uninitialized value $target_id in concatenation (.) or string at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 787.
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_get_targetid : successful :
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target_to_extent : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : called for host '10.168.30.41'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target_to_extent : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: Use of uninitialized value $target_id in numeric eq (==) at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 753.
May 18 08:40:46 proxint03 pvedaemon[2087]: Use of uninitialized value $target_id in numeric eq (==) at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 753.
May 18 08:40:46 proxint03 pvedaemon[2087]: Use of uninitialized value $target_id in numeric eq (==) at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 753.
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_get_first_available_lunid : 0
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_list_lu : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : called for host '10.168.30.41'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_get_targetid : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : called for host '10.168.30.41'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: Use of uninitialized value $target_id in concatenation (.) or string at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 787.
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_get_targetid : successful :
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_list_lu : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::run_list_lu : called with (method: 'create_lu'; result_value_type: 'name'; param[0]: '/dev/zvol/Prod1/PromoxZvol/vm-1000-disk-0')
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::run_list_lu : TrueNAS object to find: 'zvol/Prod1/PromoxZvol/vm-1000-disk-0'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::run_list_lu 'zvol/Prod1/PromoxZvol/vm-1000-disk-0' with key 'name' was not found
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_get_targetid : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target : called
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : called for host '10.168.30.41'
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_api_call : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_iscsi_get_target : successful
May 18 08:40:46 proxint03 pvedaemon[2087]: Use of uninitialized value $target_id in concatenation (.) or string at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 787.
May 18 08:40:46 proxint03 pvedaemon[2087]: PVE::Storage::LunCmd::FreeNAS::freenas_get_targetid : successful :
May 18 08:40:46 proxint03 pvedaemon[2087]: VM 1000 creating disks failed
May 18 08:40:46 proxint03 pvedaemon[2087]: unable to create VM 1000 - Unable to find the target id for iqn.2023-07.xxx.truenas01:vm at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 259.
May 18 08:40:46 proxint03 pvedaemon[1079]: <root@pam> end task UPID:proxint03:00000827:00004B2C:6647F90D:qmcreate:1000:root@pam: unable to create VM 1000 - Unable to find the target id for iqn.2023-07.xxx.truenas01:vm at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 259.