4月 092015
 
Switch(config)#line ?
 <0-16> First Line number
 console Primary terminal line
 vty Virtual terminal

Switch(config)#line console ?
 <0-0> First Line number

Switch(config)#line vty ? 
 <0-15> First Line number

Switch(config)#

配置console控制台密码

Switch(config)#line console 0
Switch(config-line)#password hellocisco
Switch(config-line)#exec-timeout ?
 <0-35791> Timeout in minutes

Switch(config-line)#exec-timeout 0 ?
 <0-2147483> Timeout in seconds
 <cr>

Switch(config-line)#exec-timeout 0 0
Switch(config-line)#exit
Switch(config)#exit
Switch#wri

查看show run配置

! 
line con 0
 exec-timeout 0 0
 password hellocisco
line vty 0 4
 login
line vty 5 15
 login
!

配置telnet密码

Switch(config)#line vty 0 ?
 <1-15> Last Line number
 <cr>

Switch(config)#line vty 0 4
Switch(config-line)#password hellocisco
Switch(config-line)#exec-timeout 0 ?
 <0-2147483> Timeout in seconds
 <cr>

Switch(config-line)#exec-timeout 0 0
Switch(config-line)#login 
Switch(config-line)#exit
Switch(config)#exit
Switch#wri

查看telnet相关show run配置

! 
line con 0
 exec-timeout 0 0
 password hellocisco
line vty 0 4
 exec-timeout 0 0
 password hellocisco
 login
line vty 5 15
 login
!

配置SSH登录密码

对配置密码加密

默认仅enable加密密码为加密显示,对enable密码和用户模式密码(console/AUX/telnet/ssh)加密需手工指定

启用加密前

!
enable secret 5 $1$p3Nf$H1f9qXJ4OjS4p6fu447Dd/
enable password hellocisco
!
!
!
! 
line con 0
 exec-timeout 0 0
 password hellocisco
line vty 0 4
 exec-timeout 0 0
 password hellocisco
 login
line vty 5 15
 login
!

启用加密后

Switch(config)#service password-encryption 
Switch(config)#exit
Switch#wri
!
version 12.2
no service pad
service timestamps debug datetime msec
service timestamps log datetime msec
service password-encryption
!
!
enable secret 5 $1$p3Nf$H1f9qXJ4OjS4p6fu447Dd/
enable password 7 011B030857040506324F41
!
!
!
!
line con 0
 exec-timeout 0 0
 password 7 141F1707000B2922372B3C
line vty 0 4
 exec-timeout 0 0
 password 7 141F1707000B2922372B3C
 login
line vty 5 15
 login
!
4月 092015
 
Switch>en
Switch#configure terminal 
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#enable ?
 last-resort Define enable action if no TACACS servers respond
 password Assign the privileged level password (MAX of 25 characters)
 secret Assign the privileged level secret (MAX of 25 characters)
 use-tacacs Use TACACS to check enable passwords

Switch(config)#enable

配置enable密码

Switch(config)#enable password cisco

使用show run查看enable密码的配置

!
enable password cisco
!
!
!

保存并查看启动配置

Switch#show startup-config 
startup-config is not present
Switch#wri
Building configuration...
[OK]
Switch#show startup-config

再次登录提示输入enable密码

Switch>
Switch>en
Password: 
Switch#

已设置password再设置secret加密密码,提示建议更换密码

Switch(config)#enable secret cisco
The enable secret you have chosen is the same as your enable password.
This is not recommended. Re-enter the enable secret.

Switch(config)#

查看show run配置

!
enable secret 5 $1$p3Nf$H1f9qXJ4OjS4p6fu447Dd/
enable password cisco
!
!
!

取消enable密码设置仅保留enable加密密码设置

Switch(config)#no enable password 
Switch(config)#exit
Switch#sh run

再次查看show run配置

!
enable secret 5 $1$p3Nf$H1f9qXJ4OjS4p6fu447Dd/
!
!
!
4月 082015
 

使用Console线连接交换机

版本信息

Switch#sh ver
Cisco IOS Software, C2960 Software (C2960-LANBASEK9-M), Version 12.2(55)SE8, RELEASE SOFTWARE (fc2)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2013 by Cisco Systems, Inc.
Compiled Wed 26-Jun-13 11:34 by prod_rel_team
Image text-base: 0x00003000, data-base: 0x01900000

ROM: Bootstrap program is C2960 boot loader
BOOTLDR: C2960 Boot Loader (C2960-HBOOT-M) Version 12.2(53r)SEY3, RELEASE SOFTWARE (fc1)

Switch uptime is 25 minutes
System returned to ROM by power-on
System image file is "flash:/c2960-lanbasek9-mz.122-55.SE8/c2960-lanbasek9-mz.122-55.SE8.bin"


This product contains cryptographic features and is subject to United
States and local country laws governing import, export, transfer and
use. Delivery of Cisco cryptographic products does not imply
third-party authority to import, export, distribute or use encryption.
Importers, exporters, distributors and users are responsible for
compliance with U.S. and local country laws. By using this product you
agree to comply with applicable laws and regulations. If you are unable
to comply with U.S. and local laws, return this product immediately.

