Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Community Member

redistribute ospf question

In my lab,I don't know why 6.2.1.0/24 is redistributed into ospf 2,and 99.128.1.0/24 doesn't.

From cisco document:http://www.cisco.com/en/US/tech/tk365/technologies_tech_note09186a008009487e.shtml. Cisco said "Note: The mechanics of route redistribution is proprietary on Cisco routers. The rules for redistribution on a Cisco router dictate that the redistributed route be present in the routing table. It is not sufficient that the route be present in the routing topology or database. "

And in my lab,these two static route is "static" in routing table,So why one can be redistributed via "redistribute ospf 1" and another doesn't ?

thanks!

230#sh run | b r o

router ospf 1

log-adjacency-changes

redistribute static subnets

network 6.0.0.0 0.127.255.255 area 0

!

router ospf 2

log-adjacency-changes

redistribute ospf 1 subnets

network 6.128.0.0 0.127.255.255 area 0

!

ip classless

ip route 6.2.1.0 255.255.255.0 Null0

ip route 99.128.1.0 255.255.255.0 Null0

230#sh ip ospf da

OSPF Router with ID (99.1.133.230) (Process ID 2)

Router Link States (Area 0)

Link ID ADV Router Age Seq# Checksum Link count

99.1.133.230 99.1.133.230 100 0x80000002 0x00C540 1

Type-5 AS External Link States

Link ID ADV Router Age Seq# Checksum Tag

6.1.1.0 99.1.133.230 100 0x80000001 0x002DAD 0

6.2.1.0 99.1.133.230 100 0x80000001 0x0021B8 0

OSPF Router with ID (99.129.1.1) (Process ID 1)

Router Link States (Area 0)

Link ID ADV Router Age Seq# Checksum Link count

99.129.1.1 99.129.1.1 123 0x80000002 0x006FE9 1

Type-5 AS External Link States

Link ID ADV Router Age Seq# Checksum Tag

6.2.1.0 99.129.1.1 122 0x80000001 0x00DED1 0

99.128.1.0 99.129.1.1 128 0x80000001 0x0033A1 0

230#sh ip route static

99.0.0.0/8 is variably subnetted, 16 subnets, 3 masks

S 99.128.1.0/24 is directly connected, Null0

6.0.0.0/24 is subnetted, 3 subnets

S 6.2.1.0 is directly connected, Null0

230#

4 REPLIES
Cisco Employee

Re: redistribute ospf question

Hi,

Your database output shows additional routers "99.1.133.230" and "99.129.1.1", who also could contribute to your puzzle.

Could you please provide the output of "show ip ospf database external", which should help to clarify the situation.

The puzzle for me is, why those static routes show up in OSPF 2 in the first place. "redistribute ospf 1" can be rephrased to "Redistribute everything inserted into the routing table by process OSPF 1". Both static routes should not be redistributed this way, as they are no OSPF routes.

So please provide the config of the other OSPF routers in your lab and the output from "show ip ospf database external".

regards, Martin

Community Member

Re: redistribute ospf question

There isn't any other routers in my lab. "99.1.133.230" and "99.129.1.1" is the same router.

You puzzle is for me,too.

230#sh ip ospf da ex

OSPF Router with ID (99.1.133.230) (Process ID 2)

Type-5 AS External Link States

LS age: 787

Options: (No TOS-capability, DC)

LS Type: AS External Link

Link State ID: 6.1.1.0 (External Network Number )

Advertising Router: 99.1.133.230

LS Seq Number: 80000021

Checksum: 0xECCD

Length: 36

Network Mask: /24

Metric Type: 2 (Larger than any link state path)

TOS: 0

Metric: 1

Forward Address: 0.0.0.0

External Route Tag: 0

LS age: 787

Options: (No TOS-capability, DC)

LS Type: AS External Link

Link State ID: 6.2.1.0 (External Network Number )

Advertising Router: 99.1.133.230

LS Seq Number: 80000021

Checksum: 0xE0D8

Length: 36

Network Mask: /24

Metric Type: 2 (Larger than any link state path)

TOS: 0

Metric: 1

Forward Address: 0.0.0.0

External Route Tag: 0

OSPF Router with ID (99.129.1.1) (Process ID 1)

Type-5 AS External Link States

LS age: 1353

Options: (No TOS-capability, DC)

LS Type: AS External Link

Link State ID: 6.2.1.0 (External Network Number )

Advertising Router: 99.129.1.1

LS Seq Number: 80000021

Checksum: 0x9EF1

Length: 36

Network Mask: /24

Metric Type: 2 (Larger than any link state path)

TOS: 0

Metric: 20

Forward Address: 0.0.0.0

External Route Tag: 0

LS age: 1354

Options: (No TOS-capability, DC)

LS Type: AS External Link

Link State ID: 99.128.1.0 (External Network Number )

Advertising Router: 99.129.1.1

LS Seq Number: 80000021

Checksum: 0xF2C1

Length: 36

Network Mask: /24

Metric Type: 2 (Larger than any link state path)

TOS: 0

Metric: 20

Forward Address: 0.0.0.0

External Route Tag: 0

230# sh ip int brief

Interface IP-Address OK? Method Status Protocol

Ethernet0/0 99.1.64.230 YES NVRAM up up

Ethernet0/1 unassigned YES NVRAM administratively down down

Loopback0 99.1.133.230 YES NVRAM up up

Loopback1 99.129.1.1 YES NVRAM up up

Loopback3 6.1.1.1 YES NVRAM up up

Loopback4 6.128.1.1 YES NVRAM up up

230#

230#sh ip ospf nei

230#

regards

Re: redistribute ospf question

This is an observation. I can't help but note:

router ospf 1

redistribute static subnets

network 6.0.0.0 0.127.255.255 area 0

ip route 6.2.1.0 255.255.255.0 Null0

ip route 99.128.1.0 255.255.255.0 Null0

The route that makes it to OSPF 2 just happens to be a match to the network statement in OSPF 1. The network statement includes all interfaces having addresses from 6.0.0.0 to 6.128.255.255. I don't think that should have any relevance, but it strikes me as interesting with the difference between the two routes. I presume 99.1.133.230 is an interface address on the local router? Where is 99.129.1.1? again I suspect it is local, but it would be nice to confirm. I would be tempted fo force the OSPF router ID on the two processes for clarity. I would also be tempted to add another static that matched the network statement, just to see what hapenned.

Community Member

Re: redistribute ospf question

thanks for your guide. It have relevance.

I think that "ip route ... interface" in CISCO is special static route. In my lab,6.2.1.0/24 is one route in OSPF 1 because CISCO think this route is connected route in OSPF 1 domain. So it was redistributed into OSPF 2.

If I change route from "null 0 " to ip address,for example:

ip route 6.2.1.0 255.255.255.0 99.128.1.3

This route wasn't redistributed to OSPF 2.

"ip route ... interface" is special route type.

When you do "redis connected",this type route wasn't redistributed .You must do "redis static".

So I don't know why CISCO do this, but it do.

Sometime this route is regarded as connected route when you redistribute between dynamic routing protocol or doesn't redistribute. Sometime it is regarded as static route if you redistribute from static to dynamic routing protocol.

I'm in puzzle.

thanks!

155
Views
0
Helpful
4
Replies
CreatePlease to create content