Take the 2-minute tour ×
Ask Different is a question and answer site for power users of Apple hardware and software. It's 100% free, no registration required.

My Internet connection has been flaky for a while. I wonder what the options are to monitor and somehow store statistics (over time) for when my modem loses and regains Internet connectivity.

I wish to use this information when I contact my ISP.

I'm thinking, would something like Instruments be able to do this?

share|improve this question
add comment

1 Answer

I maintain a script that chooses a random server that's known to respond to pings, and performs 100 pings (one second apart). I run this script by hand as a first indicator to determine if I'm having a connectivity or signal quality problem.

The ping command I use is ping -c 100 [server-hostname]

I chose hostnames for my script that were known to respond to ping at the time that I wrote the script, and I tried to keep the list geographically diverse (for example by using university web servers). But this sort of technique requires maintenance, because servers don't consistently allow ping (server configurations change over time), and things like hosted servers disrupt the geographic diversity issue.

I would think that Automator might be a better fit for this sort of task than Instruments, although if you're adept with scripting (shell, python, perl, etc), you could write a script to do it and use much less memory.

As for your situation, the source(s) of failure should dictate what kind of connectivity testing you do. The problem could be due to a piece of hardware within your home/office that needs to be periodically reset, or even replaced. The ping test I describe above doesn't necessarily isolate the source of the problem.

Edit: and to address analysis/graphing, you could perform a ping test at a regular interval (every # minutes), export the packet loss percentage data in a format such as comma-separated values, and use a spreadsheet program to graph the results.

share|improve this answer
    
Thanks for your answer, bneely. Your approach in the final edit paragraph might be something I'll look into. One of the considerations that came to my mind in this approach is, if there might be some sort of ping rate threshold on the remote server, that might cause my host to be blocked from further pinging? One way around that would probably be to add and rotate a few more servers in the pink loop, to reduce the rate/payload on a single server (and the risk of being blacklisted). –  hced Dec 16 '11 at 2:45
    
A little typo there; ping loop, not pink loop. (Too bad one can't edit comments after 5 minutes here.) –  hced Dec 16 '11 at 2:52
    
Yep, you should actively plan to avoid being detected as the source of a denial-of-service type attack. I don't know what a good threshold is. –  bneely Dec 16 '11 at 2:54
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.