0

I have 2 ethernet ports bridged as follows (/etc/network/interfaces.d/br0):

auto br0
iface br0 inet dhcp
        bridge_ports enp1s0 enp2s0
        bridge_fd 0
        bridge_waitport 0
        bridge_stp off

auto br0:1
iface br0:1 inet static
        address 169.254.10.50
        netmask 255.255.255.0

In this instance, a PC and router are always in a combined unit. The router has DHCP enabled, but takes longer to boot than the PC.

enp1s0 is in LAN port of the router, enp2s0 is connected to another device that will ALWAYS have an IP address of 169.254.10.49.

When the combined unit is rebooted, if the router does not finish its boot process before the PC has booted, br0 will never be assigned an IP address.

What I need to happen, ideally, is that at any point after the system has booted, if a DHCP server is available, br0 will be assigned an IP address.

Can I configure the bridge to get an IP address after the DHCP server becomes available?

6
  • Can you add to your question in a single sentence in plain English without any technical terms what you're trying to accomplish because this looks like an XY problem... Commented Nov 14, 2022 at 21:17
  • 1
    @Fabby - Edited the question at the bottom to be clearer. Commented Nov 14, 2022 at 21:20
  • I can see what you're trying to do, but I can still not understand why you're trying to do this... Just trying to understand why so I might throw in a solution that accomplishes what you need instead of what you want... Commented Nov 14, 2022 at 21:24
  • 1
    @Fabby - These combined units are for driving LED signage panels. They contain a PC, 4G router & a "sender card". The sender card always has the 169.254.10.49 address. The PC has 2 ethernet ports that we bridge, to allow communication to the sender card without logging in to the PC (via iptables rules). This part works fine. But the length of time it takes for the 4G router to boot if the entire unit is rebooted, means that br0 won't get it's correct IP address from the router. That's the part I want to solve. Commented Nov 14, 2022 at 21:43
  • My apologies, I still don't understand what you're trying to accomplish, so I'm just going to throw this one out there: Can you reserve an IP address on the router using the MAC address and add that reserved IP as a static IP on br0 so both NICs have a static IP and when the DHCP server comes on-line it'll always hand out that IP and stuff just starts communicating??? Commented Nov 15, 2022 at 16:28

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.