通过SSH连接,运行以下命令以禁止Ping请求:
sysctl -w net.ipv4.icmp_echo_ignore_all=1
sysctl -p
开启Ping请求:
sysctl -w net.ipv4.icmp_echo_ignore_all=0
sysctl -p
sysctl -w net.ipv4.icmp_echo_ignore_all=1
sysctl -p
开启Ping请求:
sysctl -w net.ipv4.icmp_echo_ignore_all=0
sysctl -p