Black God

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!

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

  1. krmani
    June 2, 2013 at 4:39 pm

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

  2. Soul
    March 16, 2013 at 3:00 am

    i think you would show how to fix a “hard” block ?!

  3. Luís de Sousa
    December 23, 2012 at 10:19 pm

    Hi mate, I just had this same issue (no clue why) but your little recipe worked marvellously! Thank you and regards

Leave a Reply

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