NT/2000/XP: Display or view the Windows routing table

Contributor Icon Contributed by qmchenry Date Icon June 15, 2004  
Tag Icon Tagged: Windows networking

During troubleshooting and system configuration, it is sometimes helpful to get a look at a host’s routing table. This recipe describes viewing the routing table from the command prompt in Windows.


From a command prompt, type the following command to view the complete routing table:

route print

This will display a list of the active network interfaces by name and MAC address, all active routes, and all persistent routes. A persistent route is one that will still be around after a reboot.

The active route information includes the Network Destination, Netmask, Gateway, Interface, and Metric. The Network Destination and Netmask describe the destination of the route. The Gateway is the IP address through which packets must be routed to get to the destination network. The Interface represents the IP address on the network interface on the local system that will be used to reach the gateway. The Metric is a cost associated with the route. Given two routes to the same destination network, the route with the lowest cost will be used.

For UNIX users, the familiar command below will also display the routing table on a Windows host:

netstat -r

Previous recipe | Next recipe |
 
blog comments powered by Disqus