Unable to import disc

Karabanov

Member
Aug 3, 2019
2
0
6
37
Hi

I'm trying to import the disk as usual:
Code:
root@pve2:/mnt/tmp_storage# qm importdisk 105 srv-1.qcow2 vm-data-4tb

importing disk 'srv-1.qcow2' to VM 105 ...
  Wiping dos signature on /dev/vm-data-4tb/vm-105-disk-0.
  Logical volume "vm-105-disk-0" created.
transferred 0.0 B of 64.0 GiB (0.00%)
transferred 655.4 MiB of 64.0 GiB (1.00%)
transferred 1.3 GiB of 64.0 GiB (2.00%)

... skipped ...

transferred 63.5 GiB of 64.0 GiB (99.16%)
transferred 64.0 GiB of 64.0 GiB (100.00%)
transferred 64.0 GiB of 64.0 GiB (100.00%)
can't deactivate LV '/dev/vm-data-4tb/vm-105-disk-0':   Logical volume vm-data-4tb/vm-105-disk-0 in use.
  Logical volume "vm-105-disk-0" successfully removed
volume deactivation failed: vm-data-4tb:vm-105-disk-0 at /usr/share/perl5/PVE/Storage.pm line 1233.

But for some reason I get a strange error:
Code:
can't deactivate LV '/dev/vm-data-4tb/vm-105-disk-0':   Logical volume vm-data-4tb/vm-105-disk-0 in use.

  Logical volume "vm-105-disk-0" successfully removed

volume deactivation failed: vm-data-4tb:vm-105-disk-0 at /usr/share/perl5/PVE/Storage.pm line 1233.

Please tell me what am I doing wrong?
 
I started importing the disk through the strace to understand what exactly was happening and the import was successful!

I don't know what's the matter. Looks like a race condition...
 
I ran into this today for the first time, on a PVE 8.0.4 cluster with LVM shared storage via FC SAN.

I checked over everything after the initial failure, and then tried it again. Second time was successful with no changes made to the system.