12-04-2009 05:05 AM - edited 03-06-2019 08:49 AM
dear experts, hello
why we use a wildcard in ospf network
configuration and not the subnet mask of the network, like net 10.0.0.0 0.0.0.255 and not net 10.0.0.0 255.255.255.0
so what is the reason for that.
thanks alot for your help
Labib Makar
Solved! Go to Solution.
12-04-2009 06:21 AM
labibmakar wrote:
dear jon,
now it became very clear for me the defference between wildcard mask and subnet mask.
sorry for my another question, you gave me an excellent example but does this example exist in the real world, or in other words when i can write an example like that ( 10.1.0.0 0.255.0.255)
Labib
Labib
In the real world more often than not a wildcard mask will simply be the inverse of a subnet mask. But it's important to remember that it doesn't have to be and there have been a few occasions on this forum where i or others have helped someone come up with a wildcard mask that matches only certain addresses for an acl.
So it really depends on your requirements within your network, but yes non-contiguous wildcard masks are used in production environments.
Jon
12-04-2009 05:12 AM
labibmakar wrote:
dear experts, hello
why we use a wildcard in ospf network
configuration and not the subnet mask of the network, like net 10.0.0.0 0.0.0.255 and not net 10.0.0.0 255.255.255.0
so what is the reason for that.
thanks alot for your help
Labib Makar
Labib
The subnet/widlcard mask combination is used by OPSF to determine which interfaces to start the OSPF process on. Subnet masks have to be contiguous but wildcard masks don't and therefore you have more flexibility with a wildcard mask in specifying which interfaces you want OSPF to run.
Jon
12-04-2009 05:48 AM
hello jon, first thank you for your help
but it's not clear for me. what is (Subnet masks have to be contiguous but wildcard masks don't )
in the calssless ip addressing we can distinguish between the network address and the host address by the subnetmask even the networks were contiguous or discontiguous.
would you mind please give me more explaination about why wildcard mask and not a subnet mask.
thanks alot for your efforts with me
Labib
12-04-2009 06:03 AM
labibmakar wrote:
hello jon, first thank you for your help
but it's not clear for me. what is (Subnet masks have to be contiguous but wildcard masks don't )
in the calssless ip addressing we can distinguish between the network address and the host address by the subnetmask even the networks were contiguous or discontiguous.
would you mind please give me more explaination about why wildcard mask and not a subnet mask.
thanks alot for your efforts with me
Labib
Labib
Apparently i have just read that OSPF requires the wild card mask to be contiguous in the same way a subnet mask has to be contiguous. However OSPF used to allow a non-contiguous wildcard mask so i guess it's a holdover from then.
What i mean by contiguous and non-contiguous.
In a subnet mask 255 means must match and 0 means don't care ie. it can be anything
In a wildcard mask 255 means don't care and 0 means must match
so
10.1.0.0 255.255.255.0 is equivalent to 10.1.0.0 0.0.0.255
but
10.1.0.0 255.0.255.0 is not a valid subnet mask ie. it makes no sense because you can't work out the network/host from this and it is not contiguous ie. you can't have 0s then 1s then 0s then 1s etc..
however
10.1.0.0 0.255.0.255 is a valid wildcard mask - what it is matching is any address that has a first octet of 10 then the 2nd octet can be anything, the third octet must be 0 and the last octet can be anything. Note when i say anything i mean a value from the range 0 - 255.
Now you cannot do that match with a subnet mask. And this is a key point. Wildcard masks in acls etc. are usually just the inverse of a subnet mask ie. 255.255.255.0 = 0.0.0.255. But they don't have to be. A wildcard mask is more than just an inverse subnet mask and it allows much more flexibility in matching addresses.
Jon
12-04-2009 06:16 AM
dear jon,
now it became very clear for me the defference between wildcard mask and subnet mask.
sorry for my another question, you gave me an excellent example but does this example exist in the real world, or in other words when i can write an example like that ( 10.1.0.0 0.255.0.255)
Labib
12-04-2009 06:21 AM
labibmakar wrote:
dear jon,
now it became very clear for me the defference between wildcard mask and subnet mask.
sorry for my another question, you gave me an excellent example but does this example exist in the real world, or in other words when i can write an example like that ( 10.1.0.0 0.255.0.255)
Labib
Labib
In the real world more often than not a wildcard mask will simply be the inverse of a subnet mask. But it's important to remember that it doesn't have to be and there have been a few occasions on this forum where i or others have helped someone come up with a wildcard mask that matches only certain addresses for an acl.
So it really depends on your requirements within your network, but yes non-contiguous wildcard masks are used in production environments.
Jon
12-04-2009 07:05 AM
thanks jon i appretiate your help
nice to talk to you
bye
labib
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: