Closed ktaog6 closed 3 years ago
Hi @ktaog6,
Yes, if the last address is not the one you want to reach, there are two possible causes:
ping
function or your system's ping command), more than 30 hops (default) may be needed to reach it. You can try increasing the max_hops
parameter of the traceroute
function. It should work.
Example: traceroute('192.168.46.25', max_hops=64)
ping
command, either the remote machine is off or its firewall is blocking ICMP requests.For your second deduction, you are also right. Hosts 4 through 20 did not respond. Some routers, like these, are configured not to send ICMP Time Exceeded messages for security reasons.
I hope I've helped you.
ok, thanks.
Hi,
when i use traceroute module, the last address not my address in output, does it mean the address can't reach ? And Hop 3 to Hop 21 means 4~20 not response ?
Example:
Python 3.8.5 (default, Sep 22 2020, 23:34:13) [GCC 4.8.5 20150623 (Red Hat 4.8.5-36)] on linux Type "help", "copyright", "credits" or "license" for more information.