Тестирую на GNS3 топологию перед вводомв продакт.
В общем стоит задача, чтобы на ядро прилетал 0.0.0.0 через оспф, как сделать я понял (default-route originate). Не понял как сделать, чтобы при падении линка провайдера не анонсировать дефолт роут? Чтобы на ядре дефолт роут менялся с 253 на 252 или наоборот.
R1 - Собсна ядро
R3 R4 пограничные в офисе подключенные к разным провам.
R4 R5 удаленные площадки.
ISP ISP2 эмуляция провайдера. Но это не важно.
Важно то, что все роутеры соединены туннелями, туннели на примере подняты на обычных интерфейсах для упрощения.
КонфигR1=============================
interface FastEthernet0/0
ip address 10.0.0.254 255.255.255.0
duplex auto
speed auto
!
interface FastEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface FastEthernet1/0
no ip address
shutdown
duplex auto
speed auto
!
router ospf 1
router-id 172.16.254.254
log-adjacency-changes
network 10.0.0.0 0.0.0.255 area 0
!
no ip classless
R1#sh ip route
......
Gateway of last resort is 10.0.0.253 to network 0.0.0.0 <<<<<<<< Дефолт от 253
172.16.0.0/30 is subnetted, 4 subnets
O 172.16.0.4 [110/11] via 10.0.0.253, 00:03:19, FastEthernet0/0
O 172.16.1.4 [110/11] via 10.0.0.252, 00:03:19, FastEthernet0/0
O 172.16.0.0 [110/20] via 10.0.0.253, 00:03:19, FastEthernet0/0
O 172.16.1.0 [110/20] via 10.0.0.252, 00:03:19, FastEthernet0/0
10.0.0.0/24 is subnetted, 2 subnets
C 10.0.0.0 is directly connected, FastEthernet0/0
O 10.0.4.0 [110/30] via 10.0.0.253, 00:03:19, FastEthernet0/0
[110/30] via 10.0.0.252, 00:03:21, FastEthernet0/0
O*E2 0.0.0.0/0 [110/1] via 10.0.0.253, 00:03:21, FastEthernet0/0 <<<<<< Дефолт от 253
[110/1] via 10.0.0.252, 00:03:21, FastEthernet0/0 <<<<<< Дефолт от 252
R1#sh ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface
172.16.254.2 1 FULL/DROTHER 00:00:31 10.0.0.252 FastEthernet0/0
172.16.254.3 1 FULL/BDR 00:00:37 10.0.0.253 FastEthernet0/0
R1#
R1=============================
R3=============================
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.10
encapsulation dot1Q 10
ip address 10.0.0.253 255.255.255.0
!
interface FastEthernet0/0.100
encapsulation dot1Q 100
ip address 100.0.0.2 255.255.255.0
!
interface FastEthernet0/1
ip address 172.16.0.1 255.255.255.252
duplex auto
speed auto
!
interface FastEthernet1/0
ip address 172.16.0.5 255.255.255.252
duplex auto
speed auto
!
router ospf 2
log-adjacency-changes
!
router ospf 1
router-id 172.16.254.3
log-adjacency-changes
network 10.0.0.0 0.0.0.255 area 0
network 172.16.0.0 0.0.255.255 area 0
default-information originate always
!
ip route 0.0.0.0 0.0.0.0 100.0.0.1
R3#sh ip ro
....
Gateway of last resort is 100.0.0.1 to network 0.0.0.0
100.0.0.0/24 is subnetted, 1 subnets
C 100.0.0.0 is directly connected, FastEthernet0/0.100
172.16.0.0/30 is subnetted, 3 subnets
C 172.16.0.4 is directly connected, FastEthernet1/0
C 172.16.0.0 is directly connected, FastEthernet0/1
O 172.16.1.0 [110/11] via 172.16.0.2, 00:49:52, FastEthernet0/1
10.0.0.0/24 is subnetted, 2 subnets
C 10.0.0.0 is directly connected, FastEthernet0/0.10
O 10.0.4.0 [110/20] via 172.16.0.2, 00:49:52, FastEthernet0/1
S* 0.0.0.0/0 [1/0] via 100.0.0.1
R3#sh ip osp nei
Neighbor ID Pri State Dead Time Address Interface
172.16.254.2 1 FULL/DROTHER 00:00:36 10.0.0.252 FastEthernet0/0.10
172.16.254.254 1 FULL/DR 00:00:38 10.0.0.254 FastEthernet0/0.10
172.16.254.4 1 FULL/DR 00:00:38 172.16.0.2 FastEthernet0/1
R3#
R3=============================
R2=============================
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.10
encapsulation dot1Q 10
ip address 10.0.0.252 255.255.255.0
!
interface FastEthernet0/0.100
encapsulation dot1Q 100
ip address 100.0.1.2 255.255.255.0
!
interface FastEthernet0/1
ip address 172.16.1.1 255.255.255.252
duplex auto
speed auto
!
interface FastEthernet1/0
ip address 172.16.1.5 255.255.255.252
duplex auto
speed auto
!
router ospf 1
router-id 172.16.254.2
log-adjacency-changes
network 10.0.0.0 0.0.0.255 area 0
network 172.16.0.0 0.0.255.255 area 0
default-information originate always
!
ip route 0.0.0.0 0.0.0.0 100.0.1.1
R2#sh ip route
.....
Gateway of last resort is 100.0.1.1 to network 0.0.0.0
100.0.0.0/24 is subnetted, 1 subnets
C 100.0.1.0 is directly connected, FastEthernet0/0.100
172.16.0.0/30 is subnetted, 4 subnets
O 172.16.0.4 [110/11] via 10.0.0.253, 00:00:54, FastEthernet0/0.10
C 172.16.1.4 is directly connected, FastEthernet1/0
O 172.16.0.0 [110/20] via 172.16.1.2, 00:00:54, FastEthernet0/1
[110/20] via 10.0.0.253, 00:00:54, FastEthernet0/0.10
C 172.16.1.0 is directly connected, FastEthernet0/1
10.0.0.0/24 is subnetted, 2 subnets
C 10.0.0.0 is directly connected, FastEthernet0/0.10
O 10.0.4.0 [110/20] via 172.16.1.2, 00:00:56, FastEthernet0/1
S* 0.0.0.0/0 [1/0] via 100.0.1.1
R2#sh ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface
172.16.254.4 1 FULL/DR 00:00:34 172.16.1.2 FastEthernet0/1
172.16.254.3 1 FULL/BDR 00:00:34 10.0.0.253 FastEthernet0/0.10
172.16.254.254 1 FULL/DR 00:00:36 10.0.0.254 FastEthernet0/0.10
R2#
R2=============================
R4=============================
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.10
encapsulation dot1Q 10
ip address 10.0.4.1 255.255.255.0
!
interface FastEthernet0/0.100
encapsulation dot1Q 100
ip address 100.1.0.2 255.255.255.0
!
interface FastEthernet0/1
ip address 172.16.0.2 255.255.255.252
duplex auto
speed auto
!
interface FastEthernet1/0
ip address 172.16.1.2 255.255.255.252
duplex auto
speed auto
!
router ospf 2
log-adjacency-changes
!
router ospf 1
router-id 172.16.254.4
log-adjacency-changes
network 10.0.4.0 0.0.0.255 area 0
network 172.16.0.0 0.0.255.255 area 0
!
ip route 0.0.0.0 0.0.0.0 100.1.0.1
R4#sh ip route
.....
Gateway of last resort is 100.1.0.1 to network 0.0.0.0
100.0.0.0/24 is subnetted, 1 subnets
C 100.1.0.0 is directly connected, FastEthernet0/0.100
172.16.0.0/30 is subnetted, 4 subnets
O 172.16.0.4 [110/11] via 172.16.0.1, 00:02:42, FastEthernet0/1
O 172.16.1.4 [110/2] via 172.16.1.1, 00:02:42, FastEthernet1/0
C 172.16.0.0 is directly connected, FastEthernet0/1
C 172.16.1.0 is directly connected, FastEthernet1/0
10.0.0.0/24 is subnetted, 2 subnets
O 10.0.0.0 [110/11] via 172.16.1.1, 00:02:42, FastEthernet1/0
C 10.0.4.0 is directly connected, FastEthernet0/0.10
S* 0.0.0.0/0 [1/0] via 100.1.0.1
R4#sh ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface
172.16.254.2 1 FULL/BDR 00:00:32 172.16.1.1 FastEthernet1/0
172.16.254.3 1 FULL/BDR 00:00:34 172.16.0.1 FastEthernet0/1
R4#
R4=============================
ЗЫ: Одни сетевики говорят делай оспф, другие делай на бгп. И что же выбрать? И как это все настроить. Другие говорят между ядром и пограничниками делай бгп, а между удаленными точками и пограничниками делай оспф.