思科交换机实验(思科交换机实验大全)

交换机的配置实验方法

网络设备管理方式分为两种:带外管理与带内管理。接下来是我为大家收集的交换机的配置实验 方法 ,希望能帮到大家。

交换机的配置实验方法:

1、前言:

网络设备管理方式分为两种:带外管理与带内管理。本文所介绍的console(控制台)接口管理属于带内管理(这种管理模式用于安装交换机的时候进行配置,不知道对不对?)顺带介绍带外管理的一种实例telnet(Telecommunication Network)接口管理。

2、目的:

①console(控制台)端口配置交换机

②利用telnet端口配置交换机

③实现Ping并观察ICMP报文

3、内容:

①主机名的配置

②配置进入特权模式下的密码

③配置远程登录密码

④配置console登录密码

⑤VLAN的设置

网络拓扑如下:

配置开始:

1、电脑–Desktop–Terminal(默认)–enable进入特权模式

2、输入configure terminal(这一步的意思是配置终端)

3、输入enable password root回车之后设置特权模式下的密码为root

4、输入line console 0回车(line表示进入,这一步进入console配置),password root 回车之后设置console登录密码为root,输入exit回到主控制界面

5、输入line vty 0,passwo root设置远程登录密码为root(vty—Virtual Teletype Terminal)

6、end回车结束交换机的配置,完整命令如下所示

7、输入show running-configure可以看到配置的参数

8、在主控制界面下,输入interface vlan 1(设置所有的端口处于VLAN1)

9、ip address 192.168.1.1 255.255.255.0回车之后,输入no shutdown完成配置(shutdown命令取自DOS下的关机命令shutdown,加上之后表示开机)

10、电脑的配置:

至此为止,我已经完成了所有的配置!!!

4、测试:

1、进入PC的Terminal,输入root获得特权。(表示能进入交换机进行配置)

2、进入PC的虚拟DOS终端,输入ping 192.168.1.1

(模拟得还有模有样的,还掉包….)

3、输入telnet 192.168.1.1

密码是不回显的,请注意了!

至此为止,已经完成了实验所要求的目的!!!

5、注意事项:

1、连线的选择,我们选择用电脑控制交换机。那么交换机这边就应该连接console端口,电脑这边就应该使用RS 232串口进行连接,当然连线就不能选择所谓的Copper Straight-Through以及Copper Cross-Over了。如果连接错了怎么办?(我第一次也连接错了)错了就会出现一下图示:当然这只是一个例子,图中红色点表示接口与连线没有正常的接入,正常应该是绿色点。(参照上图)

而且你单机电脑–Terminal–OK之后只会出现空白(串口配置不能修改,默认的应该是9600 8 N 1并且flow control)之后进入Terminal之后就可以对交换机进行配置了。

2、我设置了三种密码,终端密码,特权密码以及远程终端登录密码,但是我只用到了两种密码!!!我自己不懂这里是什么原因

3、配置之后,一定要将配置写进FLASH里面

4、重启的按键在右下角,重启之前必须写进FLASH,我就上当了….重新写了一次,不过就当练习命令行了

看了“交换机的配置实验方法”还想看:

1. 交换机配置基础及实例讲解

2. 思科交换机基本配置实例讲解

3. 思科设备基本开局配置实验教程

4. Cisco交换机入门配置的方法

5. Cisco交换机基本配置的方法

思科交换机的基本配置

随着Internet的高速发展,网路规模不断膨胀,对于从事网路专业的学生熟练掌握路由器和交换机的配置已显得十分重要。接下来是我为大家收集的方法,希望能帮到大家。

的方法

一、交换机的基本配置

Author:chenchao in ZJNU

从本篇文章开始,将连载大概8-9篇自己学习交换与路由的实验报告,但是怕自己能力不行,会出现错误,所以,先载两篇文章,依次为:交换机的基本配置;路由器基本配置。本篇为交换机的基本配置,使用的模拟软体是Cisco的一款免费软体:Cisco Packet Tracer。想学习的可以在百度自行下载。

下面开始附上实验过程:

实验环境:

Cisco 2950交换机1台,Console电缆1根,PC机一台,网线1根。连线如下图所示:

实验步骤:

一、 交换机的带外配置;

