0

I'm remoting into a RPi Zero W using SSH. The RPi is connected to the internet via Ethernet cable. I want to set-up the WiFi at the current remote location and check that it will work when the Ethernet cable is disconnected.

I can set-up the WiFi via raspi-config or by directly editing the wpa_supplicant file. Is there a way to verify remotely that the WiFi will work once the Ethernet cable is unplugged?

If I run iwgetid I get nothing back, ostensibly because the wireless LAN is not currently being used. The command iwconfig gives me:

lo     no wireless extensions.
eth0   no wireless extensions.
wlan0  IEEE 802.11 ESSID:off/any
       Mode:Managed Access Point: Not-Associated
       Retry short limit:7 RTS thr:off Fragment thr:off
       Power Management:on

If I run sudo iwlist wlan0 scan I can see the network I want to connect to. Is there any way to test it while plugged into Ethernet?

OS is Raspbian installed via NOOBS v. 2.8.1. I did verify the RPi can connect to the internet over WiFi at my location before shipping it off to the current remote location.

dikuw
  • 198
  • 1
  • 3
  • 8

1 Answers1

1

If you setup /etc/network/interfaces as in How to set up networking/WiFi then you can see if it has connected (and the IP) with ip a.

route -vn will show if there is an entry in the routing table (and the metric). Both eth0 and wlan0 should have entries.

Milliways
  • 62,573
  • 32
  • 113
  • 225