add VWD Service Provider Template
This commit is contained in:
136
VWD_ServiceProvider_Template/res.txt
Normal file
136
VWD_ServiceProvider_Template/res.txt
Normal file
@@ -0,0 +1,136 @@
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!switch-vwd-1,switch-vwd-2
|
||||
conf t
|
||||
vlan 809
|
||||
name oracle
|
||||
end
|
||||
wr mem
|
||||
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!switch-vwd-sp1, switch-vwd-sp2
|
||||
conf t
|
||||
vrf definition oracle
|
||||
rd 65000:1009
|
||||
address-family ipv4
|
||||
exit-address-family
|
||||
|
||||
vlan 809
|
||||
name oracle
|
||||
|
||||
ip access-list standard routes2oracle
|
||||
permit # routes acl
|
||||
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!switch-vwd-sp1
|
||||
conf t
|
||||
|
||||
interface vlan809
|
||||
description oracle
|
||||
vrf forwarding oracle
|
||||
ip address 10.120.2.2 255.255.255.0
|
||||
|
||||
int Gi1/0/9
|
||||
description Cust: VWD-Transit (oracle)
|
||||
# vrf definition oracle
|
||||
# ip address 192.168.239.25 255.255.255.254
|
||||
# switchport mode trunk|access
|
||||
# switchport access vlan ...
|
||||
# switchport trunk allowed vlan ...
|
||||
# channel-group X mode on|active
|
||||
|
||||
int Vlan1900
|
||||
description Cust: VWD-Transit (oracle)
|
||||
vrf definition oracle
|
||||
ip address 192.168.239.25 255.255.255.254
|
||||
|
||||
router bgp 65148
|
||||
address-family ipv4 vrf oracle
|
||||
bgp router-id auto-assign
|
||||
redistribute static
|
||||
neighbor 10.120.2.1 remote-as 65148
|
||||
|
||||
neighbor 10.120.2.3 remote-as 65159
|
||||
neighbor 10.120.2.3 local-as 65159
|
||||
|
||||
neighbor 192.168.239.25 remote-as 31898
|
||||
neighbor 192.168.239.25 local-as 65159
|
||||
|
||||
distribute-list routes2oracle
|
||||
exit-address-family
|
||||
|
||||
ip route vrf oracle # static routes 1
|
||||
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!switch-vwd-sp2
|
||||
conf t
|
||||
|
||||
interface vlan809
|
||||
description oracle
|
||||
vrf forwarding oracle
|
||||
ip address 10.120.2.3 255.255.255.0
|
||||
|
||||
int Gi1/0/9
|
||||
description Cust: VWD-Transit (oracle)
|
||||
# vrf definition oracle
|
||||
# ip address xxx zzz
|
||||
# switchport mode trunk|access
|
||||
# switchport access vlan ...
|
||||
# switchport trunk allowed vlan ...
|
||||
# channel-group X mode on|active
|
||||
|
||||
int Vlan1900
|
||||
description Cust: VWD-Transit (oracle)
|
||||
vrf definition oracle
|
||||
ip address xxx zzz
|
||||
|
||||
router bgp 65148
|
||||
address-family ipv4 vrf oracle
|
||||
bgp router-id auto-assign
|
||||
redistribute static
|
||||
neighbor 10.120.2.1 remote-as 65148
|
||||
|
||||
neighbor 10.120.2.2 remote-as 65159
|
||||
neighbor 10.120.2.2 local-as 65159
|
||||
|
||||
neighbor yyy remote-as 31898
|
||||
neighbor yyy local-as 65159
|
||||
|
||||
distribute-list routes2oracle
|
||||
exit-address-family
|
||||
|
||||
ip route vrf oracle # static routes 2
|
||||
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!asa-vwd-1
|
||||
conf t
|
||||
interface Port-channel2.809
|
||||
vlan 809
|
||||
nameif oracle
|
||||
security-level 100
|
||||
ip address 10.120.2.1 255.255.255.0
|
||||
|
||||
access-list oracle_access_in extended permit icmp any any
|
||||
access-list oracle_access_in extended deny ip any any
|
||||
|
||||
no monitor-interface oracle
|
||||
|
||||
access-group oracle_access_in in interface oracle
|
||||
|
||||
access-list oracle_access_in extended permit icmp any any
|
||||
access-list oracle_access_in extended deny ip any any
|
||||
|
||||
router bgp 65148
|
||||
bgp log-neighbor-changes
|
||||
address-family ipv4 unicast
|
||||
neighbor 10.120.2.2 remote-as 65148
|
||||
neighbor 10.120.2.2 description oracle primary weight 200
|
||||
neighbor 10.120.2.2 activate
|
||||
neighbor 10.120.2.2 next-hop-self
|
||||
neighbor 10.120.2.2 weight 200
|
||||
neighbor 10.120.2.3 remote-as 65148
|
||||
neighbor 10.120.2.3 description oracle secondary weight 100
|
||||
neighbor 10.120.2.3 activate
|
||||
neighbor 10.120.2.3 next-hop-self
|
||||
neighbor 10.120.2.3 weight 100
|
||||
|
||||
|
||||
4
VWD_ServiceProvider_Template/run.sh
Normal file
4
VWD_ServiceProvider_Template/run.sh
Normal file
@@ -0,0 +1,4 @@
|
||||
cp temp.txt res.txt
|
||||
|
||||
cat var.txt | egrep "! " | awk '{print "sed -i s#"$2 "#" $3"#g res.txt"}'
|
||||
#sed -i "s/__VRFXFERIPSW2__/XyZ/g" res.txt
|
||||
136
VWD_ServiceProvider_Template/temp.txt
Normal file
136
VWD_ServiceProvider_Template/temp.txt
Normal file
@@ -0,0 +1,136 @@
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!switch-vwd-1,switch-vwd-2
|
||||
conf t
|
||||
vlan __VRFXFERVLAN__
|
||||
name __VRFNAME__
|
||||
end
|
||||
wr mem
|
||||
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!switch-vwd-sp1, switch-vwd-sp2
|
||||
conf t
|
||||
vrf definition __VRFNAME__
|
||||
rd 65000:__VRFID__
|
||||
address-family ipv4
|
||||
exit-address-family
|
||||
|
||||
vlan __VRFXFERVLAN__
|
||||
name __VRFNAME__
|
||||
|
||||
ip access-list standard routes2__VRFNAME__
|
||||
permit # routes acl
|
||||
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!switch-vwd-sp1
|
||||
conf t
|
||||
|
||||
interface vlan__VRFXFERVLAN__
|
||||
description __VRFNAME__
|
||||
vrf forwarding __VRFNAME__
|
||||
ip address __VRFXFERIPSW1__ __VRFXFERIPMASK__
|
||||
|
||||
int __CUSTINTP__
|
||||
description Cust: VWD-Transit (__VRFNAME__)
|
||||
# vrf definition __VRFNAME__
|
||||
# ip address __VRFCUSTIP1__ __VRFCUSTIP1M__
|
||||
# switchport mode trunk|access
|
||||
# switchport access vlan ...
|
||||
# switchport trunk allowed vlan ...
|
||||
# channel-group X mode on|active
|
||||
|
||||
int __CUSTINT__
|
||||
description Cust: VWD-Transit (__VRFNAME__)
|
||||
vrf definition __VRFNAME__
|
||||
ip address __VRFCUSTIP1__ __VRFCUSTIP1M__
|
||||
|
||||
router bgp 65148
|
||||
address-family ipv4 vrf __VRFNAME__
|
||||
bgp router-id auto-assign
|
||||
redistribute static
|
||||
neighbor __VRFXFERIPASA__ remote-as 65148
|
||||
|
||||
neighbor __VRFXFERIPSW2__ remote-as __VRFXFERAS__
|
||||
neighbor __VRFXFERIPSW2__ local-as __VRFXFERAS__
|
||||
|
||||
neighbor __VRFCUSTIP1R__ remote-as __VRFCUSTAS__
|
||||
neighbor __VRFCUSTIP1R__ local-as __VRFXFERAS__
|
||||
|
||||
distribute-list routes2__VRFNAME__
|
||||
exit-address-family
|
||||
|
||||
ip route vrf __VRFNAME__ # static routes 1
|
||||
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!switch-vwd-sp2
|
||||
conf t
|
||||
|
||||
interface vlan__VRFXFERVLAN__
|
||||
description __VRFNAME__
|
||||
vrf forwarding __VRFNAME__
|
||||
ip address __VRFXFERIPSW2__ __VRFXFERIPMASK__
|
||||
|
||||
int __CUSTINTP__
|
||||
description Cust: VWD-Transit (__VRFNAME__)
|
||||
# vrf definition __VRFNAME__
|
||||
# ip address __VRFCUSTIP2__ __VRFCUSTIP2M__
|
||||
# switchport mode trunk|access
|
||||
# switchport access vlan ...
|
||||
# switchport trunk allowed vlan ...
|
||||
# channel-group X mode on|active
|
||||
|
||||
int __CUSTINT__
|
||||
description Cust: VWD-Transit (__VRFNAME__)
|
||||
vrf definition __VRFNAME__
|
||||
ip address __VRFCUSTIP2__ __VRFCUSTIP2M__
|
||||
|
||||
router bgp 65148
|
||||
address-family ipv4 vrf __VRFNAME__
|
||||
bgp router-id auto-assign
|
||||
redistribute static
|
||||
neighbor __VRFXFERIPASA__ remote-as 65148
|
||||
|
||||
neighbor __VRFXFERIPSW1__ remote-as __VRFXFERAS__
|
||||
neighbor __VRFXFERIPSW1__ local-as __VRFXFERAS__
|
||||
|
||||
neighbor __VRFCUSTIP2R__ remote-as __VRFCUSTAS__
|
||||
neighbor __VRFCUSTIP2R__ local-as __VRFXFERAS__
|
||||
|
||||
distribute-list routes2__VRFNAME__
|
||||
exit-address-family
|
||||
|
||||
ip route vrf __VRFNAME__ # static routes 2
|
||||
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!asa-vwd-1
|
||||
conf t
|
||||
interface Port-channel2.__VRFXFERVLAN__
|
||||
vlan __VRFXFERVLAN__
|
||||
nameif __VRFNAME__
|
||||
security-level 100
|
||||
ip address __VRFXFERIPASA__ __VRFXFERIPMASK__
|
||||
|
||||
access-list __VRFNAME___access_in extended permit icmp any any
|
||||
access-list __VRFNAME___access_in extended deny ip any any
|
||||
|
||||
no monitor-interface __VRFNAME__
|
||||
|
||||
access-group __VRFNAME___access_in in interface __VRFNAME__
|
||||
|
||||
access-list __VRFNAME___access_in extended permit icmp any any
|
||||
access-list __VRFNAME___access_in extended deny ip any any
|
||||
|
||||
router bgp 65148
|
||||
bgp log-neighbor-changes
|
||||
address-family ipv4 unicast
|
||||
neighbor __VRFXFERIPSW1__ remote-as 65148
|
||||
neighbor __VRFXFERIPSW1__ description __VRFNAME__ primary weight 200
|
||||
neighbor __VRFXFERIPSW1__ activate
|
||||
neighbor __VRFXFERIPSW1__ next-hop-self
|
||||
neighbor __VRFXFERIPSW1__ weight 200
|
||||
neighbor __VRFXFERIPSW2__ remote-as 65148
|
||||
neighbor __VRFXFERIPSW2__ description __VRFNAME__ secondary weight 100
|
||||
neighbor __VRFXFERIPSW2__ activate
|
||||
neighbor __VRFXFERIPSW2__ next-hop-self
|
||||
neighbor __VRFXFERIPSW2__ weight 100
|
||||
|
||||
|
||||
27
VWD_ServiceProvider_Template/var.txt
Normal file
27
VWD_ServiceProvider_Template/var.txt
Normal file
@@ -0,0 +1,27 @@
|
||||
! __VRFXFERVLAN__ 810
|
||||
! __VRFNAME__ bitpanda
|
||||
! __VRFID__ 1009
|
||||
! __VRFXFERIPASA__ 10.120.1.97
|
||||
! __VRFXFERIPSW1__ 10.120.1.98
|
||||
! __VRFXFERIPSW2__ 10.120.1.9
|
||||
! __VRFXFERIPMASK__ 255.255.255.248
|
||||
! __VRFXFERAS__ 65160
|
||||
! __VRFCUSTIP1__ 192.168.239.25
|
||||
! __VRFCUSTAS__ 31898
|
||||
! __CUSTINTP__ Gi1/0/10
|
||||
! __CUSTINT__ Vlan1900
|
||||
! __VRFCUSTIP1__ 192.168.239.24
|
||||
! __VRFCUSTIP1R__ 192.168.239.25
|
||||
! __VRFCUSTIP1M__ 255.255.255.254
|
||||
! __VRFCUSTIP2__ xxx
|
||||
! __VRFCUSTIP2R__ yyy
|
||||
! __VRFCUSTIP2M__ zzz
|
||||
|
||||
# static routes 1
|
||||
# 172.20.20.0 255.255.255.0 10.120.2.1
|
||||
|
||||
# static routes 2
|
||||
# 172.20.20.0 255.255.255.0 10.120.2.1
|
||||
|
||||
# routes acl
|
||||
# 172.20.20.0 0.0.0.255
|
||||
Reference in New Issue
Block a user