-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Launch Multiple VMs from a datavolume [Windows] #2
Comments
First, this repo is a bit out of date, it was originally designed for using gitops to create VMs on a cluster. Second, DataVolumes are also (while still supported) being deprecated in favor of PVCs with populators. You can read more at the KubeVirt docs at https://kubevirt.io/user-guide/virtual_machines/disks_and_volumes/ Now to answer the questions you had: You can create multiple isolated VMs using the same data volume through two ways: First, you can create a new data volume for the new vm that uses the existing data volume as its source. This will, when created, set up a clone operation and copy the original PVC to a new one in the VM's namespace. Second, you can create your VM with a dataVolumeTemplate entry. Basically this embeds a DataVolume into your VM's definition, and if the PVC the VM needs does not exist, it will be created by CDI before starting the VM. As for the other question, multiple disks work fine in VMs, double-check the PVC exists, is bound to a PV, and is being bound by the virt-launcher Pod when the VM starts. Look for any errors in those three locations. |
Here's another helpful link on import populators: https://github.com/kubevirt/containerized-data-importer/blob/main/doc/cdi-populators.md |
Thanks @cwilkers and @baromm14 I think creating a MasterCopy of Image and Launching individual VMs by cloning MasterCopy make sense. |
Hi,
I create a datavolume and created a VM
Now when i created another VM windowsvm2 using the same datavolume, i could see the files created by the windowsvm in windowsvm.
My question is how to create multiple isolated VMs using the same data volume.
My another question is even if i add another disk it is not visible in the Windows VM.
The text was updated successfully, but these errors were encountered: