- if you’re on (most modern distributions of) linux, forget that
route(1)
even exists (and throwifconfig
out in the same go) because it’s just absolutely frustrating. for probably 98% of what you need,ip(1)
is the cool you care about
generally speaking, these will cover you: ip route
, ip address
, ip link
- when dealing with routing problems (even if just two hosts next to each other),
mtr
>traceroute
>ping
is an order that’s useful for a lot of what you need
mtr is nice because you can just let it keep running. press d
in its display to get a running history breakdown of packets. fantastic for intermittent issues!
traceroute is generally known already, but depending on the complexity of your networks in question you may want traceroute-nanog
or similar other ones. some of these are ASN-aware, which is useful.
in the same breath as traceroute, something else that’s useful to know about is tracepath
it’s a little bit nicer on finding asymm paths
lastly, ping
is still useful in this, but if you need to start forcing specific kind of pings (pinning a specific source address, forcing a specific source interface, etc), sometimes fping
can be slightly easier, so do be aware of it as well
oh and re tcpdump, a small gotcha to also be aware of: if you do something like tcpdump -nvi any -s 0 ….[filters here]…
, you can get weird MAC stuff because of it capturing in promiscuous mode.
the wisdom of @froztbyte