[r1]ospf 1 router-id 1.1.1.1
[r1-ospf-1]area 0
[r1-ospf-1-area-0.0.0.0]network 23.1.1.1 0.0.0.0
[r1-ospf-1-area-0.0.0.0]network 34.1.1.1 0.0.0.0
[r1-ospf-1-area-0.0.0.0]network 1.1.1.1 0.0.0.0
[r1-ospf-1]default-route-advertise
[r1]ip route-static 0.0.0.0 0 12.1.1.2
[r1]acl 2000
[r1-acl-basic-2000]rule permit source any
[r1]interface g0/0/2
[r1-GigabitEthernet0/0/2]nat outbound 2000
[sw5]interface e0/0/1
[sw5-Ethernet0/0/1]port link-type access
[sw5-Ethernet0/0/1]port link-type trunk
[sw1]dhcp
[sw1]dhcp enable
[sw1]ip policy-based-route
[sw1]ip pool 1
[sw1-ip-pool-1]network1 192.168.1.0 mask 24
[sw1]interface Vlanif 2
[sw1-Vlanif2]vr
[sw1-Vlanif2]vrrp vrid 1 track interface Vlanif 1 reduced 30
[sw1]interface Vlanif 3
[sw1-Vlanif3]vrrp vrid 2 virtual-ip 172.16.1.2
[sw2]interface Vlanif 1
[sw2]interface Vlanif 2
[sw2-Vlanif2]ip address 192.168.1.2 24
[sw2-ip-pool-1]network 192.168.1.0 ma
[sw2-ip-pool-1]network 192.168.1.0 mask 24
[sw2-ip-pool-1]gateway-list 192.168.1.1
[sw2-ip-pool-1]dns-list 8.8.8.8
三层架构作业
最新推荐文章于 2024-07-24 08:30:35 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)