Pinging host for a lot of time

TL;DR: use this program to track if a host up or down using ping.

Sometimes for some kind of a check, I need to ping a host for a lot of time and see when the ping wasn’t successful. The familiar ping program doesn’t fit that purpose. Ping’s lines will scroll back, and if at some point ping will be unsuccessful, there is no way to know when it happened.

I searched google for a program that will log pings and tell when they were successful and when they were not. Found some for free and some programs that costs money.

I created a simple python script that will do just that. In addition I compiled the script to executable file for windows.

The program will ping destination and print the time when the ping was successful or not. After that it will print every time the destination changes it’s status. Output example:

./ -s
system up at 2018-04-02 10:37:05.976400
system down at 2018-04-02 10:37:19.039902
system up at 2018-04-02 10:37:26.063647

The program source code and executable file can be downloaded from my github page.

One Reply to “Pinging host for a lot of time”

  1. This site was… how do I say it? Relevant!! Finally I’ve found something which helped me.


    P.S. If you have a minute, would love your feedback on my new website re-design. You can find it by searching for “royal cbd” – no sweat if you can’t.

    Keep up the good work!

Leave a Reply

Your email address will not be published. Required fields are marked *