Rpi CM4 - Red interface not available after reboot

After installing on Rpi CM4 8gb lite, I reboot and my NIC is not available for Red. If I go into setup and remove and add it works again. How can I fix this on boot?

Network Cards

A work-around, more than a fix, is to swap the card assignments for Red & Green. An onboard NIC gets found and setup more quickly and reliably. That enables the boot process to proceed without errors and Green should eventually get found and initiated.

Looks like the mac address of the realtek is random. (Bit2 in the first byte is set which means self assigned) so it changes at every reboot.

The easiest way to get this working is a hack:
echo RED_DEV=eth0 >> /var/ipfire/ethernet/settings

2 Likes

@rodneyp I did attempt this but then Green was not found.

@arne_f You are the awesome, adding that config fixed the issue. Any chance of updates impacting this setting in the future?

Im not sure but im using the same trick with my Android Phone.

Ok, got everything working but then found out that my ISP requires IPv6 and IPFire does not support it. Are there any workarounds to solve red getting an IP address?

That sounds odd. What is the manufacturer and model # of the gateway??


Currently an Arris SB6141, I have pfsense running on another box and I am able to pull an IP with that. Not sure what is going on with IPFire. I honestly might start over again just to make sure I have not inadvertently ran some command I shouldn’t have trying to get it working.

I have a Arris SB6183. You should easily get an IPv4 address.

Sometimes the MAC address gets locked to the old address (the old firewall) and the modem needs to grab a new MAC address from the IPFire device.

Try powering down the modem and IPFire. And then power up the modem first (wait about 1 minute to 1.5 minutes) and then power up the IPFire box.

Yeah, still didn’t work, waited a considerable amount of time with modem off, then waited about 5 more minutes and powered the IPFire, nothing. Plugged my PFSense box back in and it pulled an IP no problem.

Plug the RPI CM4 Router board back in behind PFSense and I get an IP from the PFSense on red/eth0 without any issues. I am truly lost now.

Okay, I went back to the drawing board, reconfigured both NICs with setup, swapped ports (which I have done before), set green to eth0, and commented out the following in /var/ipfire/dhcpc/dhcpcd.conf and it worked.

I now think I have a functional Raspberry Pi 4 Compute Module 8gb lite, PI52-Router board, functional!

# A ServerID is required by RFC2131.
#require dhcp_server_identifier
1 Like

Hello,
this actually more a “hack” than a permanent solution.
I got it working by assigning a custom MAC to the NIC with udev everytime the CM4 gets powered up.
It’s documentated here: fixes.brecht-schule.hamburg/linux/linux-tutorials/set-persistent-mac-rtl8111 Maybe this will help someone in future.

Best regards

2 Likes