思科 GNS3 STP 生成树

 

Sw1

Switch>

Switch>

Switch>en

Switch#conf t

Enter configuration commands, one per line.  End with CNTL/Z.

Switch(config)#vl 10

Switch(config-vlan)#vl 20

Switch(config-vlan)#int f0/1

Switch(config-if)#sw a  v 10

Switch(config-if)#int f0/2

Switch(config-if)#sw a v 20

Switch(config-if)#int range f0/3-4

Switch(config-if-range)#sw m t

Sw2

Switch>en

Switch#conf t

Enter configuration commands, one per line.  End with CNTL/Z.

Switch(config)#vl 10

Switch(config-vlan)#vl 20

Switch(config-vlan)#int f0/1

Switch(config-if)#sw a v 10

Switch(config-if)#int f0/2

Switch(config-if)#sw a v 20

Switch(config-if)#int range f0/3-4

Switch(config-if-range)#sw m t

Sw3

Switch>en

Switch#conf t

Enter configuration commands, one per line.  End with CNTL/Z.

Switch(config)#vl 10

Switch(config-vlan)#vl  20

Switch(config-vlan)#int range f0/1-3

Switch(config-if-range)#sw t en d

Switch(config-if-range)#sw m t

Switch(config-if-range)#

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/2, changed state to up

Switch(config-if-range)#e

Switch(config)#ip routing

Switch(config)#int f0/2

Switch(config-if)#no switchport

Switch(config-if)#

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/2, changed state to up

Switch(config-if)#ip add 192.168.3.1 255.255.255.0

Switch(config-if)#no sh

Switch(config-if)#ex

Switch(config)#int vl  10

Switch(config-if)#

%LINK-5-CHANGED: Interface Vlan10, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan10, changed state to up

Switch(config-if)#ip add 192.168.1.1  255.255.255.0

Switch(config-if)#no sh

Switch(config-if)#int vl 20

Switch(config-if)#

%LINK-5-CHANGED: Interface Vlan20, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan20, changed state to up

Switch(config-if)#ip ad 192.168.2.1  255.255.255.0

Switch(config-if)#no sh

Switch(config-if)#ex

Sw4

Switch>en

Switch#conf t

Enter configuration commands, one per line.  End with CNTL/Z.

Switch(config)#vl  10

Switch(config-vlan)#vl  20

Switch(config-vlan)#int range  f0/1-3

Switch(config-if-range)#sw t en d

Switch(config-if-range)#sw  m t

Switch(config-if-range)#ex

Switch(config)#ip routing

Switch(config)#int vl 10

Switch(config-if)#

%LINK-5-CHANGED: Interface Vlan10, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan10, changed state to up

Switch(config-if)#ip add 192.168.1.2 255.255.255.0

Switch(config-if)#no sh

Switch(config-if)#int vl 20

Switch(config-if)#

%LINK-5-CHANGED: Interface Vlan20, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan20, changed state to up

ip add 192.168.2.2  255.255.255.0

Switch(config-if)#no sh

Switch(config-if)#int f0/1

Switch(config-if)#no switchport

Switch(config-if)#

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to up

ip add 192.168.3.2 255.255.255.0

Switch(config-if)#no sh

Switch(config-if)#ex

 

Sw3

Switch(config)#ip route 0.0.0.0  0.0.0.0  192.168.3.2指路

Switch(config)#spanning-tree vlan 10 root primary    设置生成树

Switch(config)#spanning-tree vlan 20 root secondary

sw4

Switch(config)#ip route 0.0.0.0  0.0.0.0 192.168.3.1

Switch(config)#spanning-tree vlan 20 root primary

Switch(config)#spanning-tree vlan 10 root secondary

Pc手动配置IP

 

 

 

 

 

  • 0
    点赞
  • 9
    收藏
  • 打赏
    打赏
  • 2
    评论
<strong><span style="color:#E53333;"># 数据链路层主要研究的三个基本问题</span></strong><br /><span> </span>    封装成帧:源mac,目的mac、帧开始符、帧结束符、帧校验序列<br /><span> </span>    透明传输:文本传输、可执行文件传输的界定符<br /><span> </span>    差错检验:发送端 环冗余检验CRC FCS帧校验序列 接收端亦CRC运算<br /><br /><strong><span style="color:#E53333;"># 点到点信道的数据链路</span></strong><br /><span> </span>    P2P封装成帧:PPP协议的特点;更换默认HDLC协议传输<br /><span> </span>    P2P透明传输:同步帧单位、零比特填充;异步字符单位、字节填充;CRC计算FCS<br /><br /><strong><span style="color:#E53333;"># 以太网特性</span></strong><br /><span> </span>    最短帧大小64字节及其测算过程<br /><span> </span>    冲突解决退避算法<br /><span> </span>    长度小于64字节时填充字段<br /><span> </span>    以太网信道利用率<br /><br /><span style="color:#E53333;"><strong># 广播信道的数据链路</strong></span><br />     <span></span>广播信道的局域网<br />     <span></span>以太网标准<br />     <span></span>CSMA/CD协议:带冲突检测的载波侦听多路访问协议。<br />     <span></span>以太网最短帧:保证有错误的反馈时间。<br />     <span></span>冲突解决方法:退避算法<br />     以太网帧格式<br />     <span></span>以太网信道利用率<br />     <span></span>网卡的作用<br />     <span></span>查看和更改MAC地址<br /><br /><strong><span style="color:#E53333;"># 网络设备特性对比</span></strong><br /><span> </span>    集线器、网桥、交换机与路由器<br /><br /><span style="color:#E53333;"><strong># 生成树协议STP</strong></span><br /><span> </span>    有效处理广播风暴的机理<br /><p> <img src="https://img-bss.csdnimg.cn/202008090927507381.png" alt="" /></p> <p> <br /></p> <p> <img src="https://img-bss.csdnimg.cn/202008090928012760.png" alt="" /></p> <p> <br /></p> <p> <br /></p>

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

数据库从删库到跑路

你的鼓励将是我创作的最大动力

¥2 ¥4 ¥6 ¥10 ¥20
输入1-500的整数
余额支付 (余额:-- )
扫码支付
扫码支付:¥2
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值