Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 Sep 2005 23:03:09 +0100
From:      Martin McCann <martin@orbweavers.co.uk>
To:        freebsd-questions@freebsd.org
Subject:   Re: command question..
Message-ID:  <200509082303.09458.martin@orbweavers.co.uk>
In-Reply-To: <4320A93D.2020500@earthlink.net>
References:  <4320A93D.2020500@earthlink.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thursday 08 September 2005 22:12, Eric Murphy wrote:
> Hey guys heres a quick question for you...
>
> I am trying to ping a certain website with the following command .  ping
> yahoo.com
>
> I would like to log all requests that come back higher then 100 or any #
> i specify.
>
> I figured I could use the script command but im not sure how to go from
> there?
>
> Reason for this is to prove to my ISP that there is something wrong with
> my connection :)
>
> Would it also be possible to log the date and time of each requets?
>
> So inconclusion I'd like to log all icmp requests that come back higher
> then 100 by date and time into a log file.

date > pings.txt ; ping -c 10 www.yahoo.com | awk '{ print $7 ; }' | sort >> 
pings.txt  

this will give you a file with the date then the pings sorted from quickest to 
slowest. Plenty of scope to make it nicer, but it gets you the info you want. 
(You will probably want to increase the count, but I would also add a delay, 
-i, it will give you a better range and also it is not nice to fire a lot of 
pings to a public server). 


Martin 


>
> Thanks
>
>
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "freebsd-questions-unsubscribe@freebsd.org"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200509082303.09458.martin>