首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >OSPF -默认路由并不是在所有区域都有广告。

OSPF -默认路由并不是在所有区域都有广告。
EN

Network Engineering用户
提问于 2018-03-01 10:47:41
回答 1查看 861关注 0票数 3

我试图找出为什么R1在他的路由表中没有默认路由,它是由我的Internet路由器传播和生成的。奇怪的是,R2实际上有一个默认路由的条目!

我很抱歉,如果这是一个非常奇怪的简单错误,很容易找到,但我只是找不到它(即使在长时间搜索和比较R1和R2之后)。

我可以这样平:

代码语言:javascript
复制
PC -----> R1
R1 -----> ABR
PC --!--> ABR
R1 --!--> Internet (I have simulated the Internet with a simple webserver)
R2 -----> Internet 
Router in the area down below the area 45 -----> Internet 

千兆位接口用于局域网,局域网被配置为被动接口.

以下是我的网络概述:

R1的配置:

代码语言:javascript
复制
en
 conf t
 no ip domain-lookup
 ipv6 unicast-routing

 int loopback 0
  ip address 1.1.1.1 255.255.255.255
  exit

 ipv6 router ospf 1
  router-id 1.1.1.1
  auto-cost reference-bandwidth 100000
  passive-interface g0/0
  area 45 range 2001:db8:18:4565::/56
  exit

 router ospf 1
  auto-cost reference-bandwidth 100000
  passive-interface g0/0
  area 45 range 10.45.65.0 255.255.255.0
  exit

 int s0/0/0
  ip address 10.45.0.6 255.255.255.252
  ipv6 address 2001:db8:18:4502::2/64
  ipv6 ospf 1 area 45
  ip ospf 1 area 45
  ip ospf hello-interval 3
  ipv6 ospf hello-interval 3
  no sh

 int g0/0
  ip address 10.45.65.1 255.255.255.0
  ipv6 add 2001:db8:18:4565::1/64
  no sh

  exit

 access-list 100 deny ip any host 224.0.0.5
 access-list 100 deny ip any host 244.0.0.6
 access-list 100 permit ip any any

 int g0/0
  ip access-group 100 in
 exit

R2的配置:

代码语言:javascript
复制
en
 conf t
 no ip domain-lookup
 ipv6 unicast-routing

 int loopback 0
  ip address 1.1.1.1 255.255.255.255
  exit

 ipv6 router ospf 1
  router-id 1.1.1.1
  auto-cost reference-bandwidth 100000
  exit

 router ospf 1
  auto-cost reference-bandwidth 100000
  network 10.45.0.0 0.0.0.3 area 45
  exit

 int s0/0/0
  ip address 10.45.0.2 255.255.255.252
  ipv6 address 2001:db8:18:4501::2/64
  ipv6 ospf 1 area 45
  ip ospf hello-interval 3
  ipv6 ospf hello-interval 3
  no sh

 int g0/0
  ip address 10.45.64.1 255.255.255.0
  ipv6 add 2001:db8:18:4564::1/64
  ipv6 ospf 1 area 45
  ip ospf hello-interval 3
  ipv6 ospf hello-interval 3
  no sh

  exit
  exit

ABR的配置:

代码语言:javascript
复制
en
 conf t
 no ip domain-lookup
 ipv6 unicast-routing

 int loopback 0
  ip address 2.2.1.1 255.255.255.255
  exit

 ipv6 router ospf 1
  area 45 range 2001:db8:18:4500::/56
  auto-cost reference-bandwidth 100000
  router-id 2.2.1.1
  exit

 router ospf 1
  area 45 range 10.45.0.0 255.255.0.0
  area 0 range 10.0.0.0 255.255.0.0
  auto-cost reference-bandwidth 100000
  network 10.45.0.0 0.0.0.255 area 45
  network 10.0.0.0 0.0.0.255 area 0

 int s0/1/0
  ip add 10.45.0.1 255.255.255.252
  ipv6 add 2001:db8:18:4501::1/64
  ipv6 ospf 1 area 45
  ip ospf hello-interval 3
  ipv6 ospf hello-interval 3
  no sh

 int s0/1/1
  ip add 10.45.0.5 255.255.255.252
  ipv6 add 2001:db8:18:4502::1/64
  ipv6 ospf 1 area 45
  ip ospf hello-interval 3
  ipv6 ospf hello-interval 3
  no sh

 int s0/0/0
  ip add 10.0.0.2 255.255.255.252
  ipv6 add 2001:db8:18:0001::2/64
  ipv6 ospf 1 area 0
  ip ospf hello-interval 3
  ipv6 ospf hello-interval 3
  no sh

 int s0/0/1
  ip add 10.0.0.6 255.255.255.252
  ipv6 add 2001:db8:18:0002::2/64
  ipv6 ospf 1 area 0
  ip ospf hello-interval 3
  ipv6 ospf hello-interval 3
  no sh

  exit

