How to enable Wake-on-lan in Gnu / Linux

Back of a router with the different network ports.

Sleep and hibernate operation generally does not work properly with some configurations or layouts. This means that some users cannot use their equipment remotely if the computer goes to sleep. But it's something that It can be changed very easily by activating the Wake-on-lan function of the network card of our equipment. This function appeared years ago within network cards and motherboards and, although it is not universal, there are many devices that have this function.

Wake-on-lan is a function that allows us to activate a device through an electronic signal. This allows us to perform actions within a computer through another computer remotely. An interesting function that even allows you to turn on the computer when it is off.Generally, Wake-on-lan is disabled in our Gnu / Linux distribution but it can be activated through the terminal and without any complementary tool. To do this we open the terminal and write the following:


This will list all the wireless devices that the operating system has. We can also use the following command if we use network cable:


The device will be given a name like eth01 or phy01. This is the name that we have to memorize as we will use it later. Now we have to write the following to know the status of the network card:

iw phy01 wowlan show

This will show us a message like the following:

WoWLAN is disabled

If not, then we will have it activated and ready to go; if so, then we have to activate it with the following command:

sudo iw phy01 wowlan enable any

And we will disable it by typing the same but changing the word enable to disable, like this

sudo iw phy01 wowlan disable any

This will cause the computer to wake up or change state with a simple message, going from suspension to activation or even from off to on.

The content of the article adheres to our principles of editorial ethics. To report an error click here!.

Be the first to comment

Leave a Comment

Your email address will not be published.



  1. Responsible for the data: AB Internet Networks 2008 SL
  2. Purpose of the data: Control SPAM, comment management.
  3. Legitimation: Your consent
  4. Communication of the data: The data will not be communicated to third parties except by legal obligation.
  5. Data storage: Database hosted by Occentus Networks (EU)
  6. Rights: At any time you can limit, recover and delete your information.