What is wake on lan (wol)? How is it used
Table of contents:
Surely you have thought many times about how to access various resources of your PC even when you are away from home, the solution is simple Wake ON LAN.
You can also have an FTP server to access the files, you can have control over your downloads, up to full control over the machine through VNC (Virtual Network Computing). You just have to register a DNS, pair the services and voila, full control. But what happens if my machine is turned off? Well, you can call your house and ask someone to simply connect your PC. Okay, but what if no one is home? Well, it is a small problem, but there is a solution.
What is Wake on LAN?
Many must have already heard of the Wake on LAN function, which lets you trigger a command over the network to wake up a machine. An interesting detail about the feature is that it works not only when the machine is "suspended", but it also works when it is "hibernating" or directly powered off.
It is currently activated on all motherboards (You can see the tutorial of the best motherboards), regardless of its range: low, medium or high. Since it is a protocol that has been on PCs for a long time.
The only downside, however, is that for the resource to work properly, the machine must have been powered on at least once. In other words, you turn on your computer normally, use it and turn it off. After that, you can send a Wake on LAN command to connect to the computer.
This happens because at shutdown the machine is in "stand by" and when detecting the "magic packet", the network controller can generate an interruption that wakes up the machine.
Another detail for this to work is that it must contain ErP (or EuP) support, a European standard that says that the equipment in standby must consume less than 1w with the option enabled. But to turn on the computer through Wake on LAN, this option must be disabled, so that the standby consumption of a typical PC will be around 3w, not worrying.
One last detail before starting: the objective of this tutorial is that you can connect your PC from a smartphone (or tablet with iOS or Android) from anywhere in the world. So we are going to track each stage of the process to ensure that the "magic packet" reaches the computer and connects.
How to activate Wake on LAN step by step
For starters, we need to enable Wake on LAN support in your motherboard's BIOS Setup, as most come with this feature disabled by default. To do this, on most motherboards you just have to press the Delete key repeatedly for several seconds during the computer startup, so as not to miss the brief moment you have to access the BIOS. On some boards it is the F2 key that should be used.
Once inside the setup you should see a screen like this below:
Look for a "Power Management" screen or something like that and there should be an option like "Wake on LAN", "Wake on SMEs" or "Power up by PCI / PCIE". In case of doubt, consult the manual of your motherboard to know the exact name and where the option is located.
The next step is to look at the "MAC Address" of your network card. There are several methods, but what is easier is to open a command prompt window (by pressing Windows key + R and typing CMD). Then type "ipconfig / all".
Look for the field "Physical Address". Write this sequence of letters and numbers on a piece of paper, since you will need it several times. If you want, you can already test if Wake on LAN works.
But how?
Since the objective is to wake up the machine from your mobile, you can download the application that triggers the magic pack. On iOS you can use Mocha WOL (https://itunes.apple.com/en/app/mocha-wol/id422625778?mt=8). On Android, an app called Wake on LAN (https://play.google.com/store/apps/details?id=net.mafro.android.wakeonlan&hl=en_419), both free.
The configuration does not have much mystery, you just have to put the MAC Address (without the: or - of the separation, since the app adds them alone) and choose port 9. Normally port 9 or 7 is used, but for security always choose the same one and add the broadcast IP of the local network, assuming that you are connected via WiFi but on the same network as the PC.
Like most routers, it defaults to the address 192.168.1.1 or 192.168.0.1; the broadcast is 192.168.1.255 or 192.168.0.255. In the iOS app you don't even have to write that address, just check the WOL on LAN option and it will automatically search for your local network address.
"Waking up" the PC from the mobile
Okay, so you can wake up your computer while you're at home. But surely you have a question regarding this: how to do this over the internet? Well, sending the magic packet is easy. You already have the application, just find out the IP of your connection, disconnect WiFi (keeping only the data connection of the mobile phone) and send the magic packet.
Finding out the IP of the connection is easy, there are also several methods, one of the easiest is to access the meuip website.
Obviously, typing your IP address, as well as impractical, can be useless in case it changes, as you may have a dynamic IP connection.
Ideally, register an address with an easy-to-remember name and find a way to associate your IP with this address. For this there are several dynamic DNS services, even free. One of the best known, and the one you are going to use, is Dyndns.
Create a free account at https://account.dyn.com/entrance/ and then go to My Hosts -> Add Host Services.
Write the desired name in the hostname field, choose a domain, so that your address is hostname.domain and in the IP Address field instead of typing your IP, just click on the link below (Your current location's IP address is xxx.xxx.xxx.xxx) for the website to fill in the field for you.
Done, now that you already have an internet address. But to make sure that the package will reach your machine using that address, you have to adjust more than two details:
- Find a way to keep the registry up to date, because if your modem / router reboots, your IP will most likely change.
- Configure the router to redirect the packet received from the internet to your machine on the local network.
The former is relatively easy. Most routers can do this automatically. You just have to register your account details in dyndns so that it keeps your IP linked with the registered address.
Now we are going to configure the router to send the magic packet from the internet to your PC.
First, we have to access the router's configuration interface. In the vast majority of cases, simply open a browser and access its address on the local network (most use 192.168.1.1) and enter a username to enter. Normally, the username is "admin", while the password is the same as "admin" or simply the user "admin" and leave the password blank. Check your router's manual. Normally, the router has a label with this information.
To find out the address, you can also go to ipconfig (via the command prompt) and just search for the "Default Gateway" address.
Once inside the configuration panel, you have to find where to set a local network IP address for the network card. Look for an option similar to "IP Binding", which is usually close to the "DHCP Server" setting. There you can associate an IP address with a MAC Address.
Choose an address and remember it, because now you are going to redirect the ports that are used to send the Wake on LAN packet.
Also in the configuration panel of your router look for the option of "Virtual Servers" (Virtual Servers) or Port Redirection (Port Forwarding).
There, create a rule that indicates that port 7 or 9 (it is more common to use port 9 for this) must be sent to the IP address that you have reserved for the computer. The protocol used for this command is UDP.
Typically, you have the option of defining a range of ports on each rule. You can put the same port in both fields, or configure the start and end ports (Start Port and End Port) and this whole interval will be covered (redirected) by this rule.
Done, now you just have to apply, save and (usually) restart the router. Look for a "Save and Restart" option in the router's configuration panel so that the changes are saved and restarted.
We recommend reading the best routers on the market.
If you have done everything correctly, the resource should already be working, you just have to try.
Open Wake on Lan again, select port 9. Pick up your mobile phone, make sure that you are not connected to your local network by WiFi and that your data connection (4G, 3G) is working. In the application configuration, put the address you registered in Dyndns, the MAC Address and port 9.
To redirect your ports to the IP of your computer, and to access, just enter the address of the Dyndns, a colon and the redirect port.
And so you can connect to your machine and access through remote access. With certainty, you will no longer have to leave the machine connected all week or the whole month, because you can always access with this method. The process may be a little laborious, but it's worth it.
Have you ever used Wake ON LAN? Do you find it useful or do you prefer to use the cloud to save all your data instead of your PC?
UK government websites have been used and used to mine because of browsealoud
A security flaw in the Browsealoud plugin to put users' processors to mine Monero, among the affected websites have been those of the US and UK governments.
▷ Activate wake on lan to turn on your computer remotely
If you want to be able to start a suspended computer remotely with even a Smartphone, do it with Wake on LAN technology ✅
▷ What are lan, man and wan networks and what are they used for
We show you what the LAN, MAN and WAN networks are. ? Characteristics, network topologies, standards and utility of the networks that surround us