cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1049
Views
0
Helpful
4
Replies

ip distribute-lists question

fredluneau
Level 1
Level 1

                   I am looking to contain the advertisement and subsequent redistribution of a subnet by use of a ip prifix-list and distribution-list.  My question is, Within the specific router eigrp definition of my configuration, if I am redistributing static and redistributing connected as well as specific network statements, do I need to allow these networks, statics and connected in my prefix-list and use the explicit deny to exclude the subnet(s) I want to contain?

Haven't used prefix-lists and distribute-lists much at all.  Thanks in advance.

-Fred

1 Accepted Solution

Accepted Solutions

Hello Fred,

Okay. So assume that the networks 192.0.2.0/24 and 223.255.255.0/29 are the ones that should not be redistributed, all other should be redistributed. The commands would be:

ip prefix-list R2E deny 192.0.2.0/24

ip prefix-list R2E deny 223.255.255.0/29

ip prefix-list R2E permit 0.0.0.0/0 le 32

!

route-map Redist2EIGRP permit 10

match ip address prefix-list R2E

!

router eigrp N

redistribute static metric 100000 1 255 1 1500 route-map Redist2EIGRP

The prefix-list R2E (redistribution to EIGRP) denies the two networks and permits any other network. The 0.0.0.0/0 le 32 means that the network and its netmask can be arbitrary (the le 32 says that the mask length of the network in question shall be less or equal to 32 bits). This is the classic order of entries - first, deny the unwanted networks, then permit anything else.

As the redistribute command usually does not allow us to refer to a prefix-list directly, we need to enclose the prefix-list into a route-map. In this case, the route-map Redist2EIGRP is simply a container that refers to the prefix-list R2E. It permits anything the prefix-list permits, and it denies everything the prefix-list denies. A route-map has many other options and uses but this is how we want to use it here. And finally, we refer to the route-map in the redistribute command. You may reuse the same route-map in multiple redistribute command, although in larger deployments, it is a better practice to have a separate route-map for a separate redistribution.

Best regards,

Peter

View solution in original post

4 Replies 4

Peter Paluch
Cisco Employee
Cisco Employee

Hi Fred,

If you do not want to advertise certain redistributed routes at all, it is possible to filter them out during the redistribution. It is more effective to redistribute just those networks that you want to advertise further than to inject all routes into EIGRP database and then not allow some of them to be advertised. This filtering during redistribution would be accomplished using route-maps and prefix-lists. I will gladly post an example if this solution fits your needs.

Best regards,

Peter

Hi Peter.  Yes, I believe your suggested solution using route-maps and prefix-lists would better than what I was initially thinking.  I would welcome your posted solution.  Thank you.

-Fred

Hello Fred,

Okay. So assume that the networks 192.0.2.0/24 and 223.255.255.0/29 are the ones that should not be redistributed, all other should be redistributed. The commands would be:

ip prefix-list R2E deny 192.0.2.0/24

ip prefix-list R2E deny 223.255.255.0/29

ip prefix-list R2E permit 0.0.0.0/0 le 32

!

route-map Redist2EIGRP permit 10

match ip address prefix-list R2E

!

router eigrp N

redistribute static metric 100000 1 255 1 1500 route-map Redist2EIGRP

The prefix-list R2E (redistribution to EIGRP) denies the two networks and permits any other network. The 0.0.0.0/0 le 32 means that the network and its netmask can be arbitrary (the le 32 says that the mask length of the network in question shall be less or equal to 32 bits). This is the classic order of entries - first, deny the unwanted networks, then permit anything else.

As the redistribute command usually does not allow us to refer to a prefix-list directly, we need to enclose the prefix-list into a route-map. In this case, the route-map Redist2EIGRP is simply a container that refers to the prefix-list R2E. It permits anything the prefix-list permits, and it denies everything the prefix-list denies. A route-map has many other options and uses but this is how we want to use it here. And finally, we refer to the route-map in the redistribute command. You may reuse the same route-map in multiple redistribute command, although in larger deployments, it is a better practice to have a separate route-map for a separate redistribution.

Best regards,

Peter

Peter,

Thank you this was extremely helpful.

Regards,

-Fred