Windows’ Wonderful Network Routing

Update: I’ve since realised (after doing this on another machine) that if you enable the RRAS (Routing and Remote Access) service under Server 2003, it actually does behave in the correct manner.

Why can Linux just do this out of the box, eh?

Running multiple NICs, on different networks, is not something I’ve had to do before with Windows. I’ve always been using Cisco routers or *nix-based devices for my routing needs. However, I came across something really quite annoying when I was fiddling with the above.

Imagine this: A Windows 2003 Server VM, with two virtual NICs. One has a public IP configured, bridged to the Public Address LAN, and the other has a private IP configured (which was obviously bridged to our internal Gigabit LAN.)

Now, possibly for reasons of clarity, 2K3 issues a notification when you configure more than one default gateway, if they’re from differing networks. Something to do with it not working well in load-balancing situations. Fair enough. But I immediately think that if it’s going to complain about something like that, then it obviously doesn’t need a second default gateway, and indeed it shouldn’t (as the networks are in completely separate IP ranges – it should work out where best to send it.)

Unfortunately, someone forgot to mention to Mr. Microsoft, that the term ‘default gateway’ is otherwise known as a ‘gateway of last resort’ and not the ‘gateway of only resort’!

So for the last few hours or so I’d been racking my brains over why connections to the internal LAN weren’t being routed back. The last thing I thought to check, was the damned Windows Server. Why on Earth would it ever decide to route packets for a 10.16.0.0 address over it’s default gateway on another network, when it’s already connected to 10.16.0.0 directly?!

Setting a default gateway (ignoring any notifications) for the internal LAN fixed it immediately. Grr.

Leave a Reply

You must be logged in to post a comment.