思科交换机2960配置
cisco2960交换机安装配置基础-电脑资料

cisco2960交换机安装配置基础-电脑资料cisco 2960 交换机安装配置基础新设备配置内容:1. interface vlan 1 的ip,gatewayconf tint vlan 1ip address xx.xx.xx.xx 255.255.255.0ip default-gateway ip-addressno shutdownexit2.en的密码3.line vty 0-4 telnet的密码4.wr存盘show interface vlan 1show run将F0/1-10端口加入到VLAN20中,对应以下命令interface range f0/1 -10switchport mode acccessswitchport access vlan 20注意,f0/1后面有个空格,然后才是-10cisco 2950 常用配置命令产品相关命令1、配置IP地址交换机要能够被网管,必须给它标识一个管理IP地址,默认情况下CISCO交换机的VLAN 1为管理VLAN,为该VLAN配上IP 地址,交换机就可以被网管了,。
命令如下:a、进入全局模式: Switch#configure terminalb、进入VLAN 1接口模式:Switch(config)#interface vlan 1c、配置管理IP地址:Switch(config-if) # ip address [A.B.C.D] [mask]如果当前VLAN 不是管理VLAN ,只需要将上面第b处命令的vlan 的号码换成管理VLAN的号码即可。
2、打开SNMP协议a、进入全局模式: Switch#configure terminalb、配置只读的Community,产品默认的只读Community名为publicSwitch(config)#snmp-server community public roc、配置可写的Community,产品默认的可写Community名为privateSwitch(config)#snmp-server community private rw3、更改SNMP的Community密码a、将设备分组,并使能支持的各种SNMP版本Switch(config)#snmp-server group qycx123 v1Switch(config)#snmp-server group qycx 123 v2cSwitch(config)#snmp-server group qycx123 v3 noauthb、分别配置只读和可写community 如:Switch(config)#snmp-server community qycx123 roSwitch(config)#snmp-server community qycx123 rw4、保存交换机配置Switch#copy run start常用命令1、设置交换机密码a、更改远程TELNNET密码Switch#configure terminalSwitch(config)#line vty 0 4Switch(config-line)#password qycx123Switch(config-line)#loginSwitch(config-line)#exitb、更改进入全局配置模式时的密码Switch#configure terminalSwitch(config)#enable secret qycx1232、创建并划分VLANa、创建VLANSwitch#vlan databaseSwitch(vlan)#vlan 99 name office(创建vlan 99 并命名为office)b、将端口划分至vlanSwitch(config)#interface fastEthernet 0/8Switch(config-if)#switchport mode accessSwitch(config-if)#switchport access vlan 99(将8号快速以太口划分至vlan 99)3、常用调试命令a、显示所有配置命令:Switch#show runb、显示所有接口状态:Switch#show ip int briefc、显示所有VLAN的信息:Switch#show vlan briefCisco之line vty线路使用Cisco的设备管理有很多种方式,如Console、HTTP、TTY、VTY或其它网管软件,但我们远程管理较为常用的一种方式肯定是VTY方式。
思科Catalyst2960 初始化配置

思科 Catalyst 2950/2960 初始化配置新购的思科交换机往往都没有说明书,要进行初始化配置,一般都需要专业的网络工程师,通过用CISCO随机带CONSOLE线,一端连在CISCO交换机的CONSOLE 口,一端连在计算机的COM口进行设置,这个我们下次再谈,先谈谈菜鸟级的配置。
实际上思科 Catalyst 2950/2960 已经具备了WEB的初始化设置功能,只是没有说明书或者是全英文的说明书,很多人不太了解,我们现在就讲讲这个,以方便非网络专业人员学习和设置。
第一步:交换机通电,各LED灯会依次不停的闪烁,等待3分钟。
第二步:等各LED灯无变化后,按下MODE按钮3-4秒不松,待MODE按钮上面的LED灯全亮后松开MODE按钮这个时候,交换机已经进入了设置状态第三步:将你的计算机网卡设置为自动获取IP地址,并打开DHCP第四步:将网络线(直通线)一头接到计算机的网卡,另一头接到交换机的1X 口,(注意:一定要1X口,其他口不行)这个时候你可以在计算机输入命令,CMD / ipconfig 你可以发现,你计算机取到的ip地址是 10.0.0.2如果不是,请重新从第一步开始。
第五步:打开计算机的浏览器,输入10.0.0.1 即可出现交换机的配置窗口,我的2960配置窗口居然还是全中文的,好爽。
第六步:依次按说明输入交换机的ip地址、子网掩码、网关、交换机名称、密码,以及远程telnet管理密码,点提交即可。
第七步:交换机将重新启动,按新的ip连接交换机即可。
整个初始化配置完成,是不是很简单,接下来你有三种方式进入交换机。
1. 还是通过计算机的COM口连接到交换机的CONSOLE口,这个我们下次再谈2. 通过计算机上的浏览器输入交换机的ip地址,输入交换机密码进入3. 通过计算机超级终端TCP/IP方式进入,输入交换机密码进入远程管理密码进入今天就到这里,下次我们谈谈通过CONSOLE口的配置。
思科交换机2960配置

