Advertisement

There's no such thing as a stupid question, but they're the easiest to answer.
Login
Search

Advertisement

All Other Software All Other Software
Search Search
Search for:
Tech Support Guy > > >

timestamping a ping request


(!)

Techmonkeys's Avatar
Techmonkeys Techmonkeys is offline
Senior Member with 625 posts.
THREAD STARTER
 
Join Date: Feb 2005
Location: West Yorks
Experience: Advanced
29-Mar-2006, 11:01 AM #1
timestamping a ping request
As you know you know you can run a constant ping against an address using the -t switch.

You can also send the results of the ping to a text file using the "> c:\blah.txt" at the end of the ping command.

My question is, is it possible to timestamp the ping reply in the text file? so that you could run a constant ping and see the times it stopped replying?

so the output would look like:

Quote:
[15:36:23] Reply from 127.0.0.1: bytes=32 time<10ms TTL=128
[15:36:24] Reply from 127.0.0.1: bytes=32 time<10ms TTL=128
or something similar? or is there a 3rd party app that may do it?

p.s. should this be in the networking section of the site?
lotuseclat79's Avatar
Member with 20,583 posts.
 
Join Date: Sep 2003
Location: -71.45091, 42.27841
29-Mar-2006, 07:40 PM #2
Hi The_KiD,

Since the default ping command issues 4 ping requests at a time, in order to attach a date-timestamp to each request's reply would require the ping command be modified, however, it contains no interface to do so.

The only way to accomplish this would be to write a script and combine one date-timestamp for all 4 replies, or reduce the count of the ping command by using the parameters: ping -n 1 <host ip address>.

The script would have to use a different command than the time /t command to get the second resolution, since the default format for using /t is in format hh:mm rather than in hh:mm:ss. However, combined with the -n 1 count it might be done.

Perhaps an inline answer to the time command could be induced in the script to simulate the ENTER response to not reset the time, but get the hh:mm:ss response to use in the output you desire.

-- Tom
__________________
The independence created by philosophical insight is - in my opinion - the mark of distinction
between a mere artisan or specialist and a real seeker after truth. - Einstein 1944
Imagination is more important than knowledge. - Einstein
Squashman's Avatar
Trusted Advisor with 19,648 posts.
 
Join Date: Apr 2003
Location: 1265 Lombardi Ave
30-Mar-2006, 09:57 AM #3
Techmonkeys's Avatar
Techmonkeys Techmonkeys is offline
Senior Member with 625 posts.
THREAD STARTER
 
Join Date: Feb 2005
Location: West Yorks
Experience: Advanced
31-Mar-2006, 11:08 AM #4
Squashman, if it were possible to ftp a hug to someone I would

Thanks mate thats exactly what I needed.

Thanks also to lotuseclat, however my programming skills died with turbo pascal
As Seen On

BBC, Reader's Digest, PC Magazine, Today Show, Money Magazine
WELCOME TO TECH SUPPORT GUY!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.


(clock)
THIS THREAD HAS EXPIRED.
Are you having the same problem? We have volunteers ready to answer your question, but first you'll have to join for free. Need help getting started? Check out our Welcome Guide.

Search Tech Support Guy

Find the solution to your
computer problem!




Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


WELCOME
You Are Using: Server ID
Trusted Website Back to the Top ↑