Skip to content

Instantly share code, notes, and snippets.

@jcpowermac
Created January 31, 2017 20:59
Show Gist options
  • Select an option

  • Save jcpowermac/86ac90bac402bd2d04059698a0ea7ed6 to your computer and use it in GitHub Desktop.

Select an option

Save jcpowermac/86ac90bac402bd2d04059698a0ea7ed6 to your computer and use it in GitHub Desktop.
virsh net-update example openvswitch (ovs) portgroup
virsh net-update ovsbr0 add --section portgroup --xml "<portgroup name='trunk'><vlan trunk='yes'><tag id='2970'/><tag id='2971'/></vlan></portgroup>" --config --live
virsh net-update ovsbr0 add --section portgroup --xml "<portgroup name='vlan-2979'><vlan><tag id='2979'/></vlan></portgroup>" --config --live
@eddycastillon
Copy link
Copy Markdown

eddycastillon commented Mar 30, 2020

In case someone wants to update a whole section, the below command will be helpful. This will override the whole section, so it is important define again the previously created tags.

virsh net-update ovs-network modify --section portgroup --xml "<portgroup name='vlan-all' default='yes'><vlan trunk='yes'><tag id='98'/><tag id='104'/><tag id='105'/> \ <tag id='106'/><tag id='107'/><tag id='230'/><tag id='231'/><tag id='232'/><tag id='233'/>\ </vlan></portgroup>" --config --live

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment