Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

This is very much a learning question if someone would be happy to explain a couple of concepts. My question is - the default routing table that exists in, in my case, a default Windows 7 install, what do each of the routes in the table do?

Here is a screenshot:

enter image description here

The 10.128.4.0 is just a route I've added while messing.

I understand from a question I posted on Superuser the first route is just a default route that will route all traffic for any IP to my default gateway on my Interface in use. But what about the others? And how would the routing table handle a machine with multiple NIC's, perhaps connected to two different networks, or maybe even two NIC's on the same network so a VM can have a physical Network card instead of each VM sharing the hosts.

Thanks!

share|improve this question

2 Answers 2

up vote 2 down vote accepted

The routing entries direct traffic to various networks to the respective interfaces. Traffic to 127.0.0.0/8 (localhost) goes to the interface with the address 127.0.0.1. Traffic to 192.168.0.0/24 (the LAN) goes to the interface with the address 192.168.0.5. Multicast traffic (224.0.0.0/4) as well as broadcast traffic (255.255.255.255/32) first goes to the interface with the address 192.168.0.5, and if that interface should be unavailable it goes to the interface with the address 127.0.0.1 (this is controlled via the metric, smaller value means higher preference).

If the host is multi-homed (i.e. has more than one external interface), that interface has its own address and associated rules. If two interfaces have addresses from the same network range, they'll both have a network route, thus it's not too good an idea to do that (and for other reasons as well).

An additional network interface dedicated to VM traffic should not be shared with the host OS, and will thus have neither an IP address nor a route.

share|improve this answer

the "Interface" column represents which networking (either physical network card or VPN) the route is for. But keep in mine that a network card can be tied to more then one IP (so just because you see multiple IP interfaces doesn't mean you have multiple cards)

in this case '127.0.0.1' is the Loopback interface and 192.168.0.5 is the LAN card

You can only have one default route, so any given IP will almost always have one possible routing solution (either Loopback or Ethernet in this case)

If you did have two networking interfaces tied to the same network (i.e. route), it would pick the route with the lower metric (which is a representation of the speed of the network - including how much data is currently being sent through it, latency, etc http://en.wikipedia.org/wiki/Metrics_(networking)) - which is why the very first route (to your local router @192.168.0.1) is the lowest number - that's the one it will always try last

You'll see a couple lines with the same route, but one is for interface 127.0.0.1 and the other is 192.168.0.5 - the 127 one is always higher because it has less traffic (because most traffic is going through the Ethernet) - It tries that first and then when it gets no response it tries the next lowest metric until it gets to the default gatway

That way it always picks the interface w/ the lowest utilization (and the most available bandwidth)

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.