I’m trying to use Opennebula to deploy virtual machines on my vSphere.
At the moment everything is good but when a vm is deployed, the name which appears in vShere is for example “one-vmname” and i want to remove the “one-” part.
I already look some configuration file but i did’nt find anything.
If someone already had the same problem and can help me?
You can’t remove that part. OpenNebula uses that prefix to identify all the resources that are managed by it. So it’s applied for vms, networks, etc… And it’s always the same as you said, first the prefix and then the resource name, in your case the name of the VM.
Note: it’s the same for KVM, if you make a list in virsh, you will see that prefix.
Hello again @marceau12
In vCenter you can change the VM_PREFIX here you have more information. So you can set this to the empty string and it will work.
It would be helpful to have this ‘function’ modified so that it is an option for end users to either use it, or not use it.
We are facing the same dilemma with this use case in our environment. host/vm/system names and IP’s are all centrally managed and are required to be consistent and managed upstream.
Introducing a new requirement like this introduces issues with existing operational processes within the established vCenters that are hosting over 5,000 existing VM’s.
I don’t see wild import as an issue , as opennebula would be new to the environment and the hosts can easily be renamed without the ‘wild customization’ during inital setup - but the reverse is not true - introducing new ‘prefix-’ naming convention into VM names will introduce changes to the existing infrastructure vcenter scripts, monitoring, operational processes.
I understand that can be scripted as well after landing in the vCenter, but it would be much simpler to be able to allow upstream processes already responsible for generating host/vm/system names continue to feed this information.
How do you represent an empty string ?
VM_PREFIX = ’ ’ should work.
I tried it but not working! ‘’ become my vm name prefix
Did you try VM_PREFIX = ‘’?
Hi, thank you for your response
Yes I tried it, maybe I’m not doing it well.
I’m under “infrastructure” --> “Hosts” --> vCenter information
I clicked on the + button and added VM_PREFIX then in the second box ‘’
Could you try updating the host using the CLI?
Now working with this syntax VM_PREFIX=" " using the cli.
Thank you for your help
Perfect! So maybe there is a bug in sunstone, could you please open a ticket on GitHub?