...
Исходная конфигурация кластера:
| Блок кода |
|---|
|
cluster
cluster-interface bridge 1
unit 1
mac-address cc:9d:a2:71:83:78
exit
unit 2
mac-address cc:9d:a2:71:82:38
exit
enable
exit
hostname ESR-1 unit 1
hostname ESR-2 unit 2
security zone SYNC
exit
bridge 1
vlan 1
security-zone SYNC
ip address 198.51.100.254/24 unit 1
ip address 198.51.100.253/24 unit 2
vrrp id 1
vrrp ip 198.51.100.1/24
vrrp group 1
vrrp
enable
exit
interface gigabitethernet 1/0/3
mode switchport
spanning-tree disable
exit
interface gigabitethernet 2/0/3
mode switchport
spanning-tree disable
exit
security zone-pair SYNC self
rule 1
action permit
match protocol icmp
enable
exit
rule 2
action permit
match protocol vrrp
enable
exit
rule 3
action permit
match protocol ah
enable
exit
exit |
Решение:
Перейдем в режим конфигурирования устройства:
| Блок кода |
|---|
|
ESR-1# configure
ESR-1(config)# |
Зададим необходимый system promptУкажите, какую именно информацию вы хотите получить:
| Блок кода |
|---|
|
ESR-1(config)# system prompt 'Cluster: %s% | Unit: %u% | State: %r%\nVRRP id 1: %v1%\n%h%' |
После применения конфигурации необходимо обновить Применим конфигурацию и обновим пользовательскую сессию CLI:
| Блок кода |
|---|
|
ESR-1# commit
Configuration has been successfully applied and saved to flash. Commit timer started, changes will be.
ESR-1# confirm
Configuration has been confirmed. Commit timer canceled.
ESR-1# exit
ESR-1 login: ESRadmin
Password:
********************************************
* Welcome to ESR *
********************************************
Cluster: Yes | Unit: 1 | State: Active
VRRP id 1: Master
ESR-1# |
| Примечание |
|---|
Обновление пользовательской сессии необходимо, чтобы настройки system prompt применились исключительно для администратора, которому это требуется. |
Итоговая конфигурация кластера:
| Блок кода |
|---|
cluster
cluster-interface bridge 1
unit 1
mac-address 68:13:e2:7f:22:c0
exit
unit 2
mac-address 68:13:e2:7f:10:30
exit
enable
exit
hostname ESR-1 unit 1
hostname ESR-2 unit 2
security zone SYNC
exit
bridge 1
vlan 1
security-zone SYNC
ip address 198.51.100.254/24 unit 1
ip address 198.51.100.253/24 unit 2
vrrp id 1
vrrp ip 198.51.100.1/24
vrrp group 1
vrrp
enable
exit
interface gigabitethernet 1/0/3
mode switchport
spanning-tree disable
exit
interface gigabitethernet 2/0/3
mode switchport
spanning-tree disable
exit
security zone-pair SYNC self
rule 1
action permit
match protocol icmp
enable
exit
rule 2
action permit
match protocol vrrp
enable
exit
rule 3
action permit
match protocol ah
enable
exit
exit
system prompt 'Cluster: %s% | Unit: %u% | State: %r%\nVRRP id 1: %v1%\n%h%' Master# |
Настройка MultiWAN
Технология MultiWAN позволяет организовать отказоустойчивое соединение с резервированием линков от нескольких провайдеров, а также решает проблему балансировки трафика между резервными линками.
...
| Блок кода |
|---|
|
cluster
cluster-interface bridge 1
unit 1
mac-address cc:9d:a2:71:83:78
exit
unit 2
mac-address cc:9d:a2:71:82:38
exit
enable
exit
hostname ESR-1 unit 1
hostname ESR-2 unit 2
security zone SYNC
exit
security zone LAN
exit
bridge 1
vlan 1
security-zone SYNC
ip address 198.51.100.254/24 unit 1
ip address 198.51.100.253/24 unit 2
vrrp id 1
vrrp ip 198.51.100.1/24
vrrp group 1
vrrp
enable
exit
interface gigabitethernet 1/0/2
security-zone LAN
ip address 192.0.2.254/24
vrrp id 2
vrrp ip 192.0.2.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 1/0/3
mode switchport
spanning-tree disable
exit
interface gigabitethernet 2/0/2
security-zone LAN
ip address 192.0.2.253/24
vrrp id 2
vrrp ip 192.0.2.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 2/0/3
mode switchport
spanning-tree disable
exit
security zone-pair SYNC self
rule 1
action permit
match protocol icmp
enable
exit
rule 2
action permit
match protocol vrrp
enable
exit
rule 3
action permit
match protocol ah
enable
exit
exit
security zone-pair LAN self
rule 1
action permit
enable
exit
exit |
Решение:
Сконфигурируем необходимые сетевые интерфейсы:
...
| Примечание |
|---|
В случае выхода из строя Active устройства, BGP будет полностью переустанавливаться со Standby устройством. |
Итоговая конфигурация кластера:
| Блок кода |
|---|
cluster
cluster-interface bridge 1
unit 1
mac-address cc:9d:a2:71:83:78
exit
unit 2
mac-address cc:9d:a2:71:82:38
exit
enable
exit
hostname ESR-1 unit 1
hostname ESR-2 unit 2
object-group service og_bgp
port-range 179
exit
security zone SYNC
exit
security zone LAN
exit
security zone WAN
exit
route-map bgp-out
rule 1
match ip address 198.51.100.0/24
action deny
exit
rule 2
exit
exit
router bgp 2500
neighbor 203.0.113.2
remote-as 3000
update-source 203.0.113.1
address-family ipv4 unicast
route-map bgp-out out
enable
exit
enable
exit
address-family ipv4 unicast
redistribute connected
exit
enable
exit
bridge 1
vlan 1
security-zone SYNC
ip address 198.51.100.254/24 unit 1
ip address 198.51.100.253/24 unit 2
vrrp id 1
vrrp ip 198.51.100.1/24
vrrp group 1
vrrp
enable
exit
interface gigabitethernet 1/0/1
security-zone WAN
ip address 203.0.113.254/24
vrrp id 4
vrrp ip 203.0.113.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 1/0/2
security-zone LAN
ip address 192.0.2.254/24
vrrp id 2
vrrp ip 192.0.2.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 1/0/3
mode switchport
spanning-tree disable
exit
interface gigabitethernet 2/0/1
security-zone WAN
ip address 203.0.113.253/24
vrrp id 4
vrrp ip 203.0.113.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 2/0/2
security-zone LAN
ip address 192.0.2.253/24
vrrp id 2
vrrp ip 192.0.2.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 2/0/3
mode switchport
spanning-tree disable
exit
security zone-pair SYNC self
rule 1
action permit
match protocol icmp
enable
exit
rule 2
action permit
match protocol vrrp
enable
exit
rule 3
action permit
match protocol ah
enable
exit
exit
security zone-pair LAN self
rule 1
action permit
enable
exit
exit
security zone-pair WAN self
rule 1
action permit
match protocol vrrp
enable
exit
rule 2
action permit
match protocol ah
enable
exit
rule 3
action permit
match protocol icmp
enable
exit
rule 4
action permit
match protocol tcp
match destination-port object-group og_bgp
enable
exit
exit |
...
| Блок кода |
|---|
|
cluster
cluster-interface bridge 1
unit 1
mac-address cc:9d:a2:71:83:78
exit
unit 2
mac-address cc:9d:a2:71:82:38
exit
enable
exit
hostname ESR-1 unit 1
hostname ESR-2 unit 2
security zone SYNC
exit
security zone LAN
exit
bridge 1
vlan 1
security-zone SYNC
ip address 198.51.100.254/24 unit 1
ip address 198.51.100.253/24 unit 2
vrrp id 1
vrrp ip 198.51.100.1/24
vrrp group 1
vrrp
enable
exit
interface gigabitethernet 1/0/2
security-zone LAN
ip address 192.0.2.254/24
vrrp id 2
vrrp ip 192.0.2.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 1/0/3
mode switchport
spanning-tree disable
exit
interface gigabitethernet 2/0/2
security-zone LAN
ip address 192.0.2.253/24
vrrp id 2
vrrp ip 192.0.2.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 2/0/3
mode switchport
spanning-tree disable
exit
security zone-pair SYNC self
rule 1
action permit
match protocol icmp
enable
exit
rule 2
action permit
match protocol vrrp
enable
exit
rule 3
action permit
match protocol ah
enable
exit
exit
security zone-pair LAN self
rule 1
action permit
enable
exit
exit |
Решение:
Сконфигурируем необходимые сетевые интерфейсы:
...
| Блок кода |
|---|
ESR-2# show bgp ipv4 unicast neighbor 203.0.113.6 advertise-routes
Status codes: u - unicast, b - broadcast, m - multicast, a - anycast
* - valid, > - best
Origin codes: i - IGP, e - EGP, ? - incomplete
Network Next Hop Metric LocPrf Weight Path
*> u 192.0.2.0/24 203.0.113.5 -- -- -- 2500 20 ?
*> u 203.0.113.4/30 203.0.113.5 -- -- -- 2500 20 ?
ESR-2# show bgp ipv4 unicast neighbor 203.0.113.6 routes
Status codes: u - unicast, b - broadcast, m - multicast, a - anycast
* - valid, > - best
Origin codes: i - IGP, e - EGP, ? - incomplete
Network Next Hop Metric LocPrf Weight Path
*> u 0.0.0.0/0 203.0.113.6 -- 100 0 3500 ? |
Итоговая конфигурация кластера:
| Блок кода |
|---|
cluster
cluster-interface bridge 1
unit 1
mac-address cc:9d:a2:71:83:78
exit
unit 2
mac-address cc:9d:a2:71:82:38
exit
enable
exit
hostname ESR-1 unit 1
hostname ESR-2 unit 2
object-group service og_bgp
port-range 179
exit
security zone SYNC
exit
security zone LAN
exit
security zone WAN
exit
route-map bgp-out
rule 1
match ip address 198.51.100.0/24
action deny
exit
rule 2
action set as-path prepend 20 track 1
exit
exit
router bgp 2500 unit 1
neighbor 203.0.113.2
remote-as 3000
update-source 203.0.113.1
address-family ipv4 unicast
route-map bgp-out out
enable
exit
enable
exit
address-family ipv4 unicast
redistribute connected
exit
enable
exit
router bgp 2500 unit 2
neighbor 203.0.113.6
remote-as 3500
update-source 203.0.113.5
address-family ipv4 unicast
route-map bgp-out out
enable
exit
enable
exit
address-family ipv4 unicast
redistribute connected
exit
enable
exit
bridge 1
vlan 1
security-zone SYNC
ip address 198.51.100.254/24 unit 1
ip address 198.51.100.253/24 unit 2
vrrp id 1
vrrp ip 198.51.100.1/24
vrrp group 1
vrrp
enable
exit
interface gigabitethernet 1/0/1
security-zone WAN
ip address 203.0.113.1/30
exit
interface gigabitethernet 1/0/2
security-zone LAN
ip address 192.0.2.254/24
vrrp id 2
vrrp ip 192.0.2.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 1/0/3
mode switchport
spanning-tree disable
exit
interface gigabitethernet 2/0/1
security-zone WAN
ip address 203.0.113.5/30
exit
interface gigabitethernet 2/0/2
security-zone LAN
ip address 192.0.2.253/24
vrrp id 2
vrrp ip 192.0.2.1/24
vrrp group 1
vrrp authentication key ascii-text encrypted 88B11079B51D
vrrp authentication algorithm md5
vrrp
exit
interface gigabitethernet 2/0/3
mode switchport
spanning-tree disable
exit
security zone-pair SYNC self
rule 1
action permit
match protocol icmp
enable
exit
rule 2
action permit
match protocol vrrp
enable
exit
rule 3
action permit
match protocol ah
enable
exit
exit
security zone-pair LAN self
rule 1
action permit
enable
exit
exit
security zone-pair WAN self
rule 1
action permit
match protocol icmp
enable
exit
rule 2
action permit
match protocol tcp
match destination-port object-group og_bgp
enable
exit
exit
track 1
track vrrp id 1 state not master
enable
exit |
...