Skip to content

Commit d253552

Browse files
committed
[stable-only][OVN] Set VETH interface MAC address before up
Set the VETH interface MAC address of the metadata namespace before setting this interface as up. This change was introduced in [1] and should be backported to stable versions. [1]https://review.opendev.org/c/openstack/neutron/+/894026/12/neutron/agent/ovn/metadata/agent.py#710 Closes-Bug: #2055561 Change-Id: Ied8f7a5b6c0e9c295e8e040546c53bd98206ef12 (cherry picked from commit ac63999)
1 parent efb504f commit d253552

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

neutron/agent/ovn/metadata/agent.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -586,13 +586,13 @@ def provision_datapath(self, datapath):
586586
ip1, ip2 = ip_lib.IPWrapper().add_veth(
587587
veth_name[0], veth_name[1], namespace)
588588

589+
# Configure the MAC address.
590+
ip2.link.set_address(metadata_port_info.mac)
591+
589592
# Make sure both ends of the VETH are up
590593
ip1.link.set_up()
591594
ip2.link.set_up()
592595

593-
# Configure the MAC address.
594-
ip2.link.set_address(metadata_port_info.mac)
595-
596596
cidrs_to_add, cidrs_to_delete = self._process_cidrs(
597597
{dev['cidr'] for dev in ip2.addr.list()},
598598
datapath_ports_ips,

0 commit comments

Comments
 (0)