拓撲設計:
實驗要求:
內網ip位址172.16.00/16 合理分配
sw1/2之間互為備份
vrrp/stp/vlan/trunk均使用
所有pc通過dhcp獲取ip位址
子網劃分
172.16.1.0/24 vlan1
172.16.2.0/24 vlan2
ethtruck的配置
[sw1]inte***ce eth-trunk 0
[sw1-eth-trunk0]int g0/0/2
[sw1-gigabitethernet0/0/2]eth-trunk 0
[sw2]inte***ce eth-trunk 0
[sw2-gigabitethernet0/0/2]eth-trunk
[sw2-gigabitethernet0/0/3]eth-trunk 0
truck
給三層交換機eth-trunk 0 g0/0/4 g0/0/5設定truck幹道
二層ethernet0/0/1和ethernet0/0/2設定truck幹道
ethernet0/0/3和ethernet0/0/4用access
stp協議
給每層交換機設定stp,三層交換機1vlan1為主根,vlan2為備份 三層交換機2vlan2為主根,vlan1為備份 ,以sw1為例
[sw1]stp enable
[sw1]stp region-configuration
[sw1-mst-region]region-name a
[sw1-mst-region]instance 1 vlan 1
[sw1-mst-region]instance 2 vlan 2
[sw1]stp instance 1 root primary
[sw1]stp instance 2 root secondary
配置svi
[sw1-vlanif1]ip address 172.16.1.1 24
[sw1-vlanif2]ip address 172.16.2.1 24
vrrp
[sw1]int vlanif 1
[sw1-vlanif1]vrrp vrid 1 virtual-ip 172.16.1.254
[sw1-vlanif1]vrrp vrid 1 priority 101
[sw1-vlanif1]vrrp vrid1 track int g0/0/1
[sw1-vlanif1]int vlanif 2
[sw1-vlanif2]vrrp vrid 2 virtual-ip 172.16.2.254
[sw1-vlanif2]vrrp vrid2 track int g0/0/1
[sw2]int vlanif 1
[sw2-vlanif1]vrrp vrid 1 virtual-ip 172.16.1.254
[sw2-vlanif1]vrrp vrid 1 track int g0/0/1
[sw2-vlanif1]int vlanif 2
[sw2-vlanif2]vrrp vrid2 virtual-ip 172.16.2.254
[sw2-vlanif2]vrrp vrid 2 priority 101
[sw2-vlanif2]vrrp vrid 2track int g0/0/1
dhcp
[sw1]dhcp enable
[sw1]ip pool v1
[sw1-ip-pool-v1]network 172.16.1.0 mask 24
[sw1-ip-pool-v1]gateway-list 172.16.1.254
[sw1-ip-pool-v1]dns-list 114.114.114.114
[sw1-ip-pool-v2]network 172.16.2.0 mask 24
[sw1-ip-pool-v2]gateway-list 172.16.2.254
[sw1-ip-pool-v2]dns-list 114.114.114.114
[sw1]int vlanif 1
[sw1-vlanif1]dhcp select global
[sw1-vlanif1]int vlanif 2
[sw1-vlanif2]dhcp select global
路由器配置
[sw1]vlan 10
[sw1-vlan10]int vlan 10
[sw1-vlanif10]ip address 172.16.10.1 24
[sw1-vlanif10]int g0/0/1
[sw1-gigabitethernet0/0/1]port link-type access
[sw1-gigabitethernet0/0/1]port default vlan 10
[sw1]ip route-static 0.0.0.0 0 172.16.10.2
[sw2]vlan 20
[sw2-vlan20]int vlan 20
[sw2-vlanif20]ip address 172.16.20.1 24
[sw2-vlanif20]int g0/0/1
[sw2-gigabitethernet0/0/1]port link-type access
[sw2-gigabitethernet0/0/1]port default vlan 20
[sw2-gigabitethernet0/0/1]ip route-static 0.0.0.0 0 172.16.20.2
[huawei]sysname r1
[r1]int g0/0/0
[r1-gigabitethernet0/0/0]ip address 172.16.10.2 24
[r1-gigabitethernet0/0/0]int g0/0/1
[r1-gigabitethernet0/0/1]ip address 172.16.20.2 24
[r1-gigabitethernet0/0/1]qu
[r1]ip route-static 172.16.2.0 24 172.16.20.1
[r1]ip route-static 172.16.2.0 24 172.16.10.1
[r1]ip route-static 172.16.3.0 24 172.16.10.1
[r1]ip route-static 172.16.3.0 24 172.16.20.1
[r1]int g0/0/2
[r1-gigabitethernet0/0/2]ip address 12.1.1.1 24
[huawei]sysname isp
[isp]int g0/0/0
[isp-acl-basic-2000]int g0/0/2
[isp-gigabitethernet0/0/2]nat outbound 2000
[isp-gigabitethernet0/0/2]qu
[isp]ip route-static 0.0.0.0 0 12.1.1.2
ensp 三層網路架構實驗
實驗拓撲 實驗要求 使用者的閘道器配置在核心交換機 企業內網劃分多個vlan 減少廣播域大小,提高網路穩定性 sw4 sw4 int e0 0 2 sw4 ethernet0 0 2 port link type access sw4 ethernet0 0 2 port default vlan ...
c mysql三層架構例項 三層架構例項
一 概要 這篇部落格,準備用乙個小demo來介紹應該實現三層架構。三層架構只是分層的一種經典形式,到底分幾層,要依具體情況而定,考慮到系統的複雜程度,和後期的可維護性,完全可以分四層,五層,甚至六層,七層。二 demo 1 實現語言 vb.net 2 需求 學校機房收費系統 中的乙個功能 操作員為學...
企業網三層架構實驗
1 內網ip位址172.16.0.0 16 合理分配。2 sw1 2之間互為備份。3 vrrp stp vlan trunk均使用。4 所有pc通過dhcp獲取ip位址。此類實驗我們處理的思路為ip位址規劃,交換,路由,該實驗中,我們用到的交換部分知識有 vlan,trunk,vrrp,mstp,s...