2

Directly coming to the point.

I bought a raspberry pi zero w from a local retailer. I burned a raspbian "buster" image (dated 2019-09-26) into a 16GB SanDisk Class 10 SDHC memory card and booted the pi. Everything was working seamlessly. I updated the pi via terminal using sudo apt update and sudo apt dist-upgrade (commands were similar to this as I upgraded 20 days ago). When upgrading I interrupted the upgrade 2-3 times but the upgrade was installed successfully. Later on, I kept the pi as it is for some days and again booted it after a few days.

Then I noticed that my pi is unable to connect to my WiFi network. It was showing No wireless interfaces found then I searched on SO forum for
Connect to WiFi network through Ubuntu terminal [duplicate]

I run the command ifconfig wlan0 and the result was

wlan0: flag=4098<BRADCAST,MULTICAST> mtu 1500
        ether b8:27:eb:db:be:ea txqueue len 1000 (Ethernet)
        RX packets 0 bytes 0 (0.0 B)
        RX errors 0 dropped 0 overruns 0 frame 0
        TX packets 0 bytes 0 (0.0 B)
        TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

Then I ran the sudo ifconfig wlan0 up command and it said SIOCSIFFLAGS: Input/Output error. Then I checked another solution of Is there a terminal command to verify if Wifi is enabled? and ran the command rfkill list to check whether wifi has any soft or hard block but as output said there was no soft or hard block to neither Wireless LAN nor Bluetooth. After more research, I updated the wpa_supplicant.conf file and tried many solutions like entering the network configuration, entering country code, again removing the network configuration after entering country code, etc. but nothing worked. Then I ran command iwlist wlan0 scan stated in the RPi 3 B+ Wifi not working and the output was
wlan0 Failed to read scan data : Network is down.
Then I ran raspi-config to change the wifi country but the output was Could not communicate with wpa_supplicant. Later on, I tried many solutions found in various communities.
I tried commands like

sudo rfkill unblock all
sudo killall wpa_supplicant
sudo wpa_supplicant -c/etc/wpa_supplicant/wpa_supplicant.conf -iwlan0
sudo wpa_supplicant -c/etc/wpa_supplicant/wpa_supplicant.conf -iwlan0 -d

Nothing worked in my case. I tried re-installing the raspbian but that also failed. Then I changed the /etc/network/interfaces file and added

auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-ssid "network-name"
wpa-psk "network-password"

And the result was the same. After so many tries of 4 days, I decided to ask the question on SO. Is WiFi of my pi is broken? or there is any other solution that will work.

Edit1: Today I noticed that I can't even connect my Pi Zero W via Bluetooth. Is there some serious issue regarding hardware?

Edit 2: I bought a WiFi dongle and connected it with my Pi using a multiport USB connector. By running sudo iwlist wlan1 scan command, my WiFi dongle is able to scan the network but could not connect through GUI.

Any help is warmly appreciated. If you need more information, please ask for it.
Thanks in advance.

  • 4
    What happens if you write a copy of plain Raspbian 2020-02-13 to a new SDCard and boot that? Does the WiFi work in that case? – Dougie Mar 9 at 14:22
  • 1
    @Dougie I haven't tried the latest version of raspbian yet. Should I hit a try? – Vaibhav Mandlik Mar 9 at 14:24
  • 1
    @VaibhavMandlik Yes, try that. – M. Rostami Mar 9 at 16:28
  • 1
    "When upgrading I interrupted the upgrade" interruptions to upgrade (from whatever cause) can corrupt your OS. Attempting to diagnose is futile (as is incomplete changes to old networking systems) - restore from your backup (or do a fresh install). PS Raspbian DOES NOT use Network Manager - so Ubuntu tutorials won't work. – Milliways Mar 9 at 23:39
  • 1
    @Milliways Thanks for your reply but I've mentioned that "I tried to re-install the raspbian" – Vaibhav Mandlik Mar 10 at 6:41
1

It is difficult to know what state your Pi is in; certainly the /etc/network/interfaces as listed will stop dhcpcd from running.

From your comments it appears you are using NOOBS

None of us do - it just makes subsequent updates and support harder.

I strongly recommend you follow Dougie's suggestion and do a fresh install. You might like to use the new installer:-

https://www.raspberrypi.org/downloads/

It might also be a good idea to use a new SD Card - just to rule this out as a possible issue.

| improve this answer | |
  • @Miliways I've installed the latest raspbian image from that link already. I just mentioned its release no which is showed at the bottom right corner at the time of booting. I didn't understand "certainly the /etc/network/interfaces as listed will stop dhcpcd from running". Should I make changes in the interfaces file? – Vaibhav Mandlik Mar 13 at 15:02
0

A big big big big thank you to @Miliways for his question and his own answer.

None of the tutorials/answers worked for me on various forums before reading the above-linked question.

NOTE calling dhcp in /etc/network/interfaces will disable dhcpcd.

This struck my mind. I was using dhcp in my /etc/network/interfaces file. Then I changed it to

# interfaces(5) file used by ifup(8) and ifdown(8)

# Please note that this file is written to be used with dhcpcd
# For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'

# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d

auto lo
iface lo inet loopback

iface eth0 inet manual

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

allow-hotplug wlan1
iface wlan1 inet manual
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

And my WiFi dongle was able to scan and connect with the available WiFi network through GUI and CLI as well. But still, Pi's inbuilt WiFi is in trouble. It cannot connect to any network.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.