cisco 交换机2960配置配置密码:2960>en ;第一次密码为空2960h#conf t ;进入全局配置模式2960(config)#hostname swa ;设置交换机名2960(config)#enable secret aaa ;设置特权加密口令为aaa2960(config)#enable password aax ;设置特权非密口令为aax2960(config)#line console 0 ;进入控制台口(Rs232)2960(config-line)#password aa ;设置登录口令aa2960(config-line)#login ;登录要求口令验证2960(config-line)#line vty 0 4 ;进入虚拟终端virtual tty2960(config-line)#password a ;设置登录口令a2960(config-line)#login ;登录要求口令验证2960(config-line)#exit ;返回上一层2960(config)#exit ;返回上一层2960#sh run ;看配置信息2960#exit ;返回命令配置Vlan新建一个Vlan的命令Switch>enable 进入特权模式Switch#configure terminal 进入全局配置模式Switch (config)# vlan vlan-id 创建一个Vlan或者进入Vlan配置模式Switch (config-vlan)# name vlan-name 给Vlan命名(取消设置:no name) Switch (config-vlan)# mtu mtu-size 设置最大通讯量(取消设置:no mtu) Switch (config-vlan)#remote-span 开启远程流量监控(关闭:no remote-span)Switch (config-vlan)# end 回到特权模式Switch#show vlan {name vlan-name | id vlan-id} 查看当前配置Switch#copy running-config startup config 保存配置删除Vlan的命令Switch>enable 进入特权模式Switch#configure terminal 进入全局配置模式Switch (config)# no vlan vlan-id 删除VlanSwitch (config)# end 回到特权模式Switch#show vlan brief 查看删除情况Switch#copy running-config startup config 保存配置端口加入特定Vlan的命令Switch>enable 进入特权模式Switch#configure terminal 进入全局配置模式Switch (config)# interface interface-id 进入端口配置Switch (config-if)# switchport mode access 将接口的模式设为访问模式Switch (config-if)# switchport access vlan vlan-id 将端口加入指定的Vlan(恢复端口默认配置:default interface interface-id)Switch (config-if)# end 回到特权模式Switch#show running-config interface interface-id 查看端口模式Switch#show interfaces interface-id switchport 查看端口详细配置Switch#copy running-config startup-config 保存配置批量端口加入特定Vlan的命令int range fa0/1 - 10switchport access VLan V2将特定端口设为trunk2960-01(config)#default interface fastEthernet 0/1 端口恢复默认值2960-01(config)#interface fastethernet0/1 进入端口模式2960-01(config-if)#switchport mode trunk 设置端口为trunk模式2960-01(config-if)#switchport nonegotiate 将接口设置为不协商模式2960-01(config-if)end2960-01#wr启用snmpSwitch>enable 进入特权模式Switch#configure terminal 进入全局配置模式Switch (config)# snmp-server community string [view view-name] [ro | rw] [access-list-number](关闭snmp: no snmp-server)(删除团体字符: no snmp-server community string) 配置snmp团体字符并开启snmp代理服务String: 团体口令字符(所有SNMP命令中只有设置团体口令的snmp-server community是必须的,其它的都是可选的.)View: view 可以用于限定哪些MIB分支不能用本community-string存取预先用snmp-server view定义ro | rw: ro获得MIB对象信息;rw获得并可以修改MIB对象信息access-list-number:访问列表号Switch (config)#access-list access-list-number {deny |permit} source [source-wildcard] 配置拒绝或者允许访问snmp代理服务的IP地址,访问列表号为上一步指定的列表号Switch (config)#end 回到特权模式Switch#show running-config 查看配置Switch#copy running-config startup-config 保存配置cisco2960口令恢复交换机口令恢复的步骤⒈串口线连接到到交换机的console口。
Cisco交换机2960配置简化步骤-For PKS

