Skip to main content

Change a VM network

Remove:

xe vm-list
Copy the uuid for the VM you want to remove the interface.
xe vif-list vm-uuid=<vm-uuid>
Copy the uuid for the vif you want to destroy.
xe vif-destroy uuid=<vif-uuid>
Note you will need to know which device you want to remove if there is more than one interface attached to the VM.
Add:

xe list-network (you can add "name-label=<label>" )
Copy the networks uuid.
xe vif-create network-uuid=<network-uuid> vm-uuid=<vm-uuid> device=0

More