在3750交換機的ssh

首先交換機的IOS版本必須是K9的,這裏的ios版本是C3750 Software (C3750-ADVIPSERVICESK9-M), Version 12.2(35)SE2
PC直接連在交換機端口上,PC的ip地址是:192.168.1.1/24.
在交換機的操作步驟如下:
1.設置交換機管理ip
Switch#conf t
Switch(config)#int vlan 1
Switch(config-if)#ip add 192.168.1.2 255.255.255.0
Switch(config-if)#no sh
2.設置交換機enable密碼
Switch(config)#enable secret level 15 cisco
3.設置域名
Switch(config)#ip domain-name rtp.cisco.com
4.設置SSH key
Switch(config)#crypto key generate rsa general-keys modulus 1024
5.設置允許SSH
Switch(config-line)#transport input ssh
Switch(config-line)#login local
6.建立本地用戶名和密碼
Switch(config)#username ciscoxwl privilege 15 secret jakedragon
我用的是CRT軟件來SSH的
點擊:連接---快速連接: 
主機名:192.168.1.2
用戶名:ciscoxwl
其他默認
進去後,用戶名還是ciscoxwl,密碼是jakedragon,就可以進去了,直接就進到了全局配置模式.
 
 
sh run 如下:
Switch#  sh run
Building configuration...
Current configuration : 2342 bytes
!
version 12.2
no service pad
service timestamps debug uptime
service timestamps log uptime
no service password-encryption
!
hostname Switch
!
enable secret 5 $1$XKLS$0Wv568kqXjf5s1gWDpONk1
!
username ciscoxwl privilege 15 secret 5 $1$DftI$pD0X3LW.C84yDHVWgMHOR/
no aaa new-model
switch 2 provision ws-c3750-48p
system mtu routing 1500
ip subnet-zero
ip domain-name rtp.cisco.com
!
!
!
!
!        
!
no file verify auto
spanning-tree mode pvst
spanning-tree extend system-id
!
vlan internal allocation policy ascending
!
!
interface FastEthernet2/0/1
!
interface FastEthernet2/0/2
!
interface FastEthernet2/0/3
!
interface FastEthernet2/0/4
!
interface FastEthernet2/0/5
!
interface FastEthernet2/0/6
!
interface FastEthernet2/0/7
!
interface FastEthernet2/0/8
!
interface FastEthernet2/0/9
!
interface FastEthernet2/0/10
!
interface FastEthernet2/0/11
!
interface FastEthernet2/0/12
!
interface FastEthernet2/0/13
!
interface FastEthernet2/0/14
!
interface FastEthernet2/0/15
!
interface FastEthernet2/0/16
!
interface FastEthernet2/0/17
!
interface FastEthernet2/0/18
!
interface FastEthernet2/0/19
!        
interface FastEthernet2/0/20
!
interface FastEthernet2/0/21
!
interface FastEthernet2/0/22
!
interface FastEthernet2/0/23
!
interface FastEthernet2/0/24
!
interface FastEthernet2/0/25
!
interface FastEthernet2/0/26
!
interface FastEthernet2/0/27
!
interface FastEthernet2/0/28
!
interface FastEthernet2/0/29
!
interface FastEthernet2/0/30
!
interface FastEthernet2/0/31
!
interface FastEthernet2/0/32
!
interface FastEthernet2/0/33
!
interface FastEthernet2/0/34
!
interface FastEthernet2/0/35
!
interface FastEthernet2/0/36
!
interface FastEthernet2/0/37
!
interface FastEthernet2/0/38
!
interface FastEthernet2/0/39
!
interface FastEthernet2/0/40
!
interface FastEthernet2/0/41
!
interface FastEthernet2/0/42
!        
interface FastEthernet2/0/43
!
interface FastEthernet2/0/44
!
interface FastEthernet2/0/45
!
interface FastEthernet2/0/46
!
interface FastEthernet2/0/47
!
interface FastEthernet2/0/48
!
interface GigabitEthernet2/0/1
!
interface GigabitEthernet2/0/2
!
interface GigabitEthernet2/0/3
!
interface GigabitEthernet2/0/4
!
interface Vlan1
 ip address 192.168.1.2 255.255.255.0
!        
ip classless
ip http server
ip http secure-server
!
!
!
control-plane
!
!
line con 0
line vty 0 4
 login local
 transport input ssh
line vty 5 15
 login
!
end
 
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章