How to configure a Windows machine that has a global IP address so it can also talk to link-local devices on that network:
Before: No route to link-local destinations is defined:
C:\>route print =========================================================================== Interface List 0x1 ........................... MS TCP Loopback interface 0x2 ...00 03 ff 96 f5 0a ...... Intel 21041-Based PCI Ethernet Adapter (Generic) - Packet Scheduler Miniport =========================================================================== =========================================================================== Active Routes: Network Destination Netmask Gateway Interface Metric 0.0.0.0 0.0.0.0 206.111.147.145 206.111.147.156 30 127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1 206.111.147.144 255.255.255.240 206.111.147.156 206.111.147.156 30 206.111.147.156 255.255.255.255 127.0.0.1 127.0.0.1 30 206.111.147.255 255.255.255.255 206.111.147.156 206.111.147.156 30 224.0.0.0 240.0.0.0 206.111.147.156 206.111.147.156 30 255.255.255.255 255.255.255.255 206.111.147.156 206.111.147.156 1 Default Gateway: 206.111.147.145 =========================================================================== Persistent Routes: None
And ping to a link-local address fails:
C:\>ping -n 5 169.254.0.130 Pinging 169.254.0.130 with 32 bytes of data: Request timed out. Request timed out. Request timed out. Request timed out. Request timed out. Ping statistics for 169.254.0.130: Packets: Sent = 5, Received = 0, Lost = 5 (100% loss),
Now, add the route:
C:\>route add 169.254.0.0 mask 255.255.0.0 206.111.147.156
Now the route to link-local destinations is in the table:
C:\>route print =========================================================================== Interface List 0x1 ........................... MS TCP Loopback interface 0x2 ...00 03 ff 96 f5 0a ...... Intel 21041-Based PCI Ethernet Adapter (Generic) - Packet Scheduler Miniport =========================================================================== =========================================================================== Active Routes: Network Destination Netmask Gateway Interface Metric 0.0.0.0 0.0.0.0 206.111.147.145 206.111.147.156 30 127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1 169.254.0.0 255.255.0.0 206.111.147.156 206.111.147.156 1 206.111.147.144 255.255.255.240 206.111.147.156 206.111.147.156 30 206.111.147.156 255.255.255.255 127.0.0.1 127.0.0.1 30 206.111.147.255 255.255.255.255 206.111.147.156 206.111.147.156 30 224.0.0.0 240.0.0.0 206.111.147.156 206.111.147.156 30 255.255.255.255 255.255.255.255 206.111.147.156 206.111.147.156 1 Default Gateway: 206.111.147.145 =========================================================================== Persistent Routes: None
And ping to a link-local address succeeds:
C:\>ping -n 5 169.254.0.130 Pinging 169.254.0.130 with 32 bytes of data: Reply from 169.254.0.130: bytes=32 time=16ms TTL=255 Reply from 169.254.0.130: bytes=32 time=8ms TTL=255 Reply from 169.254.0.130: bytes=32 time=5ms TTL=255 Reply from 169.254.0.130: bytes=32 time=7ms TTL=255 Reply from 169.254.0.130: bytes=32 time=3ms TTL=255 Ping statistics for 169.254.0.130: Packets: Sent = 5, Received = 5, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 3ms, Maximum = 16ms, Average = 7ms