Middle
How to view the routing table in Linux?
sobes.tech AI
Answer from AI
In Linux, several commands can be used to view the routing table:
route -n— displays the routing table in numeric format (without attempting to resolve names).ip route show— a modern command from the iproute2 package, shows the current routes.
Example:
route -n
or
ip route show
Both commands will display a list of routes, including network addresses, gateways, interfaces, and metrics.