Python Forum
ping program in python
Thread Rating:
  • 2 Vote(s) - 4.5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
ping program in python
#1
i want to write a new ping program in python. but i want it to differ from the classic ping program in the following ways:

1. timing that does not accumulate offsets or errors. this means that for each event this program does, it first determine when the event should happen, then calculates the time interval to the next event.

2. it should accept multiple addresses and ping them in ordered rotation or random select with a consistent spread of the addresses of the of rotation. it should be possible to specify the interval of time between each rotation cycle.

3. it should be able to use a number of methods to ping a remote host, such as ICMP or UDP or TCP.

4. it should be able to decide if a remote host is up or down reliably based on a number of ways and take an action when the condition is met.
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply
#2
Most of the servers don't respond to ICMP requests. Checking if the server is down is better to be done by requesting for a service on some port and see the response status code.
"As they say in Mexico 'dosvidaniya'. That makes two vidaniyas."
https://freedns.afraid.org
Reply
#3
(Jun-23-2018, 10:42 AM)wavic Wrote: Most of the servers don't respond to ICMP requests. Checking if the server is down is better to be done by requesting for a service on some port and see the response status code.
i'm sure i'd know whether or not my servers are responding to ICMP echo requests within my networks. BTW, i have noticed that some ISPs and many business networks discard outbound (at their border) ICMP echo requests. that might be a common cause of the issue. still, i see a majority of servers do respond. and this is why i plan to have various other options to "ping" another host, including DNS and other protocol based requests. and i may also want to only consider timely responses and a consistent sequence of responses as "up".
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Need to build a ping test for work network austina2 2 3,469 Mar-11-2019, 06:58 PM
Last Post: austina2
  TCP ping time mesure diffrence from other tools tbaror 2 3,320 Dec-25-2017, 08:57 PM
Last Post: wavic

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020