8

I am trying to connect a web power switch v7 to rpi through the ethernet jack, and then connect the rpi to the internet through usb wifi.

I looked at several QA, including this well voted one: Setting up WiFi and Ethernet

It works, but only if I first start with only the wifi dongle connected, then manually plug in the ethernet cable.

If I start with both plugged in, and reboot, only the ethernet works. The wifi dongle light turns off. My concern is power failures.

What is happening here?

My settings are pretty much lifted from various posts:

/etc/default/ifplugd INTERFACES="eth0" HOTPLUG_INTERFACES="eth0" ARGS="-q -f -u0 -d10 -w -I" SUSPEND_ACTION="stop" 

Start up:

/etc/rc.local ... sudo ifplugd eth0 --kill sudo ifup wlan0 

Network interfaces:

/etc/network/interfaces auto lo iface lo inet loopback autho eth0 allow-hotplug eth0 iface eth0 inet static address 192.168.0.51 netmask 255.255.255.0 auto wlan0 allow-hotplug wlan0 # I tried static vs manual, as per the posts, doesn't make a difference iface wlan0 inet manual wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf iface default inet dhcp 

And finally my wpa supplicant:

/etc/wpa_supplicant/wpa_supplicant.conf ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev update_config=1 network={ ssid="[my network name]" psk="[my password]" proto=RSN key_mgmt=WPA-PSK pairwise=CCMP TKIP group=CCMP TKIP } 

If it matters, running RASPBERRY PI 2 MODEL B, with raspberian UI.

4 Answers 4

5

I have read through this post, I don't know how many times, but just today I noticed:

autho eth0 allow-hotplug eth0 iface eth0 inet static address 192.168.0.51 netmask 255.255.255.0 

I know this is an old, "fixed" issue, but did you maybe correct the spelling of "autho eth0" along the way, one day? It's good to get things working, but better to know how you did it.

2

I don't know what happened, but it is working for me.

I was messing around with wifi static ips and all of a sudden it works.

My only change is the following to /etc/network/interfaces

... auto wlan0 allow-hotplug wlan0 address [desired ip address] netmask 255.255.255.0 gateway [router ip] wpa-essid [SSID of wifi] wpa-psk [wifi pw] #wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf <--- commented out .... 

Maybe my wpa_supplicant.conf was the problem?

This could all be coincidental, but my setup is working.

1
2

With the latest version of Jessie, I left everything as standard and added the following to dhcpcd.conf:

interface wlan0 metric 100 interface eth0 metric 300 static ip_address=192.168.1.69/24 static routers=192.168.1.1 static domain_name_servers=192.168.1.1 

I can now access the web management interface on a non-DHCP switch connected to eth0. I can, simultaneously, access the Internet from the Pi, or more specific to my use case, use Teamviewer to remote access the Pi from a PC.

If I reboot the Pi, it all works. If I turn WiFi off then back on, it all works. If I unplug the cable to eth0 then plug back in, it all works.

It took me a while to work through the many posts proffering advice, a lot of time and a lot of Pi rebuilds. I hope this helps someone! :O)

0
0

This post helped me out tremendously... So what I am doing involved hard line connecting my raspy pi and both ethernet and wifi were running. I needed to set the eth0 static and disable the wifi. I got ran... sudo nano /etc/network/interface and added that # mentioned above and poof problem fixed. Looks like this below...

allow-hotplug wlan0 iface wlan0 inte manual #wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf 

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.