Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I've inherited administration duties for a firewall/gateway server, and I'm trying to understand what a particular static route setup in rc.local means:

route add
route add

Obviously, the IP addresses have been changed to protect the innocent.

What does this mean, and why is it routed this way?

share|improve this question

3 Answers 3

up vote 5 down vote accepted

It means packets for will go via and packets for will go via

  • Since the advent of CIDR, netmasks indicate the length of the prefix - technically any IP in the network can be used, but by convention the non-masked bits are set to 0, which is why 'network addresses' are always on even numbers.

  • Most specific wins - /32 is more specific (longer) than /30, so it takes precedence over the /30.

share|improve this answer

First line: packets to hosts at are routed via, except (second line) for packets to, which are routed via

However, I suspect a anonymization error, if you really define a /30 network, the first address (same ip/32) is the "network"-address, which doesn't really get packets. It could also be, that someone tries to route a slice out of a bigger subnet differently, but it smells funny...

share|improve this answer
it's not the network-address it's the broadcast address... odd numbers are as far as I know never net addresses. A better notation for the network would be – Marcel G Sep 29 '10 at 1:06
The IP addresses were chosen for obfuscation purposes, I didn't realize that the oddness/evenness would be such a red herring to people. – Chris R Sep 30 '10 at 14:42

Are the "" addresses really the exact same in the setup you are debugging - or are they slightly different?

Assuming they are different - the first line means that anything in the network defined by should be forwarded to The second line means the specific IP address should be forwarded to

As to why - we'd need more context.

  • Can you tell me the last octet (the last .123) specifically - what exactly is it in your situation. Having two of htem the same with two different netmasks is a bit weird, and could mean a couple of different things....
share|improve this answer
They're the same, exactly. – Chris R Sep 28 '10 at 22:18
What context might you need to answer these questions? And what does it mean when the two IPs are the same? – Chris R Sep 28 '10 at 22:20

Your Answer


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.