This document provides a sample configuration on how and when to use distribute-list out command. This command only works on the routes being redistributed by Autonomous system boundary Router into OSPF. It can be applied to external type 2 and type 1 routes, but not to intra-area and interarea routes..
It is assumed that a person reading this document is familiar with Ospf.
For this document 3700 Series router with IOS 12.4(18) loaded in it.
The configuration files are attached with this document.
For this example, loopback interfaces connected to Router R1 will be redistributed in the ospf domain and R1 will serve as ASBR (see configuration attached for reference) .
We will filter network 126.96.36.199 from Area 1 for this example.
Before we move forward, lets take a look at the routing table of R3:
And, we can surely see network 188.8.131.52.
Now for filtering network 184.108.40.206 from area 1 we need to perform two tasks
We first need to configure an access-list to filter this particular network out.
Second, we need to apply that filter
This will be done at router R1, which is the ASBR for this OSPF network.
For step 1, we will create an access-list which will deny net 220.127.116.11/24 and permit all others:
For step 2, we will apply this filter:
Lets see the routing table of Router R3:
We surely don't see 18.104.22.168 network on R3. And, to prove that R2 is not sending type 5 LSA for this network in area 1, lets see the database for 22.214.171.124 network on R2: