:_mod-docs-content-type: ASSEMBLY
[id="virt-hot-swap-vm-secondary-network"]
= Hot swapping a virtual machine secondary network
include::_attributes/common-attributes.adoc[]
:context: virt-hot-swap-vm-secondary-network

toc::[]    

[role="_abstract"]
You can change the secondary network of a virtual machine (VM) without rebooting your VM. The change is transparent to the guest operating system, preserving properties such as the MAC address. 

By hot swapping the secondary network, you can move a running VM to a different network segment or VLAN and apply new network policies or reconfigure network topology without interrupting the workload. {VirtProductName} supports hot swapping for VMs that are connected to an OVN-Kubernetes localnet and a Linux bridge secondary network.

To hot swap a VM secondary network, you must edit the network configuration of the running VM to refer to a new `NetworkAttachmentDefinition` or `ClusterUserDefinedNetwork` manifest. This action triggers a live migration, connecting the VM to the new network without a reboot.

include::modules/virt-vm-nw-hot-swap-limitations.adoc[leveloffset=+1]

include::modules/virt-live-updating-vm-nad-udn.adoc[leveloffset=+1]

include::modules/virt-hot-swapping-vm-secondary-network-web-console.adoc[leveloffset=+1]


[role="_additional-resources"]
[id="additional-resources_{context}"]
== Additional resources
* xref:../../virt/live_migration/virt-about-live-migration.adoc#virt-about-live-migration-permissions_virt-about-live-migration[About live migration]
* xref:../../virt/vm_networking/virt-connecting-vm-to-secondary-udn.adoc#virt-connecting-vm-to-secondary-udn[Connecting a virtual machine to a secondary localnet user-defined network]
* xref:../../virt/vm_networking/virt-connecting-vm-to-linux-bridge.adoc#virt-connecting-vm-to-linux-bridge[Creating a Linux bridge network attachment definition]
* xref:../../virt/vm_networking/virt-connecting-vm-to-sriov.adoc#nw-sriov-additional-network_virt-connecting-vm-to-sriov[Creating an SR-IOV network attachment definition]