1、 在使用者模式、特权模式、全域性模式、介面模式之间转换;

Switchenable

Switch#configure terminal

Enter configuration mands, one perline. End with CNTL/Z.

Switchconfig#interface FastEthernet 0/1

Switchconfig-if#exit

Switchconfig#exit

Switch#

%SYS-5-CONFIG_I: Configured from console byconsole

Switch#exit

Switch con0 is now available

Press RETURN to get started.

Switch

2、将交换机的名称改为“student”;

Switchconfig#hostname student

studentconfig#

3、 为交换机各个模式设定密码“cisco”;

特权模式下的密码保护

student#enable

student#configure t

Enter configuration mands, one perline. End with CNTL/Z.

studentconfig#enable password cisco

studentconfig#enable secret cisco1

远端登入口令设定

student#configure t

Enter configuration mands, one perline. End with CNTL/Z.

studentconfig#line console 0

studentconfig-line#line vty 0 4

studentconfig-line#password cisco2

studentconfig-line#login

studentconfig-line#

student#

4、为交换机制定一个IP地址10.10.10.X/24;

student#config

Configuring from terminal, memory, ornetwork [terminal]?

Enter configuration mands, one perline. End with CNTL/Z.

studentconfig#interface vlan 1

studentconfig-if#ip address 10.10.10.1255.0.0.0

5、开启交换机的Telnet服务功能,建立Telnet使用者admin,口令cisco,并制定只能从10.10.10.y/24登入Telnet伺服器;

student#

student#configure t

Enter configuration mands, one perline. End with CNTL/Z.

studentconfig#user admin password 0 cisco

studentconfig#

6、 检视配置情况;

studentenable

Password:

student#show running-c

Building configuration…

hostname student

!

enable secret 5$1$mERr$q.MA2tj.WFptzvbifq/1i.

enable password cisco

!

!

username admin password 0 cisco

interface Vlan1

ipaddress 10.10.10.1 255.0.0.0

!

!

line con 0

!

line vty 0 4

password cisco2

login

line vty 5 15

login

!

!

End

二、交换机的埠配置:

1、 配置介面的描述、关闭借口、启动介面、配置介面的速度为100Mbps、配置介面工作模式为全双工、配置介面的流程控制;

student#configure terminal

Enter configuration mands, one perline. End with CNTL/Z.

studentconfig#interface FastEthernet0/1

studentconfig-if#shutdown

%LINK-5-CHANGED: Interface FastEthernet0/1,changed state to administratively down

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

%LINEPROTO-5-UPDOWN: Line protocol onInterface Vlan1, changed state to down

studentconfig-if#

studentconfig-if#exit

studentconfig#interface FastEthernet0/1

studentconfig-if#no shutdown

%LINK-5-CHANGED: Interface FastEthernet0/1,changed state to up

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

%LINEPROTO-5-UPDOWN: Line protocol onInterface Vlan1, changed state to up

studentconfig-if#speed 100

studentconfig-if#duplex full

%LINK-5-CHANGED: Interface FastEthernet0/1,changed state to down

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

%LINEPROTO-5-UPDOWN: Line protocol onInterface Vlan1, changed state to down

studentconfig-if#

2、 配置介面FastEthernet0/10为Access口;

student#

student#configure terminal

Enter configuration mands, one perline. End with CNTL/Z.

studentconfig#interface FastEthernet0/10

studentconfig-if#switchport mode access

studentconfig-if#

3、 配置介面FastEthernet0/12为Trunk口;

student#

student#configure t

Enter configuration mands, one perline. End with CNTL/Z.

studentconfig#interface fastethernet0/12

studentconfig-if#switchport mode Trunk

studentconfig-if#end

4、 检视配置情况;

!

interface FastEthernet0/1

duplex full

speed100

!

interface FastEthernet0/2

!

interface FastEthernet0/9

!

interface FastEthernet0/10

switchport mode access

!

interface FastEthernet0/11

!

interface FastEthernet0/12

switchport mode trunk

!

student#show running-c

Building configuration…

Current configuration : 1275 bytes

!

version 12.1

no service timestamps log datetime msec

no service timestamps debug datetime msec

no service password-encryption

!

hostname student

!

enable secret 5$1$mERr$q.MA2tj.WFptzvbifq/1i.

