WOL Wake On Lan 기능은 어떻게 작동하나요?
💡 요약 정리
- WOL(Wake On LAN)은 서버가 꺼져 있어도 원격으로 전원을 켤 수 있는 기능입니다.
- 반드시 동일 네트워크 내에서만 작동합니다.
- ethtool 명령어로 Wake-on 상태를 확인하고, 필요 시 설정을 변경할 수 있습니다.
- ether-wake 명령어를 통해 원격 서버를 시동할 수 있습니다.
Shutdown 돼 있는 서버를, 네트워크상에서 신호를 보내서 시동하는 기능입니다.
- 동일 네트워크 상에서 가능
- ethtool로 확인 시 Wake-on 상태가
g일 경우 가능
[root@test2 ~]# ethtool eth0
Settings for eth0:
Supported ports: [ TP MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Supports auto-negotiation: Yes
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Advertised pause frame use: No
Advertised auto-negotiation: Yes
Link partner advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Link partner advertised pause frame use: No
Link partner advertised auto-negotiation: Yes
Speed: 100Mb/s
Duplex: Full
Port: MII
PHYAD: 32
Transceiver: internal
Auto-negotiation: on
Supports Wake-on: pumbg
Wake-on: g
Current message level: 0x00000007 (7)
Link detected: yes
- Wake-on 상태가
d일 경우에는 아래 명령어로 변경할 수 있습니다.
[root@test2 ~]# ethtool -s eth0 wol g
1. WOL 기능 테스트 방법
해당 서버를 Shutdown 후, 동일 네트워크에 있는 다른 서버에서 ether-wake 명령어를 실행합니다:
[root@test1 ~]# ether-wake -i eth0 00:16:EC:EA:A5:B7
- 위 명령어에서
-i eth0는 인터페이스를 지정하는 옵션이며,00:16:EC:EA:A5:B7은 대상 서버의 MAC 주소입니다.
이 과정을 통해, 꺼져 있는 서버가 정상적으로 원격에서 시동됩니다.