Перейти к содержимому
Калькуляторы

OSPF и несколько дефолтов на группу свичей

Вот такая топология <R4> -=OSPF=- <R6> -=BGP=- <R7>

 

прописывем статический дефолт

R6#show run | i ip route
ip route 0.0.0.0 0.0.0.0 Null0

в оспф говорим сгенерить дефолт

R6# sh run | s ospf
router ospf 1
network 150.1.6.0 0.0.0.255 area 1
network 155.1.67.0 0.0.0.255 area 2
network 155.1.146.0 0.0.0.255 area 1
default-information originate metric 60

вуаля

R4#show ip route | i 0.0.0.0
Gateway of last resort is 155.1.146.6 to network 0.0.0.0
O*E2  0.0.0.0/0 [110/60] via 155.1.146.6, 00:02:02, GigabitEthernet1.146

 

добавляем дефолт еще на одном рутере

R1#sh run | i ip route
ip route 0.0.0.0 0.0.0.0 Null0
R1#sh run | s ospf    
ip ospf network point-to-multipoint non-broadcast
router ospf 1
network 150.1.1.0 0.0.0.255 area 0
network 155.1.0.0 0.0.0.255 area 0
network 155.1.13.0 0.0.0.255 area 4
network 155.1.146.0 0.0.0.255 area 1
default-information originate metric 60

и вот уже два дефолта

R4#show ip ro | b 0.0.0.0
Gateway of last resort is 155.1.146.6 to network 0.0.0.0

O*E2  0.0.0.0/0 [110/60] via 155.1.146.6, 00:02:04, GigabitEthernet1.146
               [110/60] via 155.1.146.1, 00:01:54, GigabitEthernet1.146

 

Убираем статику, делаем ebgp

R6#show ip ro | i 0.0.0.0
Gateway of last resort is 150.1.7.7 to network 0.0.0.0
B*    0.0.0.0/0 [20/0] via 150.1.7.7, 00:01:08

маршрут также прилетает
R4#show ip ro | i 0.0.0.0
Gateway of last resort is 155.1.146.6 to network 0.0.0.0
O*E2  0.0.0.0/0 [110/60] via 155.1.146.6, 00:01:31, GigabitEthernet1.146

 

Заменяемся на ibgp

Пришел дефолт
R6#show ip ro | i 0.0.0.0
Gateway of last resort is 150.1.7.7 to network 0.0.0.0
B*    0.0.0.0/0 [200/0] via 150.1.7.7, 00:00:12

а в ospf ничего
R4#show ip ro | i 0.0.0.0
R4#

делаем
R6(config)#router bgp 6
R6(config-router)#bgp redistribute-internal 

и вуаля
R4#show ip ro | i 0.0.0.0
Gateway of last resort is 155.1.146.6 to network 0.0.0.0
O*E2  0.0.0.0/0 [110/60] via 155.1.146.6, 00:00:24, GigabitEthernet1.146

 

Похоже что это относится не только к редистрибьюции, но и к дефолту

Unable to Redistribute iBGP Learnt Routes into an IGP such as EIGRP, OSPF

 

Route Redistribution is used to propagate routes learned with the use of one protocol, into another routing protocol. When BGP is redistributed into an IGP, only eBGP learned routes get redistributed. The iBGP learned routes known on the router are not introduced into the IGP in order to prevent routing loops from being formed.

 

By default, iBGP redistribution into IGP is disabled. Issue the bgp redistribute-internal command in order to enable redistribution of iBGP routes into IGP. Precautions need to be taken to redistribute specific routes using route maps into IGP.

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Гость
Ответить в тему...

×   Вставлено в виде отформатированного текста.   Вставить в виде обычного текста

  Разрешено не более 75 смайлов.

×   Ваша ссылка была автоматически встроена.   Отобразить как ссылку

×   Ваш предыдущий контент был восстановлен.   Очистить редактор

×   Вы не можете вставить изображения напрямую. Загрузите или вставьте изображения по ссылке.