HOW TO CREATE AN AHV VIRTUAL SWITCH WITH SINGLE UPLINK.
Explanation:
Bridges is same as virtual switches in VMware terminology to manage network traffic between physical and virtual network interfaces. The default AHV configuration active-backup includes an OVS bridge called br0 and an open source Linux bridge called virbr0. The virbr0 Linux bridge carries management and storage traffic between the Controller Virtual Machine (CVM) and acropolis Hypervisor (AHV) host. All other storage, host, and VM network traffic flows through the br0 OVS bridge. In dev or test environments where redundancy is not mattered on AHV, you may want to create bridges with a single uplink. When multiple uplinks are used they are added to bond acting as a single logical interface, to which bridge is connected. Open vSwitch (OVS) does not support bonds with single uplink as of now and there is a workaround than we have to directly connect bridge to single uplink.
Solution:
Enable 10GbE links only on OVS
nutanix@Prod-cvm1:~$ manage_ovs --interfaces 10g update_uplinks nutanix@Prod-cvm1:~$ manage_ovs show_uplinks
To see the uplinks of all nodes
nutanix@Prod-cvm1:~$ allssh "manage_ovs --interfaces 10g update_uplinks" nutanix@Prod-cvm1:~$ allssh "manage_ovs show_uplinks"
WARNING: On clusters running any AOS version between 5.10 and 5.10.3.2 DO NOT run “update_uplinks” with single interface specified on the interfaces .
If you have node with single interface in a bridge or want to create one please upgrade AOS to 5.10.4 or newer before making any changes or engage Nutanix Support
WARNING: Updating uplinks using “manage_ovs” will delete and recreate the bond with default configuration.
Consider the following before updating uplinks:
- Make host in maintenance mode before performing this activity.
- If you are using active-backup load balancing mode then uplink update can cause short network disconnect.
- If balance-slb or balance-tcp (LACP) load balancing mode is used on AHV uplink update will reset configuration to active-passive.
It is strongly recommended to perform changes on single node at the time after making sure that cluster can tolerate node failure.
Follow the post of cluster health that describes how to check if cluster can tolerate node failure.
Dont use “allssh manage_ovs update_uplinks” command from CVM that may lead to a cluster outage and critical alerts.
Only use it if cluster is not in production and has no user guest VMs running(Be careful).
To update bridge to single uplink please run following command on any CVM:
nutanix@Prod-cvm1:~$ manage_ovs --bridge_name br1 --interfaces eth1 update_uplinks
Manage_ovs willshow report bond with same name as interface in show_uplinks output:
nutanix@Prod-cvm1:~$ manage_ovs show_uplinks Bridge: br0 Bond: eth3 bond_mode: active-backup interfaces: eth3 lacp: off lacp-fallback: false lacp_speed: slow
“ovs-appctl bond/list” will not be showing any bonds:
root@ahvhost# ovs-appctl bond/list bond type recircID slaves root@ahvhost#
"ovs-vsctl show" will show that br0 is using eth3 interface:
[root@ahvhost ~]# ovs-vsctl show ... Bridge "br0" ... Port "eth3" Interface "eth3" ...
For comparison, here is how “ovs-vsctl show” on AHV output looks like when there are 2 or more uplinks in bond:
[root@ahvhost ~]# ovs-vsctl show Bridge "br0" ... Port "br0-up" Interface "eth3" Interface "eth4"
See also :- AHV Host and Guest VMs Networking for Nutanix