A summary of U.S. laws governing Cisco cryptographic products may be found at:
http://www.cisco.com/wwl/export/crypto/tool/stqrg.html

If you require further assistance please contact us by sending email to
export@cisco.com.

cisco WS-C2960-24TC-L (PowerPC405) processor (revision Y0) with 65536K bytes of memory.
Processor board ID FOC1835Y126
Last reset from power-on
1 Virtual Ethernet interface
24 FastEthernet interfaces
2 Gigabit Ethernet interfaces
The password-recovery mechanism is enabled.

64K bytes of flash-simulated non-volatile configuration memory.
Base ethernet MAC Address : 68:99:CD:14:C1:80
Motherboard assembly number : 73-12599-06
Power supply part number : 341-0097-03
Motherboard serial number : FOC18346QA7
Power supply serial number : DCA183387LZ
Model revision number : Y0
Motherboard revision number : B0
Model number : WS-C2960-24TC-L
System serial number : FOC1835Y126
Top Assembly Part Number : 800-32796-02
Top Assembly Revision Number : B0
Version ID : V11
CLEI Code Number : COM3K00BRF
Hardware Board Revision Number : 0x0A


Switch Ports Model SW Version SW Image 
------ ----- ----- ---------- ---------- 
* 1 26 WS-C2960-24TC-L 12.2(55)SE8 C2960-LANBASEK9-M 


Configuration register is 0xF

Switch#

配置信息

Switch#show run 
Building configuration...

Current configuration : 1231 bytes
 !
 version 12.2
 service config
 no service pad
 service timestamps debug datetime msec
 service timestamps log datetime msec
 no service password-encryption
 !
 hostname Switch
 !
 boot-start-marker
 boot-end-marker
 !
 !
 !
 !
 no aaa new-model
 system mtu routing 1500
 !
 !
 !
 !
 !
 !
 !
 !
 spanning-tree mode pvst
 spanning-tree extend system-id
 !
 vlan internal allocation policy ascending
 !
 !
 !
 interface FastEthernet0/1
 !
 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
 !
 interface FastEthernet0/11
 !
 interface FastEthernet0/12
 !
 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 GigabitEthernet0/1
 !
 interface GigabitEthernet0/2
 !
 interface Vlan1
 ip address dhcp
 !
 ip http server
 ip http secure-server
 !
 line con 0
 line vty 5 15
 !
 end

Switch#
4月 082015
 

Cisco Catalyst 2960PD-8TT-L 8个以太网 10/100 端口和1个10/100/1000 PoE输入端口;小尺寸,无风扇
Cisco Catalyst 2960-8TC-L 8个以太网10/100端口和1个两用上行端口(10/100/1000或SFP);小尺寸,无风扇
Cisco Catalyst 2960-24TT-L 24个以太网10/100端口和2个固定以太网10/100/1000 上行
Cisco Catalyst 2960-48TT-L 48个以太网10/100端口和2个固定以太网10/100/1000 上行端口
Cisco Catalyst 2960-24LT-L 24个以太网10/100端口(其中8个端口可支持PoE)和2个固定以太网10/100/1000上行端口
Cisco Catalyst 2960-24PC-L 24个以太网10/100 PoE端口和2个两用上行端口
Cisco Catalyst 2960-24TC-L 24个以太网10/100端口和2个两用上行端口
Cisco Catalyst 2960-48TC-L 48个以太网10/100端口和2个两用上行端口
Cisco Catalyst 2960G-8TC-L 8个以太网10/100/1000端口,其中有1个为两用端口;小尺寸,无风扇
Cisco Catalyst 2960G-24TC-L 24个以太网10/100/1000端口,其中有4个为两用端口
Cisco Catalyst 2960G-48-TC-L 48个以太网10/100/1000端口,其中有4个为两用端口cisco-catalyst-2960-series-switches-01 cisco-catalyst-2960x-series-switches-01

4月 062015
 

!
dot11 syslog
crypto pki token default removal timeout 0
!
!
username Cisco password 7 13261E010803
!
!
bridge irb
!
!
interface Dot11Radio0
no ip address
no ip route-cache
shutdown
antenna gain 0
station-role root
bridge-group 1
bridge-group 1 subscriber-loop-control
bridge-group 1 spanning-disabled
bridge-group 1 block-unknown-source
no bridge-group 1 source-learning
no bridge-group 1 unicast-flooding
!
interface GigabitEthernet0
no ip address
no ip route-cache
duplex auto
speed auto
bridge-group 1
bridge-group 1 spanning-disabled
no bridge-group 1 source-learning
!
interface BVI1
ip address dhcp client-id GigabitEthernet0
no ip route-cache
!
ip http server
no ip http secure-server
ip http help-path http://www.cisco.com/warp/public/779/smbiz/prodconfig/help/eag
bridge 1 route ip
!
!
!
line con 0
line vty 0 4
login local
transport input all
!
end