2960配置方法-For Honeywell Experion系统使用的配置文件:2u-2960-24.text一、交换机配置线连接,从Console口连接到电脑Step Action1 Connect the RS-232 cable to the Switch's Comm Port and the computer'sserial port. 使用配置线从RS232接口连到交换机Console口;2 Click Start > Programs > Accessories > Communications > HyperTerminal.启动超级终端软件;win7以后系统不带,需要自己准备;3 From the Connect To dialog, select the serial port being used by thecomputer and click OK.任意选择并连接,注意COM接口要选正确的那个4 From the Properties page configure the following Port Settings:o Bits per second: 9600o Data Bits: 8o Parity: NONEo Stop bits: 1o Flow control: Xon/Xoff5 Click OK. Power up the switch and go to the next procedure.二、Configure switch options交换机选项配置Step Action1 当看到下面提示时,请按照黑色字体文字操作;中间过程会出现很多信息,在本文中省略了。
Would you like to enter the initial configuration dialog? [yes/no]: y Would you like to enter basic management setup? [yes/no]: yEnter host name [Switch]: Switch1……Enter enable secret: passwordEnter enable password: password1Enter virtual terminal password: password1Configure SNMP Network Management? [no]: NEnter interface name used to connect to themanagement network from the above interface summary: vlan1 Configuring interface Vlan1:Configure IP on this interface? [yes/no]: NWould you like to enable as a cluster command switch? [yes/no]: N The following configuration command script was created:[0] Go to the IOS command prompt without saving this config.[1] Return back to the setup without saving this config.[2] Save this configuration to nvram and exit.Enter your selection [2]: 2Building configuration...[OK]Use the enabled mode 'configure' command to modify this configuration.三、Setup switch IP addressing, SNMP traps and NTP time serviceStep Action1 Use the enable command and the enable secret you previously established: Press RETURN to get started!<ENTER>Switch1>enablePassword: passwordSwitch1#config tSwitch1(config)#int vlan1Switch1(config-if)#ip address 10.1.1.223 255.255.0.0Switch1(config-if)#exitSwitch1(config)#exitSwitch1#*Mar 1 00:06:03: %SYS-5-CONFIG_I: Configured from console by console <ENTER>四、Perform an Xmodem file transferStep Action1 Initiate the transfer in the switch using the copy command. Type all values thatappear in bold.Switch1#copy xmodem: system:running-configDestination filename [running-config]?<ENTER>2 Initiate the transfer in Hyperterm and choose the appropriate switchconfiguration file:o From the Hyperterm menu bar, select Transfer >Send File.o Select Browse and navigate to the Switch Configuration folder in thefollowing location: Disk Drive:\FTE_Drivero Select the correct switch configuration file for your particular system andclick OPEN.o Select Xmodem under Protocol.o Click Send to start the file transfer.注:这一步一定要快,一般在4个C左右就开始Send。
cisco2960配置

Vlan
1,創建Vlan
(config)#vlan 180 //創建Vlan ID號為180
(config-vlan)#name askey //Vlan 名稱為askey
2,刪除Vlan
(config)#no vlan 180
#show vlan brief //查看交換機當前Vlan 號及Vlan 下有哪些端口
(config-line)#exec-timeout 5 0 //telnet 5分鐘超時
Show
1,開啟明文密碼加密服務
1,show run //查看交換機配置
2,show ip int brief //查看所有端口狀況
3, show int des //查看所有端口的描述
2,設置時間與時區
(config)# Clock timezone TAIWAN 8 //設置時區
(config)# Clock set 12:16:50 nov 27 2008 //設置時間(月﹐日﹐年)
#Show clock //查看交換機當前的時間
3﹐設置ntp server 實現時間同步
(config-if)# storm-control broadcast level 0.80 //控制广播包的突发百分比
(config-if)# storm-control action shutdown //暴风控制的违例时端口进入errdisable
(config-if)# storm-control action trap //产生snmp trap(抑制)消息来通告发生过量流量的情况
(config-if)#switchport access vlan 33 // 划分VLAN
Catalyst2960交换机基本配置

