Configuring Rate Limiting on ARP Packets based on Source IP Addresses
Context
When processing a large number of ARP packets with fixed IP addresses (for example, MAC addresses or outbound interfaces that match a source IP address frequently change), the CPU is overloaded and cannot process other services.
To prevent this problem, configure the gateway to limit the rate of ARP packets based on source IP addresses. The gateway collects statistics on ARP packets from a specified source IP address. If the number of ARP packets received in one second from the specified IP address exceeds the threshold, the device discards the excess ARP packets.
Procedure
- Run system-view
The system view is displayed.
- Configure rate limit on ARP packets based on source IP addresses.
Run arp anti-attack rate-limit source-ip maximum maximum
The maximum rate of ARP packets from any source IP address is set.
Run arp anti-attack rate-limit source-ip ip-address maximum maximum
The maximum rate of ARP packets from the specified source IP address is set.
When both the preceding commands are executed, the maximum rate set using the arp anti-attack rate-limit source-ip ip-address maximum maximum command takes effect on ARP packets from the specified source IP address, and the maximum rate set using the arp anti-attack rate-limit source-ip maximum maximum command takes effect on ARP packets from other source IP addresses.
By default, the device allows a maximum of 50 ARP packets from the same source IP address to pass through per second.
- Run commit
The configuration is committed.