When you do a ping -c 1 of a host that is on a different subnet as you are, it never times out and returns, eventually when I do a ^C to break out of it I see that it has sent more then 1 packet: loki 14> ping -c 1 198.68.22.4 PING 198.68.22.4 (198.68.22.4) from 198.68.23.48 : 56(84) bytes of data. --- 198.68.22.4 ping statistics --- 13 packets transmitted, 0 packets received, 100% packet loss When I do the same thing on a pinloki 16> ping -c 1 198.68.22.4 PING 198.68.22.4 (198.68.22.4): 56 data bytes --- 198.68.22.4 ping statistics --- 1 packets transmitted, 0 packets received, 100% packet loss g from a Redhat 6.0 system it returns in about 30 seconds: Also, if the system you are pinging is on the same subnet as you are it works correctly. Also, the -w (waitsecs) option does not seem to work at all. This is a normal priority for most people, execept people (like me) who are doing network monitoring) with Redhat 6.1. A reasonable workaround for now is to use the ping from Rehdat 6.0.
Even though the -c option works on local subnets, the return code from ping is ALWAYS 0, despite ping's success or failure. When the destination host is unreachable, the return code should be 1, from the manpage. This will break a lot of scripts that test reachability of a certain host.
To us this is really a major problem, we need the -c flag for some of our perl scripts. Up to now we have been using ping from redhat 6.0 without problem. What is the timeline for getting this resolved?
It's fixed in Raw Hide. ping now comes from iputils, so just updating netkit-base won't help you. Update netkit-base and install iputils, and it'll work.