Solved

Cloned VM and source VM power on


Badge

Hi Everyone,

In case of scenario like had a Source VM (name:TestVM) and cloned a new VM from the source VM and named cloned VM (name: TestVM) same as Source VM (name:TestVM). Now will i be able to poweron both the VM’s at once ? 

icon

Best answer by Kcmount 16 May 2024, 14:27

View original

12 replies

Userlevel 6
Badge +8

Yes you can. 

Userlevel 4
Badge +7

Hi there,

Yes you can do that no problem from Nutanix perspective but if its Windows it might get upset having two VMs pretending to be TestVM on the network.

 

Badge

Yes you can. 

Why and How Nutanix is allowing to create a multiple VM’s with same name?  In case of VMWare staright away it gives an error VM already exist if we use same name for multiple VM’s..

Userlevel 4
Badge +7

VMware won’t give you an error if the inside VM hostname is the same it doesn’t care - same as Nutanix doesn’t care.

 

// EDIT //

Nutanix nor VMware will let you name the VM inside the Virtualisation platform with the same name because that would indeed be a duplicate.

 

// EDIT // Proven incorrect in testing - Nutanix is unique here //

 

Within the guest OS isn’t VMware or Nutanix’s decision what you do with your guest OS.

Badge

Hi there,

Yes you can do that no problem from Nutanix perspective but if its Windows it might get upset having two VMs pretending to be TestVM on the network.

 

Yes, our customer is cloning windows2019 VM from source VM having same name. both the VM’s have different uuids due to this my script is failing which one it should pick for backup.

Userlevel 4
Badge +7

Hi there,

 

Yep, they will have different uuids because they are different VMs.

Even if 1 is a clone of the other, as soon as the second one is powered on it will deviate ‘away’ from the identical copy of the original one.

What is your script doing/looking for?

 

Badge

VMware won’t give you an error if the inside VM hostname is the same it doesn’t care - same as Nutanix doesn’t care.

 

Nutanix nor VMware will let you name the VM inside the Virtualisation platform with the same name because that would indeed be a duplicate.

 

Within the guest OS isn’t VMware or Nutanix’s decision what you do with your guest OS.

Yes i know VM hostname is same any vendor didn’t care but in Nutanix prism central its allowing duplicate name for multiple VM’s thats my issue.

Badge

Hi there,

 

Yep, they will have different uuids because they are different VMs.

Even if 1 is a clone of the other, as soon as the second one is powered on it will deviate ‘away’ from the identical copy of the original one.

What is your script doing/looking for?

 

Customer will give you a list of VM’s and script will use that list and will take backup. scenario here is 1 source VM and 3 cloned VM’s have same name when customer passed the VM list of one VM since name is for all 4 VM’s backup is failing resolving name since it has 4 uuids. If we rename the cloned VM’s to different name and pass 5 names in list all VM’s backup are working fine.

Userlevel 4
Badge +7

Yikes I’m very sorry, my mistake! 

I just created two VMs with the same name you’re right :)

I didn’t think you could do that within a cluster but you’re right.

 

So with my mistake aside, lets try to better understand how to help you.

 

Your script is looking for the ‘name’ e.g. TestVM and its failing because it gets two results for TestVM right?

 

Can your customer not name their VMs properly to avoid it? 

Userlevel 4
Badge +7

Yep our replies overlapped, again my apologies I was totally incorrect - Nutanix is relying on the uuid for uniqueness rather than the label.

Can the customer not name their VMs properly instead?

Badge

Yikes I’m very sorry, my mistake! 

I just created two VMs with the same name you’re right :)

I didn’t think you could do that within a cluster but you’re right.

 

So with my mistake aside, lets try to better understand how to help you.

 

Your script is looking for the ‘name’ e.g. TestVM and its failing because it gets two results for TestVM right?

 

Can your customer not name their VMs properly to avoid it? 

Haha, I informed them to rename to different after clone or during to avoid confusion. But they are asking for solution and not ready to rename don’t know what’s there in their mind. Is there any command or API to get list of UUID’s all VM’s in prism central. I will rewrite script to take UUID’s instead VM names as list to pass for backup.

Userlevel 4
Badge +7

Ah customers :)

From ncli we can run vm list which dumps out all of the VMs with their name/uuid/id that you could put into an array to work out the real VMs from the customer labels maybe?

API should do much the same, what are you writing your script in? 

Reply