[SOLVED] Qemu-Img Convert 5 qcow2 disks my VM to one vmdk

DmitriyV

New Member
Jun 25, 2024
8
3
3
Dear Colleagues,

I've Proxmox VM with 5 additional disks (vm-118-disk-0.qcow2, vm-118-disk-1.qcow2,vm-118-disk-2.qcow3, vm-118-disk-3.qcow2, vm-118-disk-4.qcow2)
How can I convert it to vmdk (vm118.vmdk) ?

My steps, I tried to use the next command into shell Proxmox 7.2.3 :
1.
qemu-img convert -p -f qcow2 -O vmdk vm-118-disk-0.qcow2 vm-118-disk-1.qcow2 vm-118-disk-2.qcow3 vm-118-disk-3.qcow2 vm-118-disk-4.qcow2 vm118.vmdk

2.
So, after that I used command:

vmkfstools -i vm118.vmdk -d thin vm118new.vmdk

Unfortunately new file vm118new.vmdk ran into VMWare but without additional disks inside.

Please advise and assistance me with this question.

With respect, Dmitriy
 
I'm not aware that qemu-img convert can do that for multiple files to concatenate it into one vmdk file.

What I would do in your case is copy all the data from the 5 drives to a new one (size of the data of first 5), & then convert that single one to vmdk format.
 
If this is time-sensitive, treat the vdisks like you would a physical disk.

Create a single .vmdk disk of appropriate size, format with filesystem, mount the .qcow2 series in a VM and use Midnight Commander or rsync / rclone to copy files over.
 
  • Like
Reactions: DmitriyV
Dear gfngfn256,

Many thank you for suggestions.
But unfortunately I have specific technical requirements for this VM in part internal disks and their sizes (C, D, E, F, G). And in this case I need find the way how make fully copy VM with all disks inside.
I didn't understood while, why qemu-img couldn't made full copy VM with all disks inside.
Maybe do you have additional ideas regarding this issue?

With respect, Dmitriy
 
I don't use/remember VMware; but why not create & convert 5 .vmdk files & then add them in VMware VM settings from "existing hard disk" & add all five.
 
  • Like
Reactions: DmitriyV
If this is time-sensitive, treat the vdisks like you would a physical disk.

Create a single .vmdk disk of appropriate size, format with filesystem, mount the .qcow2 series in a VM and use Midnight Commander or rsync / rclone to copy files over.
Dear Kingneutron,

Many thank you for the sugestion. I'll try to explore documentation about this command rsync/rclone and will do this.

With respect, Dmitriy
 
  • Like
Reactions: Kingneutron
I don't use/remember VMware; but why not create & convert 5 .vmdk files & then add them in VMware VM settings from "existing hard disk" & add all five.
Dear gfngfn256,

Thank you, I'll try to use this way also.

With respect, Dmitriy
 
I don't use/remember VMware; but why not create & convert 5 .vmdk files & then add them in VMware VM settings from "existing hard disk" & add all five.
Dear gfngfn256,

I used the way as you sugest me before and got result!
VM ready, started and work good!

Many Thank You!


With respect, Dmitriy
 
  • Like
Reactions: gfngfn256
Happy you got it working. Maybe tag prefix the thread-title with [SOLVED], (upper right hand corner under title).
 
Dear gfngfn256,

Yes, sure.
I've changed the tag on status Solved, I hope its right.

Thank You once more!


With respect, Dmitriy
 

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!