linux服务器禁止ping和允许ping的方法
禁止ping
echo 1 >/proc/sys/net/ipv4/icmp_echo_ignore_all
允许ping
echo 0 >/proc/sys/net/ipv4/icmp_echo_ignore_all
禁止ping
echo 1 >/proc/sys/net/ipv4/icmp_echo_ignore_all
允许ping
echo 0 >/proc/sys/net/ipv4/icmp_echo_ignore_all