On 10/12/23 14:58, Xuo Guoto via discuss wrote:
> Hello all,
>
> I am trying to bond two interfaces connecting my running VM with OVS.
>
> I have a bridge ovsbr-lacp0 with 7 virtio interfaces connected to two VMs, 6
> in VM1 and one in VM2.
>
> # ovs-vsctl list-ifaces ovsbr-lacp0
> vnet72
> vnet74
> vnet75
> vnet76
> vnet77
> vnet78
> vnet79
>
> # ovs-vsctl -f table --columns=name,external_id list interface | grep
> 274ce169-b166-45dc-ba1d-7faa8fea3673
> vnet75 {attached-mac="52:54:00:0d:61:fc", iface-id="..",
> iface-status=active, vm-id=".."}
> vnet78 {attached-mac="52:54:00:24:36:a7", iface-id="..",
> iface-status=active, vm-id=".."}
> vnet79 {attached-mac="52:54:00:c7:90:3c", iface-id="..",
> iface-status=active, vm-id=".."}
> vnet77 {attached-mac="52:54:00:79:8e:a0", iface-id="..",
> iface-status=active, vm-id=".."}
> vnet74 {attached-mac="52:54:00:aa:fb:bb", iface-id="..",
> iface-status=active, vm-id=".."}
> vnet76 {attached-mac="52:54:00:d4:cc:88", iface-id="..",
> iface-status=active, vm-id=".."}
>
> Where 274ce169-b166-45dc-ba1d-7faa8fea3673 is the UUID of VM1
>
> # sudo ovs-vsctl -f table --columns=name,external_id list interface | grep
> 2075bff5-ee89-492e-b50c-36bd3b92b662
> vnet72 {attached-mac="52:54:00:fd:fe:f6", iface-id="..",
> iface-status=active, vm-id=".."}
>
> and 2075bff5-ee89-492e-b50c-36bd3b92b662 is the UUID of VM2. I have removed
> the iface-id and vm-id so that the output is easy to read.
>
> Now I want to configure bonding for all the interface in VM1.
>
> # ovs-vsctl add-bond ovsbr-lacp0 bond0 vnet75 vnet78 lacp=active
> ovs-vsctl: cannot create an interface named vnet75 because a port named
> vnet75 already exists on bridge ovsbr-lacp0
>
> # ovs-vsctl --may-exist add-bond ovsbr-lacp0 bond0 vnet75 vnet78 lacp=active
> ovs-vsctl: cannot create an interface named vnet75 because a port named
> vnet75 already exists on bridge ovsbr-lacp0
>
> I am guessing I am doing some thing wrong, but not able to figure out what.
> Any help to get this working will be much appreciated.
'add-bond' command creates a 'port' with two or more 'interfaces'.
These interfaces are created as part of the port creation. So,
"add-bond ovsbr-lacp0 bond0 vnet75 vnet78" creates a 'port' named
bond0, creates two interfaces vnet75 and vnet78, and adds them into
a port. But interfaces vnet75 and vnet78 already exist, so the
command fails. The 'may-exist' flag only check for existence of
the port, not interfaces in it.
You currently have port vnet75 with an interface vnet75, and the
port vnet78 with interface vnet78. But you want a port bond0
with interfaces vnet75 and vnet78. In order to achieve that you
need to remove ports vnet75 and vnet78 first, and then create
a port bond0.
HTH
Best regards, Ilya Maximets.
_______________________________________________
discuss mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-discuss