Since vCenter doesn't allow to create VMs with same name, vcenter
nova-compute driver uses uuid as vm-name (to provide unique name).
When openStack creates VM on Contrail ApiServer, it sets display_name to UUID.
When vCenterPlugin does AddPort to vRouterAgent, it needs to passes
vm-name as uuid and that's what shows up Contrail WebUI.
Solution is for vcnetr nova-compute driver to set annotation field in
VM config to VM-name while creating VM.
Contrail vcenter-plugin will read annotation field if VM's name is it's
uuid and use it during AddPort.
Reviewed: https:/ /review. opencontrail. org/18554 github. org/Juniper/ nova/commit/ d9332a27b5c783a 58d8822f6dcb573 199c4c08ce juno_2014_ 2_3
Committed: http://
Submitter: Zuul
Branch: contrail/
commit d9332a27b5c783a 58d8822f6dcb573 199c4c08ce
Author: Sachchidanand Vaidya <email address hidden>
Date: Fri Mar 18 22:02:29 2016 -0700
Since vCenter doesn't allow to create VMs with same name, vcenter
nova-compute driver uses uuid as vm-name (to provide unique name).
When openStack creates VM on Contrail ApiServer, it sets display_name to UUID.
When vCenterPlugin does AddPort to vRouterAgent, it needs to passes
vm-name as uuid and that's what shows up Contrail WebUI.
Solution is for vcnetr nova-compute driver to set annotation field in
VM config to VM-name while creating VM.
Contrail vcenter-plugin will read annotation field if VM's name is it's
uuid and use it during AddPort.
Partial-Bug: #1559387
Change-Id: I6d465d35a49c29 fab32971688ce88 a94589c9987