Bug 10426 - ping -c hangs indefinitly if no packets received
ping -c hangs indefinitly if no packets received
Status: CLOSED CURRENTRELEASE
Product: Red Hat Linux
Classification: Retired
Component: iputils (Show other bugs)
6.1
All Linux
medium Severity medium
: ---
: ---
Assigned To: Crutcher Dunnavant
:
: 17121 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2000-03-29 19:51 EST by Andrew Turnquist
Modified: 2008-05-01 11:37 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-05-14 14:42:57 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Andrew Turnquist 2000-03-29 19:51:47 EST
The new version of ping in 6.2 will not exit properly if it does not
receive any packets back.

Example:
% ping -c 2 -w 10 192.168.1.2

The '-c 2' option alone should cause ping to exit after approx. 2 seconds.
The '-w 10', according to the man page should stop execution after 10
seconds, regardless of results.

If the target host is up, all works fine.  If something send back an error,
such as Host Unreachable, it exits properly as well.  However, if the
target host is down and no router (or the local machine) sends an error
back, ping blocks until it is killed.

This causes problems with scripts which use ping to test whether a host
is up or down, something we use heavily at our office for monitoring
network health.  I could spend a few hours rewriting my code to work
around the problem, but it is still a bug.

--Andrew
Comment 1 Pekka Savola 2000-07-12 11:38:16 EDT
This seems to work in 6.2 and rawhide, but not with 6.1.
Comment 2 Pekka Savola 2000-08-31 16:47:27 EDT
*** Bug 17121 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.