All With BGP
All With BGP
***
en
conf t
hostname B1-ANAP
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface e0/0
ip address 192.0.1.1 255.255.255.248
no shut
!
interface e0/1
ip address 192.0.11.1 255.255.255.248
no shut
!
interface e0/2
ip address 192.0.21.1 255.255.255.248
no shut
exit
!
router rip
version 2
timers basic 20 25 30 30
redistribute bgp 56278 metric 2
network 192.0.11.0
network 192.0.21.0
distance 10 192.0.11.2 0.0.0.0
no auto-summary
exit
!
router bgp 56278
bgp log-neighbor-changes
neighbor 192.0.1.2 remote-as 65501
neighbor 192.0.1.2 password P5&x!eE7CXk4
neighbor 192.0.11.2 remote-as 56278
neighbor 192.0.21.2 remote-as 56278
network 192.0.1.0 mask 255.255.255.248
no auto-summary
exit
no ip domain lookup
end
***********************************************************************************
***
en
conf t
hostname B2-ANAP
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface e0/0
ip address 192.0.2.1 255.255.255.248
no shut
!
interface e0/1
ip address 192.0.12.1 255.255.255.248
no shut
!
interface e0/2
ip address 192.0.22.1 255.255.255.248
no shut
exit
!
router bgp 56278
bgp log-neighbor-changes
neighbor 192.0.2.2 remote-as 65502
neighbor 192.0.2.2 password P5&x!eE7CXk4
neighbor 192.0.2.3 remote-as 65502
neighbor 192.0.2.3 password P5&x!eE7CXk4
neighbor 192.0.12.2 remote-as 56278
neighbor 192.0.22.2 remote-as 56278
network 192.0.2.0 mask 255.255.255.248
no auto-summary
exit
no ip domain lookup
end
***********************************************************************************
***
en
conf t
hostname B3-ANAP
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface e0/0
ip address 192.0.3.1 255.255.255.248
no shut
!
interface e0/1
ip address 192.0.13.1 255.255.255.248
no shut
!
interface e0/2
ip address 192.0.23.1 255.255.255.248
no shut
exit
!
router bgp 56278
bgp log-neighbor-changes
neighbor 192.0.3.2 remote-as 65503
neighbor 192.0.3.2 password P5&x!eE7CXk4
neighbor 192.0.13.2 remote-as 56278
neighbor 192.0.23.2 remote-as 56278
network 192.0.3.0 mask 255.255.255.248
no auto-summary
exit
no ip domain lookup
end
***********************************************************************************
***
en
conf t
hostname B4-ANAP
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface e0/0
ip address 192.0.4.1 255.255.255.248
no shut
!
interface e0/1
ip address 192.0.14.1 255.255.255.248
no shut
!
interface e0/2
ip address 192.0.24.1 255.255.255.248
no shut
exit
!
router bgp 56278
bgp log-neighbor-changes
neighbor 192.0.4.2 remote-as 65504
neighbor 192.0.4.2 password P5&x!eE7CXk4
neighbor 192.0.14.2 remote-as 56278
neighbor 192.0.24.2 remote-as 56278
network 192.0.4.0 mask 255.255.255.248
no auto-summary
exit
no ip domain lookup
end
***********************************************************************************
***
en
conf t
hostname B5-ANAP
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface e0/0
ip address 192.0.5.1 255.255.255.248
no shut
!
interface e0/1
ip address 192.0.15.1 255.255.255.248
no shut
!
interface e0/2
ip address 192.0.25.1 255.255.255.248
no shut
exit
!
router bgp 56278
bgp log-neighbor-changes
neighbor 192.0.5.2 remote-as 65505
neighbor 192.0.5.2 password P5&x!eE7CXk4
neighbor 192.0.15.2 remote-as 56278
neighbor 192.0.25.2 remote-as 56278
network 192.0.5.0 mask 255.255.255.248
no auto-summary
exit
no ip domain lookup
end
***********************************************************************************
***
en
conf t
hostname POP1
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
line vty 0 4
login
transport input none
!
!
interface g0/0
ip address 192.0.11.2 255.255.255.248
no shut
!
interface g0/1
ip address 192.0.12.2 255.255.255.248
no shut
interface g0/2
ip address 192.0.13.2 255.255.255.248
no shut
interface g0/3
ip address 192.0.14.2 255.255.255.248
no shut
interface g0/4
ip address 192.0.15.2 255.255.255.248
no shut
exit
***********************************************************************************
***
en
conf t
hostname POP2
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface g0/0
ip address 192.0.21.2 255.255.255.248
no shut
!
interface g0/1
ip address 192.0.22.2 255.255.255.248
no shut
interface g0/2
ip address 192.0.23.2 255.255.255.248
no shut
interface g0/3
ip address 192.0.24.2 255.255.255.248
no shut
interface g0/4
ip address 192.0.25.2 255.255.255.248
no shut
exit
******************************************************
conf t
hostname B1-Core
vlan 1
vlan 2
name Users
vlan 4000
name ARYAKA
interface 1/1/4
no shutdown
description ANAP
no routing
vlan access 4000
interface 1/1/7
no shutdown
no routing
vlan trunk allowed 1,2
interface vlan1
description Management
ip address 131.101.1.254/24
no shutdown
interface vlan2
description LAN_Users
ip address 10.198.1.254/24
no shutdown
interface vlan4000
description ARYAKA-RIP
ip address 192.0.1.2/29
exit
!
router bgp 65501
neighbor 192.0.1.1 remote-as 56278
bgp log-neighbor-changes
neighbor 192.0.1.1 password plaintext P5&x!eE7CXk4
address-family ipv4 unicast
neighbor 192.0.1.1 activate
neighbor 192.0.1.1 route-map LOCAL-SUBNET out
network 10.180.1.0/24
network 10.191.1.0/24
network 10.192.1.0/24
network 10.198.1.0/24
network 131.101.1.0/24
exit-address-family
end
!
wr mem
******************************************************
#
sysname IRF1
#
password-recovery enable
#
vlan 1
#
vlan 2
name users
#
interface Vlan-interface1
ip address 131.101.1.250 255.255.255.0
#
interface GigabitEthernet1/0
port link-mode route
#
interface GigabitEthernet2/0
port link-mode route
#
interface GigabitEthernet3/0
port link-mode route
#
interface GigabitEthernet4/0
port link-mode route
#
interface GigabitEthernet5/0
port link-mode route
#
interface GigabitEthernet7/0
port link-mode route
#
interface GigabitEthernet6/0
port link-mode bridge
port access vlan 2
#
interface GigabitEthernet8/0
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 to 2
#
//////////////////////////////////////////
conf t
hostname B2-VSX1
vlan 1
vsx-sync
vlan 2
vsx-sync
vlan 3
vsx-sync
vlan 4000
vsx-sync
interface 1/1/1
description ISL
no shut
no routing
lag 100
exit
vrf KA
exit
int 1/1/2
description KEEPALIVE
vrf attach KA
ip address 192.168.0.1/30
no shut
exit
vsx
role primary
inter-switch-link lag 100
keepalive peer 192.168.0.2 source 192.168.0.1 vrf KA
exit
interface vlan 2
vsx-sync
description LAN
ip address 10.198.2.251/24
active-gateway ip 10.198.2.254 mac 00:00:00:00:00:02
no shut
exit
interface vlan 3
vsx-sync
description LAN
ip address 10.192.2.251/24
active-gateway ip 10.192.2.254 mac 00:00:00:00:00:03
no shut
exit
interface vlan 1
vsx-sync
description LAN
ip address 131.101.2.251/24
active-gateway ip 131.101.2.254 mac 00:00:00:00:00:01
no shut
exit
interface 1/1/7
description LINK-LAN-SW
no shut
no routing
vlan trunk allowed 1,2,3,4000
exit
interface 1/1/4
description LINK-ANAP
no routing
no shut
vlan access 4000
interface vlan 4000
description Aryaka
vsx-sync active-gateways policies
ip address 192.0.2.2/29
active-gateway ip mac 00:00:00:00:40:00
active-gateway ip 192.0.2.6
exit
end
wr mem
//////////////////////////////////////////
conf t
hostname B2-VSX2
vlan 2
vlan 3
vlan 4000
interface 1/1/1
description ISL
no shut
lag 100
exit
vrf KA
exit
int 1/1/2
description KEEPALIVE
vrf attach KA
ip address 192.168.0.2/30
no shut
interface 1/1/4
description aryaka
no shut
no routing
vlan access 4000
exit
vsx
role secondary
inter-switch-link lag 100
keepalive peer 192.168.0.1 source 192.168.0.2 vrf KA
exit
interface vlan 2
vsx-sync
description LAN
ip address 10.198.2.252/24
active-gateway ip 10.198.2.254 mac 00:00:00:00:00:02
no shut
exit
interface vlan 3
vsx-sync
description LAN
ip address 10.192.2.252/24
active-gateway ip 10.192.2.254 mac 00:00:00:00:00:03
no shut
exit
interface vlan 1
vsx-sync
description LAN
ip address 131.101.2.252/24
active-gateway ip 131.101.2.254 mac 00:00:00:00:00:01
no shut
exit
interface 1/1/7
description LINK-LAN-SW
no shut
no routing
vlan trunk allowed 1,2,3,4000
exit
end
wr mem
//////////////////////////////////////////
conf t
hostname B2-LAN
vlan 2
vlan 3
interface 1/1/5
no routing
no shut
vlan access 2
exit
interface vlan 1
description LAN
ip address 131.101.2.250/24
no shut
exit
interface 1/1/6
description LINK-VSX2
no shut
no routing
vlan trunk allowed 1,2,3
interface 1/1/7
description LINK-VSX1
no shut
no routing
vlan trunk allowed 1,2,3
exit
end
wr mem
********************************************************************
!
******************************************************
#
sysname IRF5
#
#
vlan 1
#
vlan 4000
name aryaka
#
vlan 2
name users
#
interface Vlan-interface1
ip address 131.101.5.254 255.255.255.0
#
#
interface Vlan-interface2
ip address 10.198.5.254 255.255.255.0
#
#
interface Vlan-interface4000
ip address 192.0.5.2 255.255.255.248
#
interface GigabitEthernet6/0
port link-mode bridge
port access vlan 2
#
interface GigabitEthernet8/0
port link-mode bridge
port access vlan 4000
quit
#
bgp 65505
peer 192.0.5.1 as-number 56278
peer 192.0.5.1 password simple P5&x!eE7CXk4
#
address-family ipv4 unicast
no summary automatic
network 10.198.5.0 255.255.255.0
network 131.101.5.0 255.255.255.0
peer 192.0.5.1 enable
peer 192.0.5.1 prefix-list LOCAL-SUBNET export
#
quit
!
save f
********************************************************************
******************************************************
sys
#
sysname IRF3
#
password-recovery enable
#
vlan 1
#
vlan 4000
name aryaka
#
vlan 2
name users
#
interface Vlan-interface1
ip address 131.101.3.250 255.255.255.0
#
interface GigabitEthernet5/0
port link-mode bridge
port access vlan 4000
interface GigabitEthernet6/0
port link-mode bridge
port access vlan 2
#
interface GigabitEthernet2/0
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 2 4000
#
//////////////////////////////////////////
***********************************************************************************
***
en
conf t
hostname R3-1
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface g0/0
no shut
!
interface g0/0.1
encapsulation dot1q 1
ip address 131.101.3.254 255.255.255.0
interface g0/0.2
encapsulation dot1q 2
ip address 10.198.3.254 255.255.255.0
interface g0/0.4000
encapsulation dot1q 4000
ip address 192.0.3.2 255.255.255.248
exit
!
ip prefix-list LOCAL-SUBNET seq 10 permit 131.101.3.0/24
ip prefix-list LOCAL-SUBNET seq 15 permit 10.198.3.0/24
!
router bgp 65503
no auto-summary
neighbor 192.0.3.1 remote-as 56278
network 131.101.3.0 mask 255.255.255.0
network 10.198.3.0 mask 255.255.255.0
bgp log-neighbor-changes
neighbor 192.0.3.1 prefix-list LOCAL-SUBNET out
neighbor 192.0.3.1 password P5&x!eE7CXk4
exit
no ip domain lookup
end
******************************************************
******************************************************
sys
#
sysname IRF4
#
password-recovery enable
#
vlan 1
#
vlan 4000
name aryaka
#
vlan 2
name users
#
interface Vlan-interface1
ip address 131.101.4.250 255.255.255.0
#
interface GigabitEthernet5/0
port link-mode bridge
port access vlan 4000
interface GigabitEthernet6/0
port link-mode bridge
port access vlan 2
#
interface GigabitEthernet2/0
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 2 4000
#
interface GigabitEthernet3/0
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 2 4000
#
ip route-static 0.0.0.0 0 131.101.4.254
#
save force
//////////////////////////////////////////
***********************************************************************************
***
en
conf t
hostname R4-1
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface g0/0
no shut
!
interface g0/0.1
encapsulation dot1q 1
ip address 131.101.4.251 255.255.255.0
standby 1 ip 131.101.4.254
standby 1 priority 120
standby 1 preempt
interface g0/0.2
encapsulation dot1q 2
ip address 10.198.4.251 255.255.255.0
standby 2 ip 10.198.4.254
standby 2 priority 120
standby 2 preempt
interface g0/0.4000
encapsulation dot1q 4000
ip address 192.0.4.2 255.255.255.248
exit
!
ip prefix-list LOCAL-SUBNET seq 10 permit 131.101.4.0/24
ip prefix-list LOCAL-SUBNET seq 15 permit 10.198.4.0/24
ip prefix-list ALL-NET seq 10 permit 0.0.0.0/0 le 32
!
route-map LOCAL-SUBNET permit 10
match ip address prefix-list LOCAL-SUBNET
set metric 5
exit
!
route-map ALL-NET permit 10
match ip address prefix-list ALL-NET
set local-preference 250
exit
!
!
router bgp 65504
no auto-summary
neighbor 192.0.4.1 remote-as 56278
neighbor 192.0.4.3 remote-as 65504
network 131.101.4.0 mask 255.255.255.0
network 10.198.4.0 mask 255.255.255.0
bgp log-neighbor-changes
neighbor 192.0.4.1 route-map LOCAL-SUBNET out
neighbor 192.0.4.1 route-map ALL-NET in
neighbor 192.0.4.1 password P5&x!eE7CXk4
exit
no ip domain lookup
end
en
conf t
hostname R4-2
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
exit
!
interface g0/0
no shut
!
interface g0/0.1
encapsulation dot1q 1
ip address 131.101.4.252 255.255.255.0
standby 1 ip 131.101.4.254
standby 1 preempt
interface g0/0.2
encapsulation dot1q 2
ip address 10.198.4.252 255.255.255.0
standby 2 ip 10.198.4.254
standby 2 preempt
interface g0/0.4000
encapsulation dot1q 4000
ip address 192.0.4.3 255.255.255.248
exit
!
ip prefix-list LOCAL-SUBNET seq 10 permit 131.101.4.0/24
ip prefix-list LOCAL-SUBNET seq 15 permit 10.198.4.0/24
!
ip prefix-list ALL-NET seq 10 permit 0.0.0.0/0 le 32
!
route-map LOCAL-SUBNET permit 10
match ip address prefix-list LOCAL-SUBNET
set metric 10
exit
!
route-map ALL-NET permit 10
match ip address prefix-list ALL-NET
set local-preference 200
exit
!
!
router bgp 65504
no auto-summary
neighbor 192.0.4.1 remote-as 56278
neighbor 192.0.4.2 remote-as 65504
network 131.101.4.0 mask 255.255.255.0
network 10.198.4.0 mask 255.255.255.0
bgp log-neighbor-changes
neighbor 192.0.4.1 route-map LOCAL-SUBNET out
neighbor 192.0.4.1 route-map ALL-NET in
neighbor 192.0.4.1 password P5&x!eE7CXk4
exit
no ip domain lookup
end