How to fix “Wireless is disabled by hardware switch” message in Ubuntu 12.04

Recently I faced following error message in Network Manager indicator in my Ubuntu 12.04 laptop.

“Wireless is disabled by hardware switch” 

The catch here is I did not disable the wireless by hardware switch. In Network Manager indicator, I just removed the tick in “Enable Wireless” and again restored the tick again. Basically it was disable and enable wireless in sequence, keeping my Wi-fi hardware slide switch in laptop in ON position only.

Toggling the hardware Wi-Fi switch did not yield any useful result. Reboot was useless. Power shutdown and Power on also failed to restore this status. Though hardware switch is ON, Ubuntu kept saying it was disabled.

Wireless is disabled by hardware switch
Wireless is disabled by hardware switch

rfkill command is handy in this scenariom which is used to control the hardware switches for Wireless.

The following command helps to identify the both hard and soft state of hardware switch. To  ensure Wireless to work, we need to ensure that none of these lock is set. Here is what I got.

$ rfkill list wlan
0: sony-wifi: Wireless LAN
Soft blocked: yes
Hard blocked: no
3: phy0: Wireless LAN
Soft blocked: no
Hard blocked: no

In the above output you can see that it was soft blocked. The above can be reset with following command.

$ rfkill unblock wlan

You can ensure that it was unblocked with $ rfkill list wlan command again. The output should be similar to output shown below.

$ rfkill list wlan
0: sony-wifi: Wireless LAN
Soft blocked: no
Hard blocked: no
3: phy0: Wireless LAN
Soft blocked: no
Hard blocked: no

Now it is time to inform the Network Manager about this change. This can be done by restarting the Network Manager daemon as shown below.

$ sudo service network-manager restart

That is it. Hope you got back your wireless network. Enjoy!

Share this post

5 comments

  1. The printer will not connect to my new Netgear dual-band n900 router. The printer offers WEP which is not being used or the push the button on the modem method. This is not working. The printer has functioned as a stand-alone wireless and is not connected to any computer but has worked fine with all other routers attempted. Is there a driver update that I can use to allow it to connect with my new much more expensive and more secure router. All other equipment connects fine with the modem using the push button method.

  2. you simply press the F2 button/ wireless icon button in your coputer. it will become alright. post a reply.

Leave a Reply

Your email address will not be published. Required fields are marked *