配置端口
Copyright Hoare Lecture. All rights reserved.
配置一组端口
Step 1
Step 2 Step 3 Step 4 Step 5 Step 6 end show interfaces [interface-id] copy running-config startup-config 命令 configure terminal interface range {portrange} 目的 进入配置状态 进入组配置状态 可以使用平时的端口配置 命令进行配置 退回 验证配置 保存
Copyright Hoare Lecture. All rights reserved.
8
interface-id
• Physical interface instance. Naming notation is rack/slot/module/port and a slash between values is required as part of the notation.
通常情况下,二层交换机的端口不设置IP地址,路 由器的接口设置IP地址,三层交换机(实际上有路 由功能)的接口可以设置也可以不设置,具体情况 具体分析。 不跨网段管理可不设默认网关。
Copyright Hoare Lecture. All rights reserved. 6
Cisco Catalyst 2960系列交换机
连接配置模式 全局配置模式输入 line vty或line console 命令 vlan配置模式 全局配置模式输入 vlan database命令 Switch(configline)# Switch(vlan)#
2960交换机简要配置手册(中文)21页word

2960交换机简明配置维护手册目录说明 (3)产品特性 (3)配置端口 (3)配置一组端口 (3)配置二层端口 (5)配置端口速率及双工模式 (5)端口描述 (6)监控及维护端口 (7)监控端口和控制器的状态 (7)刷新、重置端口及计数器 (9)关闭和打开端口 (10)配置VLAN (10)理解VLAN (11)可支持的VLAN (11)配置正常范围的VLAN (11)生成、修改以太网VLAN (11)删除VLAN (13)将端口分配给一个VLAN (14)配置VLAN Trunks (15)使用STP实现负载均衡 (18)配置Cluster (23)说明本手册只包括日常使用的有关命令及特性,其它未涉及的命令及特性请参考英文的详细配置手册。
产品特性2960是只支持二层的交换机支持VLAN∙到250 个VLAN∙支持VLAN ID从1到4094(IEEE 802.1Q 标准)∙支持ISL及IEEE 802.1Q封装安全∙支持IOS标准的密码保护∙支持标准及扩展的访问列表来定义安全策略∙支持基于VLAN的访问列表监视∙交换机LED指示端口状态∙SPAN及远端SPAN (RSPAN) 可以监视任何端口或VLAN的流量∙内置支持四组的RMON监控功能(历史、统计、告警及事件)配置端口配置一组端口命令目的Step 1configure terminal进入配置状态Step 2interface range {port-range} 进入组配置状态Step 3可以使用平时的端口配置命令进行配置Step 4end退回Step 5show interfaces[interface-id] 验证配置保存Step 6copy running-configstartup-config当使用interface range命令时有如下的规则:∙有效的组范围:o vlan从1 到4094o fastethernet槽位/{first port} - {last port}, 槽位为0o gigabitethernet槽位/{first port} - {last port},槽位为0o port-channel port-channel-number - port-channel-number, port-channel号从1到64∙端口号之间需要加入空格,如:interface range fastethernet 0/1 – 5是有效的,而interface range fastethernet 0/1-5是无效的.∙interface range命令只能配置已经存在的interface vlan∙所有在同一组的端口必须是相同类别的。
Catalyst2960配置步骤

