Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $ python ping_remote_host.py --target-host=www.altsci.com
- Ping to www.altsci.com...
- Traceback (most recent call last):
- File "ping_remote_host.py", line 124, in <module>
- pinger.ping()
- File "ping_remote_host.py", line 107, in ping
- delay = self.ping_once()
- File "ping_remote_host.py", line 93, in ping_once
- raise socket.error(msg)
- socket.error: Operation not permitted need root privs to send icmp
- $ sudo python ping_remote_host.py --target-host=www.altsci.com
- Password:
- Ping to www.altsci.com... Ping failed. (timeout within 2sec.)
- Ping to www.altsci.com... Ping failed. (timeout within 2sec.)
- Ping to www.altsci.com... Ping failed. (timeout within 2sec.)
- Ping to www.altsci.com... Ping failed. (timeout within 2sec.)
- $ ping www.altsci.com
- PING www.altsci.com (216.218.134.11): 56 data bytes
- 64 bytes from 216.218.134.11: icmp_seq=0 ttl=53 time=30.533 ms
- 64 bytes from 216.218.134.11: icmp_seq=1 ttl=53 time=29.473 ms
- 64 bytes from 216.218.134.11: icmp_seq=2 ttl=53 time=30.423 ms
- ^C
- --- www.altsci.com ping statistics ---
- 3 packets transmitted, 3 packets received, 0.0% packet loss
- round-trip min/avg/max/stddev = 29.473/30.143/30.533/0.476 ms
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement