how to make sure bridge interface is up with netplan after reboot

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

how to make sure bridge interface is up with netplan after reboot

Ubuntu mailing list
Hello,

I am using Ubuntu 17.10 and therefore Netplan which I have configured a bridge for a specific network interface for my Xen virtual machines. Unfortunately when I reboot the server that bridge interface is in state DOWN so that I have to manually set it up using "ip link set xenbr1 up" command. Now does anyone know how to make sure netplan brings my bridge interface automatically up at reboot?

Here is the relevant part of my netplan netcfg.yaml file:

network:
  version: 2
  renderer: networkd
  ethernets:
    eno3:
      dhcp4: no
  bridges:
    xenbr1:
      interfaces: [eno3]
      dhcp4: no
      parameters:
        stp: no
        forward-delay: 0

Regards,
M.

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: how to make sure bridge interface is up with netplan after reboot

Tom H
On Fri, Mar 9, 2018 at 10:34 AM, mabi via ubuntu-users
<[hidden email]> wrote:

>
> I am using Ubuntu 17.10 and therefore Netplan which I have configured
> a bridge for a specific network interface for my Xen virtual machines.
> Unfortunately when I reboot the server that bridge interface is in
> state DOWN so that I have to manually set it up using "ip link set
> xenbr1 up" command. Now does anyone know how to make sure netplan
> brings my bridge interface automatically up at reboot?
>
> Here is the relevant part of my netplan netcfg.yaml file:
>
> network:
>   version: 2
>   renderer: networkd
>   ethernets:
>     eno3:
>       dhcp4: no
>   bridges:
>     xenbr1:
>       interfaces: [eno3]
>       dhcp4: no
>       parameters:
>         stp: no
>         forward-delay: 0

You have "dhcp4: no" and no "addresses:" defined so I wouldn't expect
xenbr1 to be "UP".

What do the "*.network" files in "/run/systemd/" contain?

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: how to make sure bridge interface is up with netplan after reboot

Ubuntu mailing list
That's correct I have no IP addresses defined on my xenbr1 bridge because it is just a bridge between my Xen virtual machines which are hooked up to this bridge and a hardware firewall which is connected onto the eno3 physical NIC. Both VM and firewall have an IP address but not the bridge. So it looks like this:

[VM(eth0)]-----[(xenbr1)XenHypervisor(eno3)]-----[(eth0)Firewall(eth1)]-----[Internet]

As far as I am concerned the xenbr1 bridge interface on my Xen hypervisor does not need any IP address, there is no purpose for it having an IP address.

In the /run/systemd/network directory there is no xenbr1.network file but there is a eno3.network file with the following content:

[Match]
Name=eno3

[Network]
Bridge=xenbr1
LinkLocalAddressing=no
IPv6AcceptRA=no



‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐

On March 9, 2018 7:19 PM, Tom H <[hidden email]> wrote:

> ​​
>
> On Fri, Mar 9, 2018 at 10:34 AM, mabi via ubuntu-users
>
> [hidden email] wrote:
>
> > I am using Ubuntu 17.10 and therefore Netplan which I have configured
> >
> > a bridge for a specific network interface for my Xen virtual machines.
> >
> > Unfortunately when I reboot the server that bridge interface is in
> >
> > state DOWN so that I have to manually set it up using "ip link set
> >
> > xenbr1 up" command. Now does anyone know how to make sure netplan
> >
> > brings my bridge interface automatically up at reboot?
> >
> > Here is the relevant part of my netplan netcfg.yaml file:
> >
> > network:
> >
> > version: 2
> >
> > renderer: networkd
> >
> > ethernets:
> >
> > eno3:
> >
> > dhcp4: no
> >
> > bridges:
> >
> > xenbr1:
> >
> > interfaces: \[eno3\]
> >
> > dhcp4: no
> >
> > parameters:
> >
> > stp: no
> >
> > forward-delay: 0
>
> You have "dhcp4: no" and no "addresses:" defined so I wouldn't expect
>
> xenbr1 to be "UP".
>
> What do the "*.network" files in "/run/systemd/" contain?
>
>
> --------------------------------------------------------------------------------------------------------------------------------------------------------
>
> ubuntu-users mailing list
>
> [hidden email]
>
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users



--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: how to make sure bridge interface is up with netplan after reboot

Tom H
On Fri, Mar 9, 2018 at 3:59 PM, mabi via ubuntu-users
<[hidden email]> wrote:

> On March 9, 2018 7:19 PM, Tom H <[hidden email]> wrote:
>> On Fri, Mar 9, 2018 at 10:34 AM, mabi via ubuntu-users
>> [hidden email] wrote:
>>>
>>> I am using Ubuntu 17.10 and therefore Netplan which I have configured
>>>
>>> a bridge for a specific network interface for my Xen virtual machines.
>>>
>>> Unfortunately when I reboot the server that bridge interface is in
>>>
>>> state DOWN so that I have to manually set it up using "ip link set
>>>
>>> xenbr1 up" command. Now does anyone know how to make sure netplan
>>>
>>> brings my bridge interface automatically up at reboot?
>>>
>>> Here is the relevant part of my netplan netcfg.yaml file:
>>>
>>> network:
>>> version: 2
>>> renderer: networkd
>>> ethernets:
>>> eno3:
>>> dhcp4: no
>>> bridges:
>>> xenbr1:
>>> interfaces: \[eno3\]
>>> dhcp4: no
>>> parameters:
>>> stp: no
>>> forward-delay: 0
>>
>> You have "dhcp4: no" and no "addresses:" defined so I wouldn't expect
>> xenbr1 to be "UP".
>>
>> What do the "*.network" files in "/run/systemd/" contain?
>
> That's correct I have no IP addresses defined on my xenbr1 bridge
> because it is just a bridge between my Xen virtual machines which are
> hooked up to this bridge and a hardware firewall which is connected
> onto the eno3 physical NIC. Both VM and firewall have an IP address
> but not the bridge. So it looks like this:
>
> [VM(eth0)]-----[(xenbr1)XenHypervisor(eno3)]-----[(eth0)Firewall(eth1)]-----[Internet]
>
> As far as I am concerned the xenbr1 bridge interface on my Xen
> hypervisor does not need any IP address, there is no purpose for it
> having an IP address.
>
> In the /run/systemd/network directory there is no xenbr1.network file
> but there is a eno3.network file with the following content:
>
> [Match]
> Name=eno3
>
> [Network]
> Bridge=xenbr1
> LinkLocalAddressing=no
> IPv6AcceptRA=no

If you assign "0.0.0.0/0" to xenbr1, there should be a xenbr1
".network" file in "/run/systemd/network/" to go with the xenbr1
".netdev" one and xenbr1'll be brought up. Untested, so I hope!

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: how to make sure bridge interface is up with netplan after reboot

Ubuntu mailing list
On March 10, 2018 12:48 AM, Tom H <[hidden email]> wrote:


> If you assign "0.0.0.0/0" to xenbr1, there should be a xenbr1
>
> ".network" file in "/run/systemd/network/" to go with the xenbr1
>
> ".netdev" one and xenbr1'll be brought up. Untested, so I hope!

Using 0.0.0.0/0 did not work but I used 0.0.0.0/32 instead and it worked. My xenbr1 interface is then automatically in the UP state at reboot. Thanks for the tip!

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: how to make sure bridge interface is up with netplan after reboot

Tom H
On Mon, Mar 12, 2018 at 8:56 AM, mabi via ubuntu-users
<[hidden email]> wrote:
> On March 10, 2018 12:48 AM, Tom H <[hidden email]> wrote:


>> If you assign "0.0.0.0/0" to xenbr1, there should be a xenbr1
>> ".network" file in "/run/systemd/network/" to go with the xenbr1
>> ".netdev" one and xenbr1'll be brought up. Untested, so I hope!
>
> Using 0.0.0.0/0 did not work but I used 0.0.0.0/32 instead and it
> worked. My xenbr1 interface is then automatically in the UP state at
> reboot.

Good :)


> Thanks for the tip!

It was more of an educated guess!

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users