pdf Wake On Lan chez Free
Par keyphrene, Friday 25 June 2010 à 07:11 :: Freebox :: #30 :: rss
Wake On Lan chez Free, réveiller votre ordinateur depuis internet.
Configurer votre BIOS
Aller dans votre BIOS pour activer la Wake On Lan
Exemple: Sur ma carte ASUS PK5 SE, la mention wake on lan n'y figure pas Je dois me rendre dans le menu "Power", "APM" et activer les fonctions
- WakeUp PCI
- WakeUp PCI-E
Configurer votre driver de carte réseau
Aller dans le gestionnaire de périphériques
Ouvrer les propriétés de votre carte réseau

Mettre à "On" l'option "Shutdown Wake Up"

Mettre à "Magic Packet" l'option "Wake Up Capabilities"

Configurer votre Freebox
Activer la fonction Proxy Wol (Wake On Lan)

Le redémarrage de votre Freebox est nécessaire pour activer la configuration
Récupérer l'adresse Mac de votre carte réseau
Ouvrer une command dos (cmd.exe) et la lancer la commande suivante
ipconfig /all
Vous obtenez l'adresse suivante
Adresse physique . . . . . . . . .: 00-12-4c-d5-78-dc
Sous windows Vista et Seven, vous devez démarrer la cmd.exe en tant qu'administrateur
Installer votre script wakeonlan.php chez un hébergeur
<? # Wake on LAN - (c) HotKey@spr.at, upgraded by Murzik # Modified by Allan Barizo http://www.hackernotcracker.com flush(); function WakeOnLan($addr, $mac,$socket_number) { $addr_byte = explode(':', $mac); $hw_addr = ''; for ($a=0; $a <6; $a++) $hw_addr .= chr(hexdec($addr_byte[$a])); $msg = chr(255).chr(255).chr(255).chr(255).chr(255).chr(255); for ($a = 1; $a <= 16; $a++) $msg .= $hw_addr; // send it to the broadcast address using UDP // SQL_BROADCAST option isn't help!! $s = socket_create(AF_INET, SOCK_DGRAM, SOL_UDP); if ($s == false) { echo "Error creating socket!\n"; echo "Error code is '".socket_last_error($s)."' - " . socket_strerror(socket_last_error($s)); return FALSE; } else { // setting a broadcast option to socket: $opt_ret = socket_set_option($s, 1, 6, TRUE); if($opt_ret <0) { echo "setsockopt() failed, error: " . strerror($opt_ret) . "\n"; return FALSE; } if(socket_sendto($s, $msg, strlen($msg), 0, $addr, $socket_number)) { echo "Magic Packet sent successfully!"; socket_close($s); return TRUE; } else { echo "Magic packet failed!"; return FALSE; } } } // Port number where the computer is listening. Usually, any number between 1-50000 will do. Normally people choose 7 or 9. $socket_number = "9"; // MAC Address of the listening computer's network device 00:1b:fc:c3:0c:3d $mac_addy = "00:12:4c:d5:78:dc"; // IP address of the listening computer. Input the domain name if you are using a hostname (like when under Dynamic DNS/IP) $ip_addy = "10.10.10.1"; WakeOnLan($ip_addy, $mac_addy,$socket_number) ?>
Remplacer $mac_addy="votre adresse mac" et $ip_addy="votre adresse publique" Attention, l'adresse MAC doit avoir comme séparateur ":" et être en minuscule pour les lettres
Tester le démarrage de votre serveur
Lancer votre script http://<votre_domaine>/wakeonlan.php
ou vous pouvez utiliser ce service
WakeOnLanTAGS : Wake on lan Free Freebox script PHP magic packet BIOS wake up

Comments
No comment for this moment.
Add a comment