云计算作业2

拓补图及要求

交换机基本配置

1. 创建VLAN
在SW1、SW2、SW3、SW4上分别创建所需VLAN:
SW1:
system - view
vlan batch 2 3 28 30
SW2:
system - view
vlan batch 2 3 28 30
SW3:
system - view
vlan batch 2 3
SW4:
system - view
vlan batch 28 30
2. 配置接口类型及加入VLAN
对于接入层交换机SW3和SW4:
SW3:
interface Ethernet0/0/1
port link - type access
port default vlan 2
interface Ethernet0/0/2
port link - type access
port default vlan 3
SW4:
interface Ethernet0/0/1
port link - type access
port default vlan 28
interface Ethernet0/0/2
port link - type access
port default vlan 30
对于汇聚层交换机SW1和SW2连接接入层交换机的接口:
SW1:
interface GigabitEthernet0/0/3
port link - type trunk
port trunk allow - pass vlan 2 3
interface GigabitEthernet0/0/4
port link - type trunk
port trunk allow - pass vlan 28 30
SW2:
interface GigabitEthernet0/0/3
port link - type trunk
port trunk allow - pass vlan 2 3
interface GigabitEthernet0/0/4
port link - type trunk
port trunk allow - pass vlan 28 30
SW1和SW2之间互联接口:
SW1:
interface GigabitEthernet0/0/1
port link - type trunk
port trunk allow - pass vlan 2 3 28 30
interface GigabitEthernet0/0/2
port link - type trunk
port trunk allow - pass vlan 2 3 28 30
SW2:
interface GigabitEthernet0/0/1
port link - type trunk
port trunk allow - pass vlan 2 3 28 30
interface GigabitEthernet0/0/2
port link - type trunk
port trunk allow - pass vlan 2 3 28 30
生成树(STP)配置

1. 设置根桥和备份根桥
SW1:
stp mode stp
stp instance 0 priority 0  // VLAN2和VLAN3的主根
stp instance 1 priority 4096  // 作为VLAN28和VLAN30的备份根
SW2:
stp mode stp
stp instance 0 priority 4096  // 作为VLAN2和VLAN3的备份根
stp instance 1 priority 0  // VLAN28和VLAN30的主根
VLAN间路由(SVI配置)

1. 在SW1和SW2上配置SVI接口
SW1:
interface Vlanif2
ip address 10.0.2.1 24
interface Vlanif3
ip address 10.0.3.1 24
SW2:
interface Vlanif28
ip address 10.0.28.1 24
interface Vlanif30
ip address 10.0.30.1 24
2. 配置HSRP实现网关备份
SW1:
interface Vlanif2
standby 1 ip 10.0.2.254
standby 1 priority 110
interface Vlanif3
standby 2 ip 10.0.3.254
standby 2 priority 110
SW2:
interface Vlanif28
standby 3 ip 10.0.28.254
standby 3 priority 110
interface Vlanif30
standby 4 ip 10.0.30.254
standby 4 priority 110
路由器配置(AR1)

1. 配置接口IP地址
interface GigabitEthernet0/0/0
ip address 202.1.1.1 30
interface GigabitEthernet0/0/1
ip address 10.0.0.1 30
interface GigabitEthernet0/0/2
ip address 10.0.0.5 30
2. 配置静态路由
ip route - static 10.0.2.0 24 10.0.0.2
ip route - static 10.0.3.0 24 10.0.0.2
ip route - static 10.0.28.0 24 10.0.0.6
ip route - static 10.0.30.0 24 10.0.0.6
ip route - static 100.100.100.0 24 202.1.1.2

感悟

在本次网络实验中,从搭建拓扑开始就深刻体会到规划的重要性。清晰的拓扑结构是网络稳定运行的基础,明确各设备角色及链路连接方式,就像搭建房屋要有精确蓝图。比如确定AR1作为企业出口路由器,SW1、SW2作为汇聚层交换机等,合理布局才能让网络层次分明,便于后续配置与维护 。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值