[SOLVED] xenserver PV (paravirtualization) VM to proxmox

empbilly

Member
Jul 31, 2022
22
1
8
Hello,

I converted a VM using the scritp xva-conv.sh directly via wget and it always gets stuck at the boot screen.

I've done and re-done it using other settings and nothing works. I tried to fix grub and it didn't work either.

In a VM that is in PV mode do I need to install something to work in proxmox?
 
In a VM that is in PV mode do I need to install something to work in proxmox?
That question is not PVE specific. Normally you need to install a non-pv kernel, grub settings and copy over the files. What script is this?

The migration would be much easier if you just rsync the (offline) machine directly into an LX(C) container of the same OS with --delete rsync option, Containers don't need all the kernel and bootloader stuff that is not as easy as installing something like you would suggest.
 
Normally you need to install a non-pv kernel
Since we are here, and if you can, how would I install this non-pv kernel?


What script is this?
https://github.com/guestisp/xen-to-pve

The migration would be much easier if you just rsync the (offline) machine directly into an LX(C) container of the same OS with --delete rsync option, Containers don't need all the kernel and bootloader stuff that is not as easy as installing something like you would suggest.
Do you have a howto?
 
Since we are here, and if you can, how would I install this non-pv kernel?
Depends on your guest OS.

There is no bootloader stuff in there, so your imported container will boot if your guest OS has a bootloader, which is optional in XEN.

Do you have a howto?
https://pve.proxmox.com/wiki/Additi...Proxmox_VE#Physical_Linux_server_to_Container

And please also read this.
 
There is no bootloader stuff in there, so your imported container will boot if your guest OS has a bootloader, which is optional in XEN.
I installed the grub via boot-repair-disk, but gets stuck in the message "booting from hard disk".

I also did the procedure via xenmigrate.py and the same problem occurred.
 
I recommend booting via live cd, try to fix grub from a chroot there and boot again. Most problems I got with XEN (last migration was over 5y ago), were fairly easy to fix in a live system.
 
Can you post what you did (exact commands including output in CODE tags) and the actual screengrab of the error in Grub? What about the VM config file (precisely: UEFI or legacy). How does /boot look like and what OS you're using.
 
Commands:
Bash:
sudo mount /dev/sda1 /mnt
sudo mount --bind /dev /mnt/dev/
sudo mount --bind /dev/pts /mnt/dev/pts
sudo mount --bind /proc /mnt/proc
sudo mount --bind /sys /mnt/sys
sudo chroot /mnt
grub-install /dev/sda
grub-install --recheck /dev/sda
update-grub
exit
sudo umount /mnt/sys
sudo umount /mnt/proc
sudo umount /mnt/dev/pts


screenshot
1659371145112.png

vm config:
legacy and debian 10

/boot
1659374345207.png

installing grub
1659374542606.png
 

Attachments

  • 1659374253152.png
    1659374253152.png
    38.7 KB · Views: 11
Thank you, now please post the contents of the file /etc/pve/qemu-server/102.conf on your PVE host?
Code:
root@pve1:~# cat /etc/pve/qemu-server/102.conf
boot: order=scsi1;ide2
cores: 2
ide2: local:iso/boot-repair-disk-64bit.iso,media=cdrom,size=880M
memory: 4096
name: fileserver
net0: virtio=6A:89:75:C9:F4:80,bridge=vmbr0,firewall=1,tag=26
numa: 0
ostype: l26
scsi1: pool-zfs-pve:vm-102-disk-1,size=30G
scsihw: virtio-scsi-pci
smbios1: uuid=86a7ca92-4d91-40fb-a909-560537b5fdd8
sockets: 2
vmgenid: cbcb9506-ca1f-4d59-ad92-bd8420285a94
 
Okay, thank you. That looks correct.

Could you please also post fdisk -l /dev/sda from inside your rescue system? Maybe you need to have a dedicated boot partition? I'm unsure about the current restriction in legacy booting from a non-dedicated boot disk. It should not matter anymore ...
 
  • Like
Reactions: empbilly
Could you please also post fdisk -l /dev/sda from inside your rescue system?
1659445882929.png

/etc/fstab

1659446196340.png


Another thing I did, was to change the VM on the xenserver from PV to HVM by installing grub directly on it before the migration. I did tests and the boot worked correctly.

Now I don't understand why it doesn't work in pve.
 
Last edited:
Another thing I did, was to change the VM on the xenserver from PV to HVM by installing grub directly on it before the migration. I did tests and the boot worked correctly.
That's good to know.

I don't know if you still need this, but "in ancient times", you needed the boot flag in the partition that has your grub. Can you add it? Something like fdisk /dev/sda, a, 1, w IIRC
 
  • Like
Reactions: empbilly
I don't know if you still need this, but "in ancient times", you needed the boot flag in the partition that has your grub. Can you add it? Something like fdisk /dev/sda, a, 1, w IIRC
1659447423246.png

I made the modification, rebooted, and it still locks up on the message.

What a crazy thing !!!
 
1659448370504.png

It looked like the picture above.

I removed the console=hvc0 and ran an update-grub

wow, is that the problem all this time?

now it seems to be booting up...

1659448966368.png
 
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!