Wildcard Masking - Ip Route. Why not?

RoguetadhgRoguetadhg Member Posts: 2,489 ■■■■■■■■□□
So I'm overlooking topics, and I noticed that Ip route doesn't need wildcard masks.

Considering the use of wildcard masks (ACLs,OSPF) I think it makes sense to use it with ip route. Yet it doesn't.

For example routing for a group of networks (10.0.0.0 /16 to 10.0.7.0 /16) the command I think should be correct is:
ip route 10.0.0.0 0.0.7.255 123.4.5.9

But the correct syntax for the command to forward to a group of networks is:
ip route 10.0.0.0 255.255.248.0 123.4.5.9

The "Destination Prefix Mask" isn't a subnet mask, like looking at "255.255.248.0" seems to be. These are just the examples I could think of at the top of my head with "Wild card Masks" which I will use in my argument.

OSPF: network 10.0.4.0 0.0.0.255 area 0
EIGRP: network 10.0.4.0 0.0.0.255 or "network 10.0.4.0 255.255.255.0"
ACL: access-list 1 permit 10.0.8.0 0.0.7.255

Am I wrong for thinking that Ip Route should have a "wildcard mask", and not a "Destination Prefix Mask"?
In order to succeed, your desire for success should be greater than your fear of failure.
TE Threads: How to study for the CCENT/CCNA, Introduction to Cisco Exams

Comments

  • SharkDiverSharkDiver Member Posts: 844
    Yes, the instances in which you use and don't use a wildcard mask seem to be quite random.

    I always review when to use and when to not use a wildcard mask right before I go into an exam, because it seems to have no pattern and I know I am likely to forget.
  • networker050184networker050184 Mod Posts: 11,962 Mod
    Wild card masks are generally used for matching on bits. You don't necessarily have to match on a whole network, thats just most of the examples in books because its easier to understand. When you route you are going to route a network or host. You don't need to just match on certain bits in an address. Thats my take on it anyway.

    Personally I prefer the syntax of some other vendors where you just use the CIDR notation. Much easier though I have become a pro at typing 255's repetitively! :)
    An expert is a man who has made all the mistakes which can be made.
Sign In or Register to comment.