mirror of
https://gitea.com/mcereda/oam.git
synced 2026-02-09 05:44:23 +00:00
chore: improved knowledge about wake on lan
This commit is contained in:
@@ -49,6 +49,9 @@ tcpdump -r 'path/to/capture.file'
|
|||||||
|
|
||||||
# Isolate TCP flags.
|
# Isolate TCP flags.
|
||||||
tcpdump 'tcp[tcpflags] == tcp-fin'
|
tcpdump 'tcp[tcpflags] == tcp-fin'
|
||||||
|
|
||||||
|
# Capture and show Wake-on-Lan magic packets.
|
||||||
|
sudo tcpdump -nXxei any ether proto 0x0842 or udp port 9
|
||||||
```
|
```
|
||||||
|
|
||||||
## Sources
|
## Sources
|
||||||
|
|||||||
@@ -12,6 +12,11 @@ The host needs to support wake-on-LAN and have it enabled.
|
|||||||
|
|
||||||
See [`wakeonlan`][wakeonlan] or [`wol`][wol].
|
See [`wakeonlan`][wakeonlan] or [`wol`][wol].
|
||||||
|
|
||||||
|
```sh
|
||||||
|
# Check the magic packet arrives on the target machine.
|
||||||
|
sudo tcpdump -nXxei any ether proto 0x0842 or udp port 9
|
||||||
|
```
|
||||||
|
|
||||||
## Further readings
|
## Further readings
|
||||||
|
|
||||||
- [`wakeonlan`][wakeonlan]
|
- [`wakeonlan`][wakeonlan]
|
||||||
|
|||||||
@@ -12,15 +12,15 @@
|
|||||||
# Install `wakeonlan`.
|
# Install `wakeonlan`.
|
||||||
brew install 'wakeonlan'
|
brew install 'wakeonlan'
|
||||||
|
|
||||||
# Send a WOL package to the host.
|
# Broadcast a WOL package.
|
||||||
wakeonlan '11:22:33:44:55:66'
|
wakeonlan '11:22:33:44:55:66'
|
||||||
|
|
||||||
# Simulate.
|
# Simulate the broadcast.
|
||||||
wakeonlan -n '11:22:33:44:55:66'
|
wakeonlan -n '11:22:33:44:55:66'
|
||||||
|
|
||||||
# Limit the magic package to a specific network or host.
|
# Limit the magic package to specific networks or hosts.
|
||||||
# Use a network's *broadcast* address unless you have a static ARP table
|
# Use network *broadcast* addresses to ensure the magic packets can actually
|
||||||
# configured so the magic packet can actually reach the single host.
|
# reach the target host; avoid this by having a static ARP table configured.
|
||||||
wakeonlan -i '192.168.1.255' '11:22:33:44:55:66'
|
wakeonlan -i '192.168.1.255' '11:22:33:44:55:66'
|
||||||
wakeonlan -n '11:22:33:44:55:66' -i '192.168.100.3'
|
wakeonlan -n '11:22:33:44:55:66' -i '192.168.100.3'
|
||||||
```
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user