Stuck VM (alternatives to connect to console?) and frozen conversion process.

Axl_fzetafs

Active Member
Apr 29, 2020
80
2
28
51
Hi,

I succesfully imported a VHDX disk and started the machine (I had to set the SCSI controller to default and BIOS UEFI).
The conversion process told me it converted a 60Gb-big file when actually the VHDX file was 50Gb big.
Then I started the process of importing another VHDX disk. QM told me that it had to convert a 60Gb-big disk, though the VHDX file was 20Gb big.
The overall result was that I was not able to connect through the console on the first machine and the conversion process froze at the 100% without exiting.

I tried to connect to the first machine (through the console) to shut it down from within, no way.

I tried (I found this advice on another thread), but I got confused, 'cause if I provide the password, the password is not recognized as option, if I don't provide it, then I got the error msg that vncproxy cannot run without it. "man qm" reports no password option for the switch vncproxy...

Code:
root@pve03:~# nc -l -p 5900 -c "qm vncproxy 107 pippo"
400 too many arguments
qm vncproxy <vmid>
root@pve03:~# nc -l -p 5900 -c "qm vncproxy 107"

LC_PVE_TICKET not set, VNC proxy without password is forbidden



I used the "qm shutdown <vmid>" command but I got

Code:
root@pve03:~# qm shutdown 107
VM 107 qmp command 'query-status' failed - unable to connect to VM 107 qmp socket - timeout after 31 retries

VM quit/powerdown failed

Also I found

Code:
root@pve03:~# ps -ef | grep 107.vnc
root      190593       1  1 17:22 ?        00:02:46 /usr/bin/kvm -id 107 -name RADIUS01 -no-shutdown -chardev socket,id=qmp,path=/var/run/qemu-server/107.qmp,server=on,wait=off -mon chardev=qmp,mode=control -chardev socket,id=qmp-event,path=/var/run/qmeventd.sock,reconnect=5 -mon chardev=qmp-event,mode=control -pidfile /var/run/qemu-server/107.pid -daemonize -smbios type=1,uuid=b481964d-e1b1-4768-b847-9662a7042320 -drive if=pflash,unit=0,format=raw,readonly=on,file=/usr/share/pve-edk2-firmware//OVMF_CODE.fd -drive if=pflash,unit=1,format=raw,id=drive-efidisk0,size=131072,file=/tmp/107-ovmf.fd -smp 2,sockets=2,cores=1,maxcpus=2 -nodefaults -boot menu=on,strict=on,reboot-timeout=1000,splash=/usr/share/qemu-server/bootsplash.jpg -vnc unix:/var/run/qemu-server/107.vnc,password=on -no-hpet -cpu kvm64,enforce,hv_ipi,hv_relaxed,hv_reset,hv_runtime,hv_spinlocks=0x1fff,hv_stimer,hv_synic,hv_time,hv_vapic,hv_vpindex,+kvm_pv_eoi,+kvm_pv_unhalt,+lahf_lm,+sep -m 4096 -device pci-bridge,id=pci.1,chassis_nr=1,bus=pci.0,addr=0x1e -device pci-bridge,id=pci.2,chassis_nr=2,bus=pci.0,addr=0x1f -device vmgenid,guid=0fa22d9a-deaf-449b-a806-55eaff74627a -device piix3-usb-uhci,id=uhci,bus=pci.0,addr=0x1.0x2 -device usb-tablet,id=tablet,bus=uhci.0,port=1 -device VGA,id=vga,bus=pci.0,addr=0x2 -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 -iscsi initiator-name=iqn.1993-08.org.debian:01:93f8b4939936 -drive file=/dev/pve/vm-107-disk-1,if=none,id=drive-ide0,format=raw,cache=none,aio=io_uring,detect-zeroes=on -device ide-hd,bus=ide.0,unit=0,drive=drive-ide0,id=ide0,bootindex=100 -drive file=/var/lib/vz/template/iso/KNOPPIX_V9.1CD-2021-01-25-EN.iso,if=none,id=drive-ide2,media=cdrom,aio=io_uring -device ide-cd,bus=ide.1,unit=0,drive=drive-ide2,id=ide2 -netdev type=tap,id=net0,ifname=tap107i0,script=/var/lib/qemu-server/pve-bridge,downscript=/var/lib/qemu-server/pve-bridgedown -device e1000,mac=AE:94:54:24:A7:00,netdev=net0,bus=pci.0,addr=0x12,id=net0 -rtc driftfix=slew,base=localtime -machine type=pc-i440fx-6.1+pve0 -global kvm-pit.lost_tick_policy=discard


Questions:
1.1) is there alternate way to know where the process to connect to the console gets stuck so, I can fix it?
1.2) What other safe options do I have to shutdown gracefully the previous machine?

Code:
root      190593       1  2 17:22 ?        00:02:46 /usr/bin/kvm -id 107 -name RADIUS01 -no-shutdown -chardev socket,id=qmp,path=/var/run/qemu-server/107.qmp,server=on>

2) since the conversion process stopped at 100% (I got twice the output), was the import successful?

Code:
root      192314    4152  0 17:34 tty1     00:00:01 /usr/bin/perl /usr/sbin/qm importdisk 108 DC01.vhdx local-lvm
root      192340  192314  1 17:35 tty1     00:01:09 /usr/bin/qemu-img convert -p -n -O raw DC01.vhdx zeroinit:/dev/pve/vm-108-disk-0
Can I softly kill the process 192340 first and then 192314?

I always got that I don't have the warning if the the storage gets full but from the GUI it seems that I have enough space.

TIA,

Alex
 
Last edited:

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!