[96483] in RedHat Linux List
Re: PING Program
daemon@ATHENA.MIT.EDU (Linux User)
Tue Oct 27 12:50:17 1998
Date: Tue, 27 Oct 1998 12:19:53 -0500 (EST)
From: Linux User <linuxuser@linuxtest.fellows.denison.edu>
To: redhat-list@redhat.com
In-Reply-To: <199810270138.TAA27092@isunix.it.ilstu.edu>
Resent-From: redhat-list@redhat.com
Reply-To: redhat-list@redhat.com
Thank you everyone who helped me out to get the script running,
Thanks Tim, it was educational.
And thanks Kevin for pointing me to fping
Here is the script that I finally decided to use. it works well..
____________________________________________________________________
#!/bin/sh
# Uses fping. RPM available in contrib directory, REDHAT distribution
datafile="rundata"
hostfile="hostlist"
rm -f $datafile
date > $datafile
fping -r 0 -sq -f $hostfile >> $datafile
cat $datafile | mail -s "ping results" root
exit
___________________________________________________________________
the OUTPUT looks like this :
Mon Oct 26 20:08:17 EST 1998
3060 hosts
489 alive
2571 unreachable
0 unknown addresses
5631 timeouts (waiting for response)
3060 pings sent
563 pings received
_______________________________________________________________________
Now I just need to get it into a cron job
thanks again,
Fahd Sultan
Software Techie
Denison U.
linuxuser@linuxtest.fellows.denison.edu
sultan_f@denison.edu
--
PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
http://www.redhat.com http://archive.redhat.com
To unsubscribe: mail redhat-list-request@redhat.com with
"unsubscribe" as the Subject.