这是ABR上的“显示int"-command。

代码语言:javascript
复制
Serial0/1/0 is up, line protocol is up
  Internet address is 10.45.0.1/30, Area 45
  Process ID 1, Router ID 2.2.1.1, Network Type POINT-TO-POINT, Cost: 64
  Transmit Delay is 1 sec, State POINT-TO-POINT, Priority 0
  No designated router on this network
  No backup designated router on this network
  Timer intervals configured, Hello 3, Dead 40, Wait 40, Retransmit 5
    Hello due in 00:00:02
  Index 1/1, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 0 msec
  Neighbor Count is 1 , Adjacent neighbor count is 1
    Adjacent with neighbor 1.1.1.1
  Suppress hello for 0 neighbor(s)
Serial0/1/1 is up, line protocol is up
  Internet address is 10.45.0.5/30, Area 45
  Process ID 1, Router ID 2.2.1.1, Network Type POINT-TO-POINT, Cost: 64
  Transmit Delay is 1 sec, State POINT-TO-POINT, Priority 0
  No designated router on this network
  No backup designated router on this network
  Timer intervals configured, Hello 3, Dead 40, Wait 40, Retransmit 5
    Hello due in 00:00:02
  Index 2/2, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 0 msec
  Suppress hello for 0 neighbor(s)
Serial0/0/0 is up, line protocol is up
  Internet address is 10.0.0.2/30, Area 0
  Process ID 1, Router ID 2.2.1.1, Network Type POINT-TO-POINT, Cost: 64
  Transmit Delay is 1 sec, State POINT-TO-POINT, Priority 0
  No designated router on this network
  No backup designated router on this network
  Timer intervals configured, Hello 3, Dead 40, Wait 40, Retransmit 5
    Hello due in 00:00:02
  Index 3/3, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 0 msec
  Neighbor Count is 1 , Adjacent neighbor count is 1
    Adjacent with neighbor 3.3.3.3
  Suppress hello for 0 neighbor(s)
Serial0/0/1 is up, line protocol is up
  Internet address is 10.0.0.6/30, Area 0
  Process ID 1, Router ID 2.2.1.1, Network Type POINT-TO-POINT, Cost: 64
  Transmit Delay is 1 sec, State POINT-TO-POINT, Priority 0
  No designated router on this network
  No backup designated router on this network
  Timer intervals configured, Hello 3, Dead 40, Wait 40, Retransmit 5
    Hello due in 00:00:02
  Index 4/4, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 0 msec
  Neighbor Count is 1 , Adjacent neighbor count is 1
    Adjacent with neighbor 4.4.4.4
  Suppress hello for 0 neighbor(s)

R1上的命令没有显示任何内容。

EN

回答 1

Network Engineering用户

发布于 2018-03-01 14:12:21

错误是,我在R1和R2上配置了相同的路由器-id,但这不起作用!

两个路由器可以有相同的接触器-id,但不是当有相同的邻居!一个路由器不能通过连接两个具有相同路由器id的路由器来“做OSPF”!

然而,正如@Karl指出的那样,在两个或多个路由器上配置相同的路由器id总是一个问题,因为LSA包含广告路由器的路由器id。除此之外,还可能出现更多的问题。

但是,连接到PC1的R1仍然不能平移ABR.

票数 2
EN
页面原文内容由Network Engineering提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://networkengineering.stackexchange.com/questions/48751

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档