enable password cisco

!

!

username admin password 0 cisco

!

!

interface FastEthernet0/1

duplex full

speed 100

!

interface FastEthernet0/2

!

interface FastEthernet0/3

!

interface FastEthernet0/4

!

interface FastEthernet0/5

!

interface FastEthernet0/6

!

interface FastEthernet0/7

!

interface FastEthernet0/8

!

interface FastEthernet0/9

!

interface FastEthernet0/10

switchport mode access

!

interface FastEthernet0/11

!

interface FastEthernet0/12

switchport mode trunk

!

interface FastEthernet0/13

!

interface FastEthernet0/14

!

interface FastEthernet0/15

!

interface FastEthernet0/16

!

interface FastEthernet0/17

!

interface FastEthernet0/18

!

interface FastEthernet0/19

!

interface FastEthernet0/20

!

interface FastEthernet0/21

!

interface FastEthernet0/22

!

interface FastEthernet0/23

!

interface FastEthernet0/24

!

interface GigabitEthernet1/1

!

interface GigabitEthernet1/2

!

interface Vlan1

ipaddress 10.10.10.1 255.0.0.0

!

!

line con 0

!

line vty 0 4

password cisco2

login

line vty 5 15

login

!

!

end

思科交换机关于MSTP的配置命令

1、首先我们按着如下图所示搭建一个实验的拓扑图。

2、按着上面的拓扑图我们首先配置接入层交换机的基本配置信息,如下图所示先将接入的PC的接口配置好。

3、将一台接入层 交换机和两台核心交换机的生成树模式都修改为MSTP多实例生成树模式。

4、接着我们就需要配置三台交换机之间的链路模式以及封装了,如下图所示在两两之间相连的线路上都需配置成TRUNK模式。

5、在核心交换机上运行VTP协议,是的三个交换机VLAN 信息可以同步。

6、我们设计将VLAN 10,VLAN 20分到一个实例12中,将VLAN 30,VLAN 40分到另一个实例34中,如下图所示我们开始配置MSTP。

7、现在我们来查看接入层交换机的生成树状态,如下图所示我们可以看在实例12中交换机的E0/1口为AP,在实例34中交换机的E0/0口为AP,实现了互为主备的关系,让交换网络实现的负载均衡。

思科装置基本开局配置实验教程

Cisco交换机Dot1x支援情况简述Cisco交换机支援标准的基于埠的802.1x认证,在网路上搜寻了一下好像还不支援基于MAC的802.1x认证。接下来是我为大家收集的方法,希望能帮到大家。

配置专案:

1、主机名

2、管理IP地址

3、远端管理开启

4、安全密码

实验拓扑图:

操作步骤:

1、配置主机名

R1#conf t 进入全域性配置模式

R1config#hostname R1-test 改主机名为R1-test

2、给路由器配置管理IP地址

R1-testconfig#int fa0/0

R1-testconfig-if#ip add 202.106.1.1 255.255.255.252

R1-testconfig-if#no shut

3、开启装置的远端管理功能

R1-testconfig#line vty 0 4 进入虚拟控制台埠一般设定最多允许5个使用者同时线上就够了

R1-testconfig-line#password abc 设定密码

R1-testconfig-line#login 开启验证

R1-testconfig-line#enable secret 123abc 配置特权查模式密码

4、给交换机配置管理IP地址

SW1config#int vlan 1 交换机配IP是要进vlan1配

SW1config-if#ip add 202.106.1.2 255.255.255.252

SW1config-if#no shut

SW1config#no ip routing 关闭路由功能

SW1config#ip default-gateway 202.106.1.1 给交换机指闸道器,使之连线外网

5、开启交换机远端管理

SW1config#line vty 0 4

SW1config-line#login local 使用本地使用者名称和密码进行验证,不使用介面密码验证

SW1config-line#username test privilege 15 password abc 加一个使用者为test,密码abc , 许可权设为15级

注:使用这种方法验证不需要设定特权模式密码

6、分别在SW1和R1上做远端管理测试

SW1 telnet R1:

R1 telnet sw1:

7、配置控制台密码

SW1config#line console 0

SW1config-line#password abc

SW1config-line#login

SW1config-line#enable secret 123abc

0

评论0