michaelmichael
Posts: 6
Joined: Fri Jan 12, 2018 6:06 am

Using both Wlan0 and Eth0 trouble with fixed IP

Tue Jan 16, 2018 10:37 am

Hi all!

i am experiencing this problem - I don't know if it's common but I coulnd't find a solution through search...
I have multiple Pi3s connected to a router via ethernet, but the WLAN is also active, I use it to ssh into the Pis via hostname, the ETH0 is used so they can talk to each other.

So I need a static IP for ETH0 on one of the Pis. As soon as this is activated, I cannot access it through WLAN anymore. I can still ssh into another Pi and then, via ethernet, connect to this one, but it can't be found in the Wifi anymore.

Is there any way around this? Right now it's more a comfort issue, also I don't know too much about network technology, but I feel like this should be an easy one to fix if one knows where to look...?

SurferTim
Posts: 1769
Joined: Sat Sep 14, 2013 9:27 am
Location: Miramar Beach, Florida

Re: Using both Wlan0 and Eth0 trouble with fixed IP

Tue Jan 16, 2018 10:47 am

Not enough info. How did you assign the static settings? What are the settings on the other RPis?

Maybe if you post the output of ifconfig and route somebody may see the problem

Code: Select all

ifconfig
route
Edit: The symptom you describe could be caused by overlapping localnets. The ethernet interface has priority, so if you have both assigned the same localnet, eth0 will be used as the default.

klricks
Posts: 7172
Joined: Sat Jan 12, 2013 3:01 am
Location: Grants Pass, OR, USA
Contact: Website

Re: Using both Wlan0 and Eth0 trouble with fixed IP

Tue Jan 16, 2018 2:18 pm

The easiest way to do this is to use DHCP reservations to MAC address settings in your router. Do not change the settings on the RPi .. Leave them set to DHCP.
Be sure to assign different IPs to WIFI and Ethernet.
Last edited by klricks on Tue Jan 16, 2018 10:32 pm, edited 1 time in total.
Unless specified otherwise my response is based on the latest and fully updated RPiOS Buster w/ Desktop OS.

michaelmichael
Posts: 6
Joined: Fri Jan 12, 2018 6:06 am

Re: Using both Wlan0 and Eth0 trouble with fixed IP

Tue Jan 16, 2018 8:01 pm

SurferTim wrote:
Tue Jan 16, 2018 10:47 am
Not enough info. How did you assign the static settings? What are the settings on the other RPis?

Maybe if you post the output of ifconfig and route somebody may see the problem

Code: Select all

ifconfig
route
Edit: The symptom you describe could be caused by overlapping localnets. The ethernet interface has priority, so if you have both assigned the same localnet, eth0 will be used as the default.
Oops sorry, I totally forgot to put all the crucial info: The pis run on the latest Raspbian stretch release, I set individual host names through raspi-config and the static ip in dhcpcd.conf. That's all. I'll post the ifconfig output as soon as I ca get around to (don't have the pis here)

SurferTim
Posts: 1769
Joined: Sat Sep 14, 2013 9:27 am
Location: Miramar Beach, Florida

Re: Using both Wlan0 and Eth0 trouble with fixed IP

Tue Jan 16, 2018 8:27 pm

No thing. While you are at it, ensure you are not using an IP that has already in use or has been issued by the dhcp server on that network.

Return to “Troubleshooting”