(Note: I had created a thread earlier, but that was published accidentally before I could type out completely. I have deleted that post.)
I had been using a Netgear USB WiFi adapter. It required no driver installation or anything. It stopped working two days back, probably because it is too old now.
I unboxed my wifi dongle which I purchased as a backup - a D-Link DWA 131 USB adapter. And it is not working.
First up, just to ensure that the D-Link dongle itself doesn’t have any problems, I booted into windows and installed the driver from exe file (it is a dual boot system). The wifi dongle works fine, as expected. So the dongle is okay, I can guarantee.
Now the problem exactly, is that the wifi doesn’t connect to a network. After I plug in the dongle, I can click on network manager applet in the system tray and see the available wifi networks around me. I click on on a network, and it asks me the password. I enter the correct password. The network manager icon in system tray turns to a loading icon (the rotating circle). But it doesn’t connect to the network. A notification pops up, saying that the PC has disconnected from the network. (Note that it doesn’t connect to the network in the first place. Also, It doesn’t say that the password was wrong or some other error)
I tried reinstalling the kernel (
linux-lts). In the post-installation steps, it installs modules for the chipset which my dongle uses. Rebooted my PC, but the problem persisted.
I headed over to arch wiki. The entry relating to my chipset is this: https://wiki.archlinux.org/index.php/Network_configuration/Wireless#rtl8xxxu
A question on fedora forum, relating to the same wifi dongle is here: https://ask.fedoraproject.org/t/wifi-adaptor-dl-dwa-131-seems-working-but-cannot-connect/3222/3
A user on the forum suggest installing the driver from https://github.com/Mange/rtl8192eu-linux-driver I wanted to proceed but I have never compiled an application from source before so I stopped.
I went to the official website: https://support.dlink.com/ProductInfo.aspx?m=DWA-131
My hardware version is E (it asks you to select). I downloaded the files for Linux 184.108.40.206. That too contained source files. But it had a readme which convinced me that the installation is easy (
sudo make install) I did the build. It didn’t throw any errors, but I still couldn’t connect to my wifi network.
Finally, I have booted in windows, and am typing this post. Probably the GitHub link I posted may be the right driver, but I am too dumb with source files and stuff. Maybe a user here can help me get my wifi dongle working. Thanks!
Edit: Outputs that may be required
$ uname -a Linux wired 5.4.46-1-lts #1 SMP Wed, 10 Jun 2020 20:36:34 +0000 x86_64 GNU/Linux
$ iwconfig enp0s26u1u2 no wireless extensions. lo no wireless extensions. enp3s0 no wireless extensions. wlan0 IEEE 802.11 ESSID:off/any Mode:Managed Access Point: Not-Associated Tx-Power=20 dBm Retry short limit:7 RTS thr=2347 B Fragment thr:off Power Management:off
$ ifconfig enp0s26u1u2: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 192.168.42.218 netmask 255.255.255.0 broadcast 192.168.42.255 inet6 fe80::929d:8a76:dfd1:888b prefixlen 64 scopeid 0x20<link> ether 22:a2:6e:9c:59:1e txqueuelen 1000 (Ethernet) RX packets 28 bytes 2744 (2.6 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 57 bytes 9659 (9.4 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 enp3s0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500 ether 94:de:80:e5:03:2b txqueuelen 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 lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10<host> loop txqueuelen 1000 (Local Loopback) RX packets 6148 bytes 341879 (333.8 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 6148 bytes 341879 (333.8 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 wlan0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500 ether ce:d4:3a:28:3e:30 txqueuelen 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
$ sudo lshw -c network [sudo] password for snehit: *-network description: Ethernet interface product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller vendor: Realtek Semiconductor Co., Ltd. physical id: 0 bus info: pci@0000:03:00.0 logical name: enp3s0 version: 06 serial: 94:de:80:e5:03:2b capacity: 1Gbit/s width: 64 bits clock: 33MHz capabilities: pm msi pciexpress msix vpd bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt 1000bt-fd autonegotiation configuration: autonegotiation=on broadcast=yes driver=r8169 firmware=rtl8168e-3_0.0.4 03/27/12 latency=0 link=no multicast=yes port=MII resources: irq:16 ioport:d000(size=256) memory:f2104000-f2104fff memory:f2100000-f2103fff *-network:0 description: Ethernet interface physical id: 2 bus info: usb@1:1.2 logical name: enp0s26u1u2 serial: 22:a2:6e:9c:59:1e capabilities: ethernet physical configuration: broadcast=yes driver=rndis_host driverversion=22-Aug-2005 firmware=RNDIS device ip=192.168.42.218 link=yes multicast=yes *-network:1 description: Wireless interface physical id: 3 bus info: usb@2:1.2 logical name: wlan0 serial: ce:d4:3a:28:3e:30 capabilities: ethernet physical wireless configuration: broadcast=yes driver=rtl8xxxu driverversion=5.4.46-1-lts firmware=N/A link=no multicast=yes wireless=IEEE 802.11
I ran all these commands while the USB dongle is plugged in the cpu.
Also note that the system is a desktop computer, which doesn’t have any built-in wireless interface. The wifi dongle is the only wireless interface connected to my PC.