icmp_ratemask bitmap
时间:2010-10-09 来源:gaocheng
icmp_ratemask
Mask made of ICMP types for which rates are being limited.
Significant bits: IHGFEDCBA9876543210
Default mask: 0000001100000011000 (6168)
Bit definitions (see include/linux/icmp.h):
- 0 Echo Reply
- 3 Destination Unreachable *
- 4 Source Quench *
- 5 Redirect
- 8 Echo Request
- B Time Exceeded *
- C Parameter Problem *
- D Timestamp Request
- E Timestamp Reply
- F Info Request
- G Info Reply
- H Address Mask Request
- I Address Mask Reply
* - rate limited by default (see default mask above)
通过脚本配置
#!/bin/sh
#enable ping rate limit
cat /proc/sys/net/ipv4/icmp_ratemask | while read netmask; do
echo $netmask
let "netmask |= 1"
echo $netmask > /proc/sys/net/ipv4/icmp_ratemask
done
相关阅读 更多 +