用戶模式  enableSwitch#   特權(quán)模式   configure terminalSwitch(config)#    Swi..."/>
溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊(cè)×
其他方式登錄
點(diǎn)擊 登錄注冊(cè) 即表示同意《億速云用戶服務(wù)條款》

cisco交換機(jī)

發(fā)布時(shí)間:2020-07-01 10:31:38 來源:網(wǎng)絡(luò) 閱讀:478 作者:小小三郎1 欄目:網(wǎng)絡(luò)安全

用戶模式、特權(quán)模式、全局模式

Switch>   用戶模式  enable

Switch#   特權(quán)模式   configure terminal

Switch(config)#    



Switch(config)#no ip domain-lookup  #關(guān)閉域名查找的功能


Switch(config-line)#logging   synchronous  #配置鼠標(biāo)選項(xiàng)

Switch(config)#hostname  ccna  #配置主機(jī)名

ccna(config)#no  hostname  ccna  #取消主機(jī)名


line console   0  

exec-timeout  0  0   #console  口配置  exec-timeout  5  30  五分鐘30s   0  0  不配置超時(shí)

回到上一層  exit

回到最初 用end



#安全 配置用戶模式下用戶密碼登陸

全局模式:

line console  0

password  123456

login

推出保存 下次登陸有密碼  這個(gè)密碼是進(jìn)入用戶模式時(shí)候的密碼


配置特權(quán)模式的密碼:

全局模式下配置 enable secret  123456  #加密的密碼



#配置telnet密碼


Switch(config)#line vty  0 3  #最多可以有四個(gè)人登陸

Switch(config-line)#pas

Switch(config-line)#password  123456

Switch(config-line)#login

Switch(config-line)#



#############保存配置 開機(jī)啟動(dòng)過的配置

Switch#copy running-config  startup-config

Destination filename [startup-config]?

Building configuration...

[OK]

Switch#


Switch#w  #wr或者w都可以  嘗試

Building configuration...

[OK]

Switch#



# 特權(quán)模式下  reload  代表重啟系統(tǒng)  



Switch#erase   startup-config

Erasing the nvram filesystem will remove all configuration files! Continue? [confirm]

[OK]

Erase of nvram: complete

%SYS-7-NV_BLOCK_INIT: Initialized the geometry of nvram

Switch#



#配置交換機(jī)的管理端口

interface vlan 1

Switch(config-if)#ip address   192.168.1.1  255.255.255.0

Switch(config-if)#no shu

Switch(config-if)#no shutdown


Switch(config-if)#

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


Switch(config-if)#



##配置交換機(jī)的默認(rèn)網(wǎng)關(guān)

Switch(config)#ip default-gateway  192.168.1.254

Switch(config)#



  1. no ip domain-lookup  #關(guān)閉域名查找的功能

  2. line console  0

    Switch(config-line)#logging  synchronous

  3. Switch(config-line)#exec-timeout     0   0

外加安全設(shè)置 


#查看端口的狀態(tài)

Switch#show  ip  interface   brief

Interface              IP-Address      OK? Method Status                Protocol


FastEthernet0/1        unassigned      YES manual down                  down


FastEthernet0/2        unassigned      YES manual down                  down


FastEthernet0/3        unassigned      YES manual down                  down


FastEthernet0/4        unassigned      YES manual down                  down


##############整理思路

1.配置主機(jī)名

hostname 

2.時(shí)鐘同步

clock timezone GMT 8

3.配置路由器的motd

banner motd #Hello , This is a LAB of ccietea.com#

4.配置console 口

R1(config)# line console 0 !! 進(jìn)入console口

R1(config-line)# no exec-time !! 配置console永不超時(shí),也可用命令exec-time 0 0

R1(config-line)# logging synchronous !! 配置console的日志同步功能,使得命令行界面彈出的日志信息不回打斷用戶正在輸入中的配置命令

R1(config-line)# exit

R1(config)# no ip domain lookup !! 關(guān)閉域名解析,以防在特權(quán)模式下敲錯(cuò)命令而陷入域名解析的過程

5.密碼配置  第一console口密碼 特權(quán)密碼

全局模式:

line console  0

password  123456

login

推出保存 下次登陸有密碼  這個(gè)密碼是進(jìn)入用戶模式時(shí)候的密碼


配置特權(quán)模式的密碼:

全局模式下配置 enable secret  123456  #加密的密碼


6.配置telnet密碼

R1(config)# line vty 0 4 !! 進(jìn)入VTY 0-4線路

R1(config-line)# password ccietea !! 設(shè)置VTY線路密碼,即用戶通過telnet登入路由器時(shí)輸入的密碼

R1(config-line)# login !! 使得Telnet登錄到本設(shè)備需用密碼驗(yàn)證

R1(config-line)# exit


向AI問一下細(xì)節(jié)

免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如果涉及侵權(quán)請(qǐng)聯(lián)系站長(zhǎng)郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。

AI