Server Virtualization

Welcome to the Nutanix NEXT community. To get started please read our short welcome post. Thanks!

cancel
Showing results for 
Search instead for 
Did you mean: 

Change VM NIC Mac Address Acropolis

Trailblazer

Change VM NIC Mac Address Acropolis

Hi all,

 

I have a requirement with one of our migrated servers to retain its original MAC Address due to licensing.

 

I've migrated the machine only to find these requirements post migration, so the Question is how can I change the VM MAC address?

 

Thanks,

 

Stephen...

6 REPLIES
Trailblazer

Re: Change VM NIC Mac Address Acropolis

I believe this can be changed in the XML config for the VM 

 

 <interface type='network'>
 <mac address='52:54:00:be:99:b3'/>
 <source network='NTNX-Local-Network'/>
 <model type='virtio'/>
 <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
 </interface> 

 

Moderator Moderator
Moderator

Re: Change VM NIC Mac Address Acropolis

Do not edit the local XML directly, as this is all controlled by Acropolis. Editing the local XML will just result in that being erased somewhere down the line.

 

Think of the local XML as ephemeral, which is fantastic, as its all managed in a distributed fashion within the cluster.

 

Anyhow, this is done via acli vm.nic_create

 

Syntax is documented here: 

https://portal.nutanix.com/#/page/docs/details?targetId=AMF_Guide-Acr_v4_6:man_acli_vm_auto_r.html

 

Jon Kohler | Principal Architect, Nutanix | Nutanix NPX #003, VCDX #116 | @JonKohler
Please Kudos if useful!
Trailblazer

Re: Change VM NIC Mac Address Acropolis

Thanks Jon. was not aware Smiley Happy 

Trailblazer

Re: Change VM NIC Mac Address Acropolis

many thanks that sorted it

Trendsetter

Re: Change VM NIC Mac Address Acropolis

Is this document available for CE only users?

 

William

Moderator Moderator
Moderator

Re: Change VM NIC Mac Address Acropolis

No, as thats a commercial product doc.

 

But, its all the same as the in-built help, as we use that man page to generate the online documentation

 

acli help vm.nic_create should get you a lot of good info.

 

Either way, heres the contents on creating a NIC with a specific MAC

 

<acropolis> vm.nic_create vm [ip="ip_addr" ] [mac="mac_addr" ] [model="model" ] [network="network" ] [request_ip="{ true | false }" ] [trunked_networks="networks" ] [vlan_mode="vlan_mode" ]  
Jon Kohler | Principal Architect, Nutanix | Nutanix NPX #003, VCDX #116 | @JonKohler
Please Kudos if useful!