Question: how icmp works in ping command?
Answer: Ping is a computer network administration software utility used to test the reachability of a host on an Internet Protocol (IP) network. ... Ping operates by sending Internet Control Message Protocol (ICMP) echo request packets to the target host and waiting for an ICMP echo reply.