R1
#
sysname r1
#
interface GigabitEthernet0/0/1
ip address 10.11.1.1 255.255.255.0
#
interface GigabitEthernet0/0/2
ip address 10.11.2.1 255.255.255.0
#
interface LoopBack0
ip address 8.8.8.8 255.255.255.0
#
ospf 1 router-id 11.11.11.11
area 0.0.0.2
network 8.8.8.8 0.0.0.0
network 10.11.1.0 0.0.0.255
network 10.11.2.0 0.0.0.255
SW1
#
sysname sw1
#
vlan batch 2 to 10
#
stp instance 1 root primary
stp instance 2 root secondary
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface Vlanif5
ip address 10.1.5.1 255.255.255.0
#
interface Vlanif6
ip address 10.1.6.1 255.255.255.0
#
interface Vlanif9
ip address 10.1.9.1 255.255.255.0
#
interface Vlanif10
ip address 10.11.1.2 255.255.255.0
#
interface Eth-Trunk0
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/1
port link-type access
port default vlan 10
#
interface GigabitEthernet0/0/3
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/4
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/5
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
eth-trunk 0
#
ospf 1 router-id 1.1.1.1
area 0.0.0.0
network 10.1.9.0 0.0.0.255
area 0.0.0.1
network 10.1.5.0 0.0.0.255
network 10.1.6.0 0.0.0.255
area 0.0.0.2
network 10.11.1.0 0.0.0.255
SW2
sysname sw2
#
vlan batch 2 to 10
#
stp instance 1 root secondary
stp instance 2 root primary
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface Vlanif7
ip address 10.1.7.1 255.255.255.0
#
interface Vlanif8
ip address 10.1.8.1 255.255.255.0
#
interface Vlanif9
ip address 10.1.9.2 255.255.255.0
#
interface Vlanif10
ip address 10.11.2.2 255.255.255.0
#
interface Eth-Trunk0
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/1
port link-type access
port default vlan 10
#
interface GigabitEthernet0/0/3
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/4
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/5
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
eth-trunk 0
#
interface GigabitEthernet0/0/24
eth-trunk 0
#
interface NULL0
#
ospf 1 router-id 2.2.2.2
area 0.0.0.0
network 10.1.9.0 0.0.0.255
area 0.0.0.1
network 10.1.7.0 0.0.0.255
network 10.1.8.0 0.0.0.255
area 0.0.0.2
network 10.11.2.0 0.0.0.255
SW3
#
sysname sw3
#
vlan batch 2 to 10
#
stp instance 1 priority 8192
stp instance 2 priority 8192
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface Vlanif2
ip address 10.1.2.1 255.255.255.0
vrrp vrid 1 virtual-ip 10.1.2.254
vrrp vrid 1 priority 130
vrrp vrid 1 preempt-mode timer delay 5
vrrp vrid 1 track interface GigabitEthernet0/0/1 reduced 20
vrrp vrid 1 track interface GigabitEthernet0/0/2 reduced 20
#
interface Vlanif3
ip address 10.1.3.1 255.255.255.0
vrrp vrid 1 virtual-ip 10.1.3.254
#
interface Vlanif5
ip address 10.1.5.2 255.255.255.0
#
interface Vlanif7
ip address 10.1.7.2 255.255.255.0
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/6
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/7
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
ospf 1 router-id 3.3.3.3
area 0.0.0.1
network 10.1.5.0 0.0.0.255
network 10.1.2.0 0.0.0.255
network 10.1.3.0 0.0.0.255
network 10.1.7.0 0.0.0.255
SW4
#
sysname sw4
#
vlan batch 2 to 10
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface Vlanif2
ip address 10.1.2.2 255.255.255.0
vrrp vrid 1 virtual-ip 10.1.2.254
#
interface Vlanif3
ip address 10.1.3.2 255.255.255.0
vrrp vrid 1 virtual-ip 10.1.3.254
vrrp vrid 1 priority 130
vrrp vrid 1 preempt-mode timer delay 5
vrrp vrid 1 track interface GigabitEthernet0/0/1 reduced 20
vrrp vrid 1 track interface GigabitEthernet0/0/2 reduced 20
#
interface Vlanif6
ip address 10.1.6.2 255.255.255.0
#
interface Vlanif8
ip address 10.1.8.2 255.255.255.0
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/8
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/9
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
ospf 1
area 0.0.0.1
network 10.1.6.0 0.0.0.255
network 10.1.2.0 0.0.0.255
network 10.1.3.0 0.0.0.255
network 10.1.8.0 0.0.0.255
SW5
#
sysname sw5
#
vlan batch 2 to 10
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface Vlanif4
ip address 10.1.4.1 255.255.255.0
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/10
port link-type trunk
port trunk allow-pass vlan 2 to 4094
SW7
#
sysname sw7
#
vlan batch 2 to 10
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface GigabitEthernet0/0/3
port link-type trunk
port trunk allow-pass vlan 2 to 4094
SW8
#
sysname sw8
#
vlan batch 2 to 10
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface GigabitEthernet0/0/4
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
SW9
#
sysname sw9
#
vlan batch 2 to 10
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface GigabitEthernet0/0/4
port link-type trunk
port trunk allow-pass vlan 2 to 4094
SW10
#
sysname sw10
#
vlan batch 2 to 10
#
stp region-configuration
region-name a
instance 1 vlan 2 5 to 6 9
instance 2 vlan 3 to 4 7 to 8
active region-configuration
#
interface GigabitEthernet0/0/5
port link-type trunk
port trunk allow-pass vlan 2 to 4094