Catalyst2960配置步骤1 、需要科技处提供VLAN _ID和IP地址,掩码,网关;2 、2960初始化的IP地址为10.0.0.1,默认启用DHCP,为了方便连接,可将计算机的IP 地址设置为10.0.0.2,掩码255.255.255.0,用一根直通线连接此计算机;3 、另一端连接交换机任意Ethernet口,按交换机上的Reset键直到Reset键左边除第2个和第3个以外所有的LED为绿色进入交换机快速设置模式;4、打开IE,在地址栏输入http://10.0.0.1,可进入交换机的快速设置界面;5、在快速设置界面上,第1行输入VLAN_ID;6、在第2行给交换机设置一个IP地址和掩码;7、第3行输入设置网关;8、第6行启用telnet;9、第7行设置telnet登录密码;10、保存设置后交换机会自动重新启动;11、在计算机IE地址栏输入http://95.*.*.*(即新分配给交换机的IP地址),可以进入交换机的设备管理界面,证明设置成功;12、在设备管理界面左边的树形菜单中,可以查看交换机到各个端口已经划分到新的VLAN 中,如果有误可telnet登录到交换机重新进行配置,如果设置不成功可以初始化交换机重新进行配置,具体方法是:按住交换机Reset键直到Reset键左边所有LED处于时亮时灭的状态,然后交换机会自动重新启动初始化为出厂设置,再重复上述步骤直到设置成功为止;13、在计算机“开始”->“运行”中输入cmd进入command窗口,在提示符后输入telnet 95.*.*.*并在接下来的password:后输入刚才设置的密码登录到交换机;14、在switch>提示符后输入enable进入特权模式;15、在switch(enable)#提示符后输入show vlan可以查看各个端口的配置情况;16、在switch(enable)#提示符后输入exit;17、交换机不能启用端口汇聚Trunk功能,设置步骤如下:在switch#提示符后输入configure在switch(config)#提示符后输入interface在switch(config-if)#提示符后输入switchport mode access在switch(config-if)#提示符后输入switchport access vlan vlan_id在switch(config-if)# 提示符后输入end。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
cisco 交换机2960配置配置密码:2960>en ;第一次密码为空2960h#conf t ;进入全局配置模式2960(config)#hostname swa ;设置交换机名2960(config)#enable secret aaa ;设置特权加密口令为aaa2960(config)#enable password aax ;设置特权非密口令为aax2960(config)#line console 0 ;进入控制台口(Rs232)2960(config-line)#password aa ;设置登录口令aa2960(config-line)#login ;登录要求口令验证2960(config-line)#line vty 0 4 ;进入虚拟终端virtual tty2960(config-line)#password a ;设置登录口令a2960(config-line)#login ;登录要求口令验证2960(config-line)#exit ;返回上一层2960(config)#exit ;返回上一层2960#sh run ;看配置信息2960#exit ;返回命令配置Vlan新建一个Vlan的命令Switch>enable 进入特权模式Switch#configure terminal 进入全局配置模式Switch (config)# vlan vlan-id 创建一个Vlan或者进入Vlan配置模式Switch (config-vlan)# name vlan-name 给Vlan命名(取消设置:no name) Switch (config-vlan)# mtu mtu-size 设置最大通讯量(取消设置:no mtu) Switch (config-vlan)#remote-span 开启远程流量监控(关闭:no remote-span)Switch (config-vlan)# end 回到特权模式Switch#show vlan {name vlan-name | id vlan-id} 查看当前配置Switch#copy running-config startup config 保存配置删除Vlan的命令Switch>enable 进入特权模式Switch#configure terminal 进入全局配置模式Switch (config)# no vlan vlan-id 删除VlanSwitch (config)# end 回到特权模式Switch#show vlan brief 查看删除情况Switch#copy running-config startup config 保存配置端口加入特定Vlan的命令Switch>enable 进入特权模式Switch#configure terminal 进入全局配置模式Switch (config)# interface interface-id 进入端口配置Switch (config-if)# switchport mode access 将接口的模式设为访问模式Switch (config-if)# switchport access vlan vlan-id 将端口加入指定的Vlan(恢复端口默认配置:default interface interface-id)Switch (config-if)# end 回到特权模式Switch#show running-config interface interface-id 查看端口模式Switch#show interfaces interface-id switchport 查看端口详细配置Switch#copy running-config startup-config 保存配置批量端口加入特定Vlan的命令int range fa0/1 - 10switchport access VLan V2将特定端口设为trunk2960-01(config)#default interface fastEthernet 0/1 端口恢复默认值2960-01(config)#interface fastethernet0/1 进入端口模式2960-01(config-if)#switchport mode trunk 设置端口为trunk模式2960-01(config-if)#switchport nonegotiate 将接口设置为不协商模式2960-01(config-if)end2960-01#wr启用snmpSwitch>enable 进入特权模式Switch#configure terminal 进入全局配置模式Switch (config)# snmp-server community string [view view-name] [ro | rw] [access-list-number](关闭snmp: no snmp-server)(删除团体字符: no snmp-server community string) 配置snmp团体字符并开启snmp代理服务String: 团体口令字符(所有SNMP命令中只有设置团体口令的snmp-server community是必须的,其它的都是可选的.)View: view 可以用于限定哪些MIB分支不能用本community-string存取预先用snmp-server view定义ro | rw: ro获得MIB对象信息;rw获得并可以修改MIB对象信息access-list-number:访问列表号Switch (config)#access-list access-list-number {deny |permit} source [source-wildcard] 配置拒绝或者允许访问snmp代理服务的IP地址,访问列表号为上一步指定的列表号Switch (config)#end 回到特权模式Switch#show running-config 查看配置Switch#copy running-config startup-config 保存配置cisco2960口令恢复交换机口令恢复的步骤⒈串口线连接到到交换机的console口。
⒉先按住交换机面板上的mode键,然后打开电源。
⒊初始化flash。
>flash_init⒋更名含有password的配置文件。
>rename flash:config.text flash:config.old⒌启动交换机。
>boot⒍进入特权模式。
>enable⒎此时开机是已忽略password。
#rename flash:config.old flash:config.text⒏copy配置文件到当前系统中。
#copy flash:config.text system:running-config⒐修改口令。
#configure terminal#enable secret⒑保存配置。
#write日志评论(1)21配置步骤注释配置密码Switch>en 特权模式Switch#conf t 配置模式Switch(config)#host SAT2960 改变设备名称Switch(config)#ena se cisco 特权口令Switch(config)#line vty 0 15 修改远程登陆口令Switch(config-line)#loginSwitch(config-line)#password ciscoSwitch(config-line)#line con 0 修改串口登陆口令Switch(config-line)#loginSwitch(config-line)#password nocoSwitch(config-line)#exitSwitch(config)#exitSwitch#创建VLAN (特权模式下用vlan database命令)SAT2960#vlan databaseSAT2960(vlan)#vlan 2 name Marketing 创建并命名VLAN 2 modified:Name: MarketingSAT2960(vlan)#apply 应用APPLY completeSAT2960(vlan)#(Ctrl+C)退出SAT2960#sh vlan brief 验证设置IP信息默认情况下,VLAN1是管理VLAN,所有接口均是VLAN1的成员SAT2960(config)#int vlan1 进入管理VLANSAT2960(config-if)#ip address 172.16.10.16 255.255.255.0SAT2960(config-if)#no shut 打开接口SAT2960(config-if)#exitSAT2960(config)#ip default-gateway 172.16.10.1SAT2960(config)#SAT2960交换机配置文件的擦除:SAT2960交换机配置文件是存储在NVRAM中的,使用copy run start 来保存当前运行的配置到NVRAM中,擦除SAT2960 里面的start-config文件,使用命令:SAT2960#erase start-configSAT2960#reload配置端口描述:(使用description 命令)SAT2960(config)#int fa 0/1SAT2960(config-if)#description hahaSAT2960(config-if)#exit可以使用show interface 和show running-config 命令来查看这些描述信息;给VLAN分配端口:SAT2960(config-if)#int f0/2SAT2960(config-if)#switchport access vlan 2SAT2960(config-if)#int f0/3SAT2960(config-if)#switchport access vlan 3SAT2960(config-if)#int f0/4SAT2960(config-if)#switchport access vlan 4SAT2960(config-if)#exitSAT2960(config)#exit验证配置信息,如下:SAT2960#sh vlan brief配置中继端口——打trunkSAT2960(config)#int f0/12SAT2960(config-if)#switchport mode trunkSAT2960(config-if)#(ctrl+c)SAT2960#验证配置信息:SAT2960#sh run保存设置SAT2960#wr mem或者SAT2960#copy running-config startup-config常用调试命令a、显示所有配置命令:Switch#show runb、显示所有接口状态:Switch#show ip int briefc、显示所有VLAN的信息:Switch#show vlan brief。