Fix WiFi Not Working After VPN Disconnected in Ubuntu

Last updated: June 4, 2020

Sometimes after disconnected from a VPN network in Ubuntu 20.04, wireless does no longer work and even shows ‘No Adapter Found’ in the settings. If you have the same problem, this tutorial may help.

Without restarting your computer, you can try following steps to make the wireless work again.

1.) Restart Wifi network via system menu.

Try turn off wireless network from system tray menu, and turn it on again.

This works in the case when I disconnected from PPTP VPN server.

2.) Restart Wifi network via nmcli.

The previous step may not work sometimes. If so, try running commands in terminal (Ctrl+Alt+T) to restart networking:

nmcli networking off 

nmcli networking on

And this works in the case when I disconnected from a ExpressVPN server.

3.) Restart Wireless interface via ifconfig

You may also run following 2 commands to restart the wireless network:

sudo ifconfig wlo1 down

sudo ifconfig wlo1 up

NOTE you need to replace wlo1 to your wifi network name (usually wlan0). Check it via ifconfig command.

4.) If none of the previous steps works, you may try to reload the wireless kernel module.

Open terminal (Ctrl+Alt+T) from system application menu and run command to check your wireless driver:

sudo lshw -C network 2>&1 | grep wireless | grep driver

As the picture shows, it’s rtw_pci in my case.

Then run command to reload the kernel module:

sudo modprobe -r MODULE_NAME && sudo modprobe MODULE_NAME

In my case the command is (rtwpci did work though it should be rtw_pci):

sudo modprobe -r rtwpci && sudo modprobe rtwpci

Twitter

I'm a freelance blogger who started using Ubuntu in 2007 and wishes to share my experiences and some useful tips with Ubuntu beginners and lovers. Please comment to let me know if the tutorial is outdated! And, notify me if you find any typo/grammar/language mistakes. English is not my native language. Contact me via [email protected] Buy me a coffee: https://ko-fi.com/ubuntuhandbook1

3 responses to Fix WiFi Not Working After VPN Disconnected in Ubuntu

  1. These do work but they do not fix the problem – they merely make the symptoms disappear. Do you how the root cause of this problem can be identified and fixed permanently? Thanks

  2. Brandon Bourret August 6, 2020 at 2:02 am

    I made a little GUI wrapper around ExpressVPN’s console-based interface (for Debian-based Linux systems). And thanks to the information on this page, I included an option to reset the WiFi kernel module (the function SHOULD automagically detect which kernel module is in use).

    https://github.com/bourretbrandon/expressvpn-gui

  3. Hi, happy to know others had this issue as well. VPNExpress supported pointed me to this site: https://www.expressvpn.com/support/troubleshooting/linux-not-connected-cannot-browse/