I'm running Elementary OS on an old(er) HP Pavilion dm1. Unfortunately, on startup my wireless is hard disabled, and I need to run sudo rfkill unblock all to get it up and running. Works fine once I do though.

Is there any way to either: 1) Automatically run this line with startup 2) Not need to do this anymore?

When I use rfkill to view any blocks, there's a hard block on the wireless, and the wireless button's light is orange. Pressing the button does nothing. After running the line, I can switch wireless on and off at will.

  • It's reproducible on other distros?
    – Braiam
    Commented May 3, 2014 at 17:06
  • I think it is better to use the path: /usr/sbin/rfkill unblock all because there may be permission problems when executing the script. Commented Mar 29, 2017 at 2:42

4 Answers 4


Another approach to unblocking the Wi-Fi interface on boot is to modify the kernel boot parameters (via grub/bootloader config or on a Raspberry Pi in the /boot/cmdline.txt file), and add these two parameters on the end of the line:

systemd.restore_state=0 rfkill.default_state=1

The first one disables the systemd rfkill restore service, whilst the second sets the default kernel rfkill status to enabled.


You have three options:

  • You can add the command rfkill unblock all using "System Settings > Startup Applications > Add"

  • Or add it to your /etc/rc.local file, before any return statement:

    rfkill unblock all
  • Not sure of this one; you can create a script (unblock.sh) in /etc/init.d with the single line rfkill unblock all >&2. Then, run chmod +x unblock.sh

  • 2
    Adding rfkill unblock all to /etc/rc.local didn't work for me on Debian (it's soft disabled by default)
    – zoechi
    Commented Aug 13, 2015 at 8:24
  • 1
    I have the same issue, soft-disabled by default, on Linux Mint 17.2 . Which is based on Ubuntu (which is based on Debian). A hassle to manage to enable wlan by default. I tried rc.local, service in init.d, ... that does work few seconds then something get it blocked
    – ArchiT3K
    Commented Aug 31, 2015 at 13:26

If you are using systemd, you can do this by running (as root or with sudo):

systemctl enable rfkill-unblock@all

Another option to manage rfkill status on boot is TLP ("TLP is a feature-rich command line utility for Linux, saving laptop battery power without the need to delve deeper into technical details.").

The specific setting in /etc/tlp.conf is:


(See Radio Device Switching.)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .