Wake on LAN tools to turn on the remote PCs


1.0 Introduction

Wake-on-LAN (WOL) is an ethernet computer networking standard that allows a computer to be turned by a network message named magic packed that is a broadcast frame containing 6 bytes set all to 255 (FF FF FF FF FF FF in hexadecimal), followed by sixteen repetitions of the target computer's 48-bit MAC address, for a total of 102 bytes. Optionally, if the network interface (NIC) supports it, it's possible to specify extra six bytes as password. To use this method to power on your PC:


2.0 System requirements

WakeUp tools require a Linux (x86 or x64) or Windows (2000/XP/Vista/7/8 x86 or x64) PC.


3.0 Installation

No installation is required for the stand-alone Windows version. If you want to use WakeUpServer and WakeUpService included in VEGA ZZ package, you must check "Warp utilities for secure Internet connection" component during the setup procedure. For the Linux version, choose the binary files compatible with your system (x86 or x64), copy wakeup, wakeupserver and wakeupservice to /usr/local/bin and libhdrive-so to /usr/local/lib. For WakeUpServer and WakeUpService read the 4.2 section.


4.0 Usage

The package include three tools:


4.1 WakeUp

If you run this small utility by command prompt without arguments, the help is shown:

WakeUp 1.0.0 - (c) 2013, Alessandro Pedretti
Send wake on lan magic packet

Usage: WakeUp -k [COMMAND] -hlq -c [CONFIG_FILE] -s [SERVER]
              -p [PORT] [MAC_ADDRESS/HOST_NAME] ...

 c -> configuration file
 h -> show this help
 k -> command to execute:
      find -> find the MAC address by host name or IP
      list -> show the host list of the configuration file
      wake -> wake up the specified hosts (default)
 p -> WakeUp server port (default 53212)
 q -> quiet mode
 s -> WakeUp server name or IP

WakeUp bc-ff-5c-f3-01-00 MyHost
WakeUp -c list
WakeUp -c find

As argument, you can specify one or more targets by their MAC address, IP (Find command only), name that is automatically translated by the DNS or the information included in the configuration file (wakeup.ini), that is located usually in Config directory. Wildcards are allowed to turn on more than one PC included in the configuration file.

The following table shows the description of the options and their arguments:

Option Argument Description
-c Configuration file Change the default configuration file with that specified by the user.
-h - Show the help.
-k Command Define the command to be executed by WakeUp:
  • Find
    find the MAC address by IP or host name. It works only for the PCs connected in the local network.
  • List
    show all targets included in the configuration file.
  • Wake
    wake up the specified targets. It's the default operating mode.
-p Port TCP/IP port of the WakeUp server (default 53212). See -s option.
-q - Enable the quiet mode. No message is shown when you turn on this option.
-s Server WakeUp server name or IP for the routing of WOL packets. If you don't use it, you can turn on only the PC in the loca network.

*All options are case-insensitive.


4.1.1 Examples

Here are some examples to clarify the WakeUp uses:


4.2 WakeUpServer and WakeUpService

As explained in the introduction, WOL message can be sent only in the local network and in order to reach a remote network it must be routed by TCP/IP protocol. Some routers and firewalls can be configured to receive the WOL packet and to repeat in the original form in the local network, but if you don't have the access to the configuration of the network devices, it could be a problem. To overcome that, WakeUpServer and WakeUpService were developed that are the same tool in two different version: the former is a normal program that runs in background and the latter is the same program but it can run in service/daemon mode.

WakeUpServer and WakeUpService includes a protection system to avoid DoS attacks: no more than five concurrent connections are allowed and the the received packets must be encrypted. A check system stops the unauthorized packets.


4.2.1 Running WakeUpServer for Windows

To run this version, select VEGA ZZ WarpProject WakeUp Server in the Start menu. The program starts in background without graphic interface, installing a small icon in the Windows try bar. Clicking on it by the right mouse button, the context menu is shown:

If you want to run the stand-alone version, go into ...\Bin\Mingw32 or ...\Bin\Mingw64 directory and open Wakeupserver.exe.

The default TCP/IP listening port is 53212 and it must be opened if you are running a firewall.


4.2.2 Running WakeUpService for Windows

A Windows service (used to be called NT service) is a console application, which does not have a message pump. A Windows service can be started without the user having to login to the computer and it won't die after the user logs off. The WakeUpService works in background and it doesn't have the graphic interface. Before running it, it must be installed by selecting VEGA ZZ WarpProject WakeUp Service Install in the Start menu. To start the service, choose VEGA ZZ WarpProject WakeUp Service Start. Restarting the system, WakeUpService is automatically executed as the other  services. If you want to stop the service, select VEGA ZZ WarpProject WakeUp Service Stop. Remember that when you reboot the system, WakeUpService service is automatically restarted.
To uninstall the service, choose VEGA ZZ WarpProject WakeUp Service Uninstall.
As for the previous version, the default TCP/IP listening port is 53212 and it must be opened if you are running a firewall.


4.2.3 Running WakeUpServer for Linux

This version can be executed as a normal Linux command typing wakeupserver in the command prompt. No command options are available.


4.2.4 Running WakeUpService for Linux

A daemon (or service) is a background process that is designed to run autonomously, with little or not user intervention. WakeUpService can be started as Linux daemon when the system cam up, running in background. To configure the WakeUpService daemon, you must follow these steps:


5.0 Wakeup.ini configuration file

This file includes the information to translate the target names to MAC address. It can be found by WakeUp in ...\VEGA ZZ\Config directory or by reading VEGADIR environment variable value that should point to VEGA or VEGA ZZ installation directory. The Linux version, if VEGADIR is not set, looks also in /etc directory. Optionally, you can specify manually the file by using the WakeUp -c option.

Here's an example of wakeup.ini file:

; WakeUp host list
; Copyright 2013, Alessandro Pedretti
; Host name    MAC address
; =================================
  MyHost       70:FE:EA:39:43:E1

The first column is the host name and the second one is the MAC address. To separate each byte of the MAC address, you can use both dash (-) and colon (:). Both host name and MAC address are case insensitive.  Thanks to the pattern matching, it could be interesting to organize the hosts to be able to turn on group of them:

; Home PCs:
  Home/Desktop    b6-8a-59-5f-69-b0
  Home/Laptop     47-bf-dd-8e-ed-09

; Office PCs:

  Office\Desktop  bb-9d-64-b4-fd-5c
  Office\HPC1     53-b2-ca-2d-94-bb
  Office\HPC2     5f-03-fd-8e-4b-0a

The path separator can be slash (/) or back slash (\) and they are automatically interconverted during the pattern matching.


6.0 History


7.0 Copyright and disclaimers

All trademarks and software directly or indirectly referred in this document, are copyrighted from legal owners. WakeUp Tools is a freeware program and can be spread through Internet, BBS, CD-ROM and other electronic formats. The Author of this program accepts no responsibility for hardware/software damages resulting from the use of this package. No warranty is made about the software or its performance. Use and copying of this software and the preparation of derivative works based on this software are permitted, so long as the following conditions are met:


WakeUp Tools
is a software developed in 2013
by Alessandro Pedretti
All rights reserved.

Alessandro Pedretti
Dipartimento di Scienze Farmaceutiche
UniversitÓ degli Studi di Milano
Via Mangiagalli, 25
I-20133 Milano - Italy
Tel. +39 02 503 19332
Fax. +39 02 503 19359
E-Mail: info@vegazz.net
WWW: http://www.vegazz.net