Cisco 浜ゆ崲鏈洪厤缃殑鍩烘湰鍛戒护
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Cisco 浜ゆ崲鏈洪厤缃殑鍩烘湰鍛戒护相关的知识,希望对你有一定的参考价值。
鏍囩锛?a href='http://www.mamicode.com/so/1/%e7%99%bb%e5%bd%95' title='鐧诲綍'>鐧诲綍
璁剧疆 瀹夎 鍏卞瓨 access timeout link 鎿嶄綔 鐞嗚В1.涓嶅悓鐨剉lan
涓嶅悓vlan闇€瑕佽矾鐢?br />鍦ㄨ矾鐢辩殑绔彛璁剧疆澶氫釜IP娈?br />
2.鏌ョ湅绔彛鍚嶅瓧
SWA#sh vlan
default Active F0/1, F0/2, F0/3, F0/4, F0/5, F0/6, F0/7, F0/8
f鏄鍙e悕瀛?br /> default Active Gi/1, Gi0/2, Gi0/3, Gi0/4, Gi0/5, Gi0/6, Gi0/7, Gi0/8
Gi鏄鍙e悕瀛?/p>
3.鍒涘缓鍔ㄦ€侀摼璺仛鍚?/p>
Switch(config)#interface range g0/21-22
Switch(config-if-range)#channel-group 1 mode active
Switch(config-if-range)#exit
4.鍒涘缓绔彛鐨勯摼璺被鍨?/p>
浠ュお缃戠鍙f湁涓夌閾捐矾绫诲瀷锛欰ccess銆丠ybrid銆乀runk銆侫ccess绫诲瀷鐨勭鍙e彧鑳藉睘浜?涓猇LAN锛屼竴鑸敤浜庤繛鎺ヨ绠楁満鐨勭鍙o紱Trunk 绫诲瀷鐨勭鍙e彲浠ュ睘浜庡涓猇LAN锛屽彲浠ユ帴鏀跺拰鍙戦€佸涓猇LAN鐨勬姤鏂囷紝涓€鑸敤浜庝氦鎹㈡満涔嬮棿杩炴帴鐨勭鍙o紱Hybrid绫诲瀷鐨勭鍙e彲浠ュ睘浜庡涓猇LAN锛屽彲浠ユ帴鏀跺拰鍙戦€佸涓猇LAN鐨勬姤鏂囷紝鍙互鐢ㄤ簬浜ゆ崲鏈轰箣闂磋繛鎺ワ紝涔熷彲浠ョ敤浜庤繛鎺ョ敤鎴风殑璁$畻鏈恒€侶ybrid绔彛鍜孴runk绔彛鐨勪笉鍚屼箣澶勫湪浜嶩ybrid绔彛鍙互鍏佽澶氫釜VLAN鐨勬姤鏂囧彂閫佹椂涓嶆墦鏍囩锛岃€孴runk绔彛鍙厑璁哥己鐪乂LAN鐨勬姤鏂囧彂閫佹椂涓嶆墦鏍囩銆?/p>
琛?-9 璁剧疆浠ュお缃戠鍙g殑閾捐矾绫诲瀷
鎿嶄綔
鍛戒护
璁剧疆绔彛涓篈ccess绔彛
Switch(config)#interface range g0/21-22
Switch(config)#switchport mode access
璁剧疆绔彛涓篐ybrid绔彛
Switch(config)#interface range g0/21-22
Switch(config)#switchport mode hybrid
璁剧疆绔彛涓篢runk绔彛
Switch(config)#interface range g0/21-22
Switch(config)#switchport mode trunk
鎭㈠绔彛鐨勯摼璺被鍨嬩负缂虹渷鐨凙ccess绔彛
undo port link-type
涓夌绫诲瀷鐨勭鍙e彲浠ュ叡瀛樺湪涓€鍙颁互澶綉浜ゆ崲鏈轰笂锛屼絾Trunk绔彛鍜孒ybrid绔彛涔嬮棿涓嶈兘鐩存帴鍒囨崲锛屽彧鑳藉厛璁句负Access绔彛锛屽啀璁剧疆涓哄叾浠栫被鍨嬬鍙c€備緥濡傦細Trunk绔彛涓嶈兘鐩存帴琚缃负Hybrid绔彛锛屽彧鑳藉厛璁句负Access绔彛锛屽啀璁剧疆涓篐ybrid绔彛銆?/p>
缂虹渷鎯呭喌涓嬶紝绔彛涓篈ccess绔彛銆?/p>
闇€瑕佹敞鎰忕殑鏄細Access绔彛鍔犲叆鐨刅LAN蹇呴』宸茬粡瀛樺湪骞朵笖涓嶈兘鏄己鐪乂LAN锛汬ybrid绔彛鍔犲叆鐨刅LAN蹇呴』宸茬粡瀛樺湪锛汿runk绔彛鍔犲叆鐨刅LAN涓嶈兘鏄己鐪乂LAN銆?/p>
鎵ц浜嗘湰閰嶇疆锛屽綋鍓嶄互澶綉绔彛灏卞彲浠ヨ浆鍙戞寚瀹歏LAN鐨勬姤鏂囥€侶ybrid绔彛鍜孴runk绔彛鍙互鍔犲叆鍒板涓猇LAN涓紝浠庤€屽疄鐜版湰浜ゆ崲鏈轰笂鐨刅LAN涓庡绔氦鎹㈡満涓婄浉鍚孷LAN鐨勪簰閫氥€侶ybrid绔彛杩樺彲浠ヨ缃摢浜沄LAN鐨勬姤鏂囨墦涓婃爣绛撅紝鍝簺涓嶆墦鏍囩锛屼负瀹炵幇瀵逛笉鍚孷LAN鎶ユ枃鎵ц涓嶅悓澶勭悊娴佺▼鎵撲笅鍩虹
5.浜ゆ崲鏈烘樉绀哄懡浠?nbsp;
鎬濈閲嶅惎
鎬濈鎵€鏈夌殑閲嶅惎鍛戒护閮芥槸reload
浜ゆ崲鏈烘樉绀哄懡浠わ細
switch#write 锛涗繚瀛橀厤缃俊鎭?br />switch#show vtp 锛涙煡鐪媣tp閰嶇疆淇℃伅
switch#show run 锛涙煡鐪嬪綋鍓嶉厤缃俊鎭?br />switch#show vlan 锛涙煡鐪媣lan閰嶇疆淇℃伅
switch#show interface 锛涙煡鐪嬬鍙d俊鎭?br />switch#show int f0/0 锛涙煡鐪嬫寚瀹氱鍙d俊鎭?br />switch#show cdp nei 锛涙煡鐪嬬鍙d笂琛岃澶囧強杩炴帴鐨勫搴旂鍙d俊鎭?br />switch#show ip int bir 鏌ョ湅绔彛VLAN IP 寮€鍚姸鎬佹€昏
switch#show int status 鏌ョ湅绔彛鐘舵€佹€昏
switch#show inventory 鏌ョ湅鍏夋ā鍧楁樉淇?br />switch#sh int etherchannel sum 鏌ョ湅“绔彛鑱氬悎/閾捐矾鎹嗙粦
switch#sh int port-channel 鏌ョ湅“绔彛鑱氬悎/閾捐矾鎹嗙粦
switch#show spanning-tree 鏌ョ湅鐢熸垚鏍戠姸鎬?br />switch#show access-list 鏌ョ湅瑙勫垯鐘舵€?br />switch#show history 鏌ョ湅鍘嗗彶杈撳叆鍛戒护
switch#show errdisable recovery 鏌ョ湅鍝簺淇濇姢浼氬湪瓒呮椂鍚庡彲鑷姩鎭㈠
switch#show errdisable detect?鏌ョ湅 err-disabled 鐘舵€佺殑鍘熷洜
6.閰嶇疆vlan鐨処P
s(config)#int vlan 6
s(config-vlan)#no shu
s(config-vlan)#ip add 10.2.20.1 255.255.255.254
SWA#wr
7.閰嶇疆浜ゆ崲鏈虹殑IP鍜岀綉鍏?/p>
閰嶇疆浜ゆ崲鏈虹綉鍏筹細Switch锛坈onfig锛?ip default-gateway 缃戝叧
switch(config)#int vlan 1
璁剧疆ip鍦板潃鍜屾帺鐮?
switch(config-if)#ip address 10.65.1.3 255.255.0.0
璁剧疆switch鐨勭綉鍏?
switch(config)#ip defaule-gateway 10.65.1.9
鏌ョ湅褰撳墠閰嶇疆:
switch#sh run
8.娓呴櫎鎬濈鎵€鏈夐厤缃?/p>
SWA#del vlan.dat
SWA#reload
9.鍒犻櫎鍔ㄦ€侀摼鎺?/p>
Switch(config)#interface range g0/21-22
Switch(config-if-range)#no channel-group 1
Switch(config-if-range)#exit
10.璁剧疆vtp
switch(config)#vtp domain 锛涜缃彂vtp鍩熷悕
switch(config)#vtp password 锛涜缃彂vtp瀵嗙爜
switch(config)#vtp mode server 锛涜缃彂vtp妯″紡
switch(config)#vtp mode client 锛涜缃彂vtp妯″紡
11.璁剧疆鎬濈浜ゆ崲鏈虹殑IP鍜屽瓙缃戞帺鐮?/p>
switch#conf t
杩涘叆榛樿VLAN鐘舵€?
switch(config)#int vlan 1
璁剧疆ip鍦板潃鍜屾帺鐮?
switch(config-if)#ip address 10.65.1.3 255.255.0.0
璁剧疆switch鐨勭綉鍏?
switch(config)#ip defaule-gateway 10.65.1.9
鏌ョ湅褰撳墠閰嶇疆:
switch#sh run
SWA#write
12.鎬濈telnet鐧婚檰鏂规硶
寮€濮?-cmd---telnet
13.鎬濈淇濆瓨鏂规硶
鍦ㄥ叏灞€閰嶇疆妯″紡涓?br />Router#copy running-config startup-config //淇濆瓨褰撳墠鐨勯厤缃?br />鎴?br />Router#write
涔熻
14.鎬濈鏌ョ湅vlan
SWA#sh vlan
15.鎬濈鏌ョ湅褰撳墠閰嶇疆
鏌ョ湅褰撳墠閰嶇疆:
switch#sh run
16.鎬濈鎭㈠鍑哄巶璁剧疆
Switch#erase startup-config
Switch#reload
鏈夋彁绀鸿淇濆瓨閰嶇疆 灏遍€夋嫨no
17.鎬濈灏嗙鍙e姞鍏lan
SWA(config)#int f0/5 (f鏄鍙e彿sh vlan鍙互鐪嬬鍙e彿锛岀鍙e彿鏄笉涓€鏍风殑鎴戜滑鐨勬槸Gi)
SWA(config-if)#switchport access vlan 2
SWA(config-if)#int f0/6
SWA(config-if)#switchport access vlan 2
SWA(config-if)#int f0/7
SWA(config-if)#switchport access vlan 2
SWA(config-if)# end
SWA#sh vlan
SWA#wr(淇濆瓨)
18.鎬濈鍜岀數鑴戞帴娉?/p>
棣栧厛杩欎釜杞欢涓嶈兘杩炴帴鐪熷疄璁惧锛?br />閫夋嫨涓€鍙癙C锛屼竴涓澶囷紙浜ゆ崲鏈猴紝璺敱鍣ㄩ兘琛岋級
杩炴帴PC鍜岃澶囷紝绾跨紗閫夋嫨钃濊壊绾跨紗锛岃嫳鏂囧簲璇ユ槸console---鎺у埗鍙扮殑鎰忔€濄€傝繛鎺ユ槸锛孭C涓婇€夋嫨RS232鎺ュ彛锛岃澶囦笂閫夋嫨CONSOLE鎺ュ彛
杩炴帴濂戒箣鍚庯紝鍙屽嚮PC鍥炬爣锛屾墦寮€涓€涓獥鍙o紝鐐瑰嚮妗岄潰(desktop)锛屽啀閫夋嫨缁堢锛坱erminal)锛岀偣鍑籓K锛屽氨鍙互浜嗭紒
19.鎬濈杩涘叆
Switch>enable
Switch#
20.鎬濈妯″紡
鍛靛懙缁堜簬鎵惧埌涓€涓叧浜巆isco鐨勯棶棰樹簡銆?/p>
鏈嬪弸浣犲ソ锛屾垜灏辩敤鎴戣嚜宸辩殑璇█琛ㄨ揪浜嗗搱锛屾湁鐐归暱鍝堬紝浣嗕竴瀹氬府浣犲鎳傚搱銆傛€濈鐨勮矾鐢卞櫒鐨勭敤鎴风晫闈㈡湁浠ヤ笅鍑犵锛?br />1.鐢ㄦ埛鎵ц妯″紡锛圲ser EXEC Mode锛?br />2.鐗规潈鎵ц妯″紡锛圥rivileged EXEC Mode锛?br />3.鍏ㄥ眬閰嶇疆妯″紡锛圙lobal Configuration Mode锛?br />4.鐩戞帶妯″紡锛圧OM Monitor Mode锛?nbsp; 瀹塩trl + break
5.瀹夎妯″紡锛圫etup Mode锛?nbsp; 鍏堣繘鍏ョ壒鏉冩ā寮?鍦╯etup 灏辫
6.Boot妯″紡锛圧XBoot Mode锛?/p>
甯哥敤鐨勬槸1銆?鍜?銆備笅闈㈡垜灏辨潵姝e紡鍥炵瓟浣犻棶鐨勩€?/p>
璺敱鍣ㄤ竴寮€鏈猴紝杩涘幓鐨勯偅涓晫闈㈡彁绀虹鏄?ldquo;>”锛屾瘮濡傚儚杩欐牱瀛愬搱锛?ldquo;Router>”杩欎釜灏辨槸鐢ㄦ埛鎵ц妯″紡锛屼篃鏄渶浣庣骇鍒殑妯″紡锛屽畠鍙厑璁告湁闄愭暟閲忕殑鍩烘湰鐩戣鍛戒护锛岃妯″紡涓嬩笉鍏佽浠讳綍浼氭敼鍙樿矾鐢卞櫒閰嶇疆鐨勫懡浠ゃ€?/p>
閭f垜浠閰嶇疆璺敱鍣ㄦ椂璇ュ拫寮勫憿锛岃繖鏃跺氨蹇呴』鍏堝緱杩涘叆鍒?ldquo;鐗规潈鎵ц妯″紡”浜嗭紙涔熷氨鏄湪鐢ㄦ埛鎵ц妯″紡涓嬭緭鍏?ldquo;enable”鍛戒护锛夈€傚嚭鐜板儚杩欐牱鐨勬彁绀虹“#”锛屾瘮濡?ldquo;Router#”銆傜浉姣旂敤鎴锋墽琛屾ā寮忥紝瀹冩彁渚涙洿澶氱殑鍛戒护鍜屾潈闄愶紝姣斿debug鍛戒护锛屽拰鏇翠负缁嗚嚧鐨勬祴璇曠瓑銆?/p>
鑷充簬“鍏ㄥ眬閰嶇疆妯″紡”锛屾槸閰嶇疆锛堝叏灞€锛夌郴缁熷拰鐩稿簲鐨勫叿浣撶粏鑺傞厤缃紙姣斿鎺ュ彛ip銆佽矾鐢卞崗璁繖浜涳級鏃惰繘鍏ョ殑鐣岄潰锛屽湪姝ら厤缃殑涓滀笢鏄奖鍝嶅叏灞€鐨勩€傚叏灞€閰嶇疆妯″紡鐨勬彁绀虹鏄繖鏍风殑“(config)#”锛屾瘮濡傛垜杩欓噷涓剧殑渚嬪氨璇ユ槸“Router(config)#”銆?/p>
鑰岃閰嶇疆鍏蜂綋鐨勪笢涓滃氨寰椾粠鍏ㄥ眬閰嶇疆妯″紡涓嬭繘鍏ュ埌鐩稿簲鐨勫瓙閰嶇疆妯″紡涓嬨€傛瘮濡傦細
Router(config-if)# //鍏蜂綋鐨勬帴鍙i厤缃?br />Router(config-line)# //line妯″紡閰嶇疆锛屾瘮濡俢onsole鍜寁ty杩欎簺鍝?br />Router(config-router)# //璺敱鍣ㄦā寮忥紝姣斿閰嶇疆璺敱鍗忚鏃?/p>
鐧惧害鐭ラ亾涓嶈兘鍥炲笘鍔熻兘涓嶅寮哄ぇ锛屼笉鐒舵垜鍙互閲嶆柊鏇存紓浜殑鎺掔増鍜屾爣璁帮紝濂借鏈嬪弸鏇村姞瀹规槗鐞嗚В銆?/p>
绠€鍗曟€荤粨涓嬩綘鐨勯棶棰樺氨鏄紝鐗规潈鎵ц妯″紡涓昏鏄敤鏉ヨ皟璇曠殑锛屽叏灞€閰嶇疆妯″紡鏄敤鏉ラ厤缃殑銆傝€屼笖浠栦滑鐨勫叧绯伙紝瑕佸埌杈惧叏灞€閰嶇疆妯″紡锛屼綘蹇呴』鍏堝緱澶勫湪鐗规潈鎵ц妯″紡鍝堛€?/p>
鑰岀浉搴旂殑鍛戒护瑙佷笅闈㈠搱锛?/p>
Router>
Router>enable //灏嗕粠鐢ㄦ埛鎵ц妯″紡杩涘叆鍒扮壒鏉冩墽琛屾ā寮?br />Password: //濡傛灉瀵圭壒鏉冩墽琛屾ā寮忚缃簡瀵嗙爜鐨勮瘽锛岃繘鍏ユ椂杩樺緱杈撳叆瀵嗙爜鍝?br />Router#
Router#exit //灏嗕粠鐗规潈鎵ц妯″紡閫€鍥炲埌鐢ㄦ埛鎵ц妯″紡
Router>
//涓嬮潰鎴戞紨绀哄浣曚粠鐢ㄦ埛鎵ц妯″紡涓€姝ユ鍒拌揪鍏ㄥ眬閰嶇疆妯″紡鍝堬細
Router>enable
Router#
Router#configure terminal
Router(config)#
21.鎬濈閰嶇疆vlan骞朵繚瀛?/p>
SWA#vlan database
SWA(vlan)#vlan 2
SWA(vlan)#vlan 3
SWA(vlan)#exit
SWA#write
22.鎬濈閰嶇疆杩滅▼鐧诲綍
111(config)# line vty 0 4 杩涘叆铏氭嫙绾跨▼閰嶇疆妯″紡锛屽湪杩欎釜妯″紡閲屽彲瀵?br />telnet鍔熻兘杩涜閰嶇疆
111(config-line)# login
111(config-line)# password XXX 閰嶇疆telnet瀵嗙爜锛岄粯璁ょ殑缃戠粶璁惧telnet鐨勫姛鑳芥槸
鍏抽棴鐨勶紝閰嶄簡瀵嗙爜涔嬪悗浼氳嚜鍔ㄦ墦寮€
111(config)# enable password XXX 閰嶇疆杩涘叆enable妯″紡鐨勫瘑鐮侊紝 鍖哄垎澶у皬鍐?br />111(config)# enable secret XXX 閰嶇疆杩涘叆enable妯″紡鐨勫瘑鐮侊紝鏄姞瀵嗙殑瀵嗙爜锛宻how
run鏄湅涓嶈鐨?br />111(config)# line console 0
111(config-line)# login
111(config-line)# password XXX 閰嶇疆杩涘叆鐢ㄦ埛妯″紡鐨勫瘑鐮?br />111(config-line)# logging synchronous 杈撳叆鍚屾
111(config-line)# exec-timeout 0 0 绂佹鍥犱负涓€娈垫椂闂存病鏈夎緭鍏ヨ€岃烦鍑?br />111#SWA#write淇濆瓨閰嶇疆
23.鎬濈鎵瑰鐞嗙櫥闄?/p>
off
echo set sh=WScript.CreateObject("WScript.Shell") >telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "open 浣犵殑缃戠粶璁惧telnet鐧诲綍IP" >>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "{ENTER}" >>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "浣犵殑鐢ㄦ埛鍚峽ENTER}">>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "浣犵殑瀵嗙爜{ENTER}">>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "conf{ENTER}">>telnet_tmp.vbs
start telnet
cscript //nologo telnet_tmp.vbs
del telnet_tmp.vbs
24.鎬濈鍒犻櫎vlan
jjf{cinfig}#no vlan 10 鍒犻櫎vlan10
jjf{cinfig}#end 鍥炲埌鐗规潈妯″紡
jjf{cinfig}sh vlan 鏌ョ湅vlan
SWA#write
25.鎬濈璁剧疆trunk骞茬嚎
璁剧疆骞茬嚎trunk
灏嗚繛鎺ヤ袱涓氦鎹㈡満鐨勭鍙h缃垚trunk銆?br />SWA(config)#int f0/8
SWA(config-if)#switchport mode trunk
SWA(config-if)#switchport trunk allowed vlan 1,2,3(鍙厑璁竩lan 1 2 3 鍦ㄨ繖鏉′釜trunk閾捐矾涓婅蛋锛岃繖涓氨鏄痸lan淇壀銆?
SWA(config-if)#switchport trunk encap dot1q(鍙互涓嶈dot1q鏄痸lan涓户鍗忚(802.1q)涓€鑸氦鎹㈡満閮芥槸鑷甫鐨?
SWA(config-if)#end
SWA#sh run
SWB(config)#int f0/1
SWB(config-if)#switchport mode trunk
SWB(config-if)#switchport trunk allowed vlan 1,2,3
SWB(config-if)#switchport trunk encap dot1q
SWB(config-if)#end
SWB#sh run
26.鎬濈鍨嬪彿
Cisco Catalyst 2960G-24TC-L 24涓互澶綉10/100/1000绔彛锛屽叾涓湁4涓负涓ょ敤绔彛
26.鎬濈杩滅▼鐧婚檰pingIP鍦板潃锛堝彲鍋氭壒澶勭悊锛?/p>
off
echo set sh=WScript.CreateObject("WScript.Shell") >telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "open 鐧婚檰浜ゆ崲鏈篒P鍦板潃" >>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "{ENTER}" >>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "鐢ㄦ埛鍚峽ENTER}">>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "鐧诲綍瀵嗙爜{ENTER}">>telnet_tmp.vbs
echo sh.SendKeys "ping 192.168.0.2{ENTER}" >>telnet_tmp.vbs
start telnet
cscript //nologo telnet_tmp.vbs
echo del telnet_tmp.vbs
27.鎬濈杩滅▼浜ゆ崲鏈虹櫥闄嗛厤缃?/p>
1.杩涘叆vlan 1鎺ュ彛妯″紡
switch(config)#interface vlan 1
2.鎵撳紑vlan 1绔彛
switch(config-if)#no shutdown
3.閰嶇疆vlan 1鐨処P鍦板潃
switch(config-if)#ip address 172.16.10.99 255.255.255.0
涓夈€侀厤缃氦鎹㈡満Telnet鐧诲綍
1.鍦ㄥ叏灞€閰嶇疆妯″紡涓嬭缃壒鏉冩ā寮忓彛浠?br />switch(config)#enable password cisco
2.鍦ㄥ叏灞€閰嶇疆妯″紡涓嬭缃櫄鎷熺粓绔?Virtual terminal)鐨勭嚎璺彿
switch(config)#line vty 0 4
switch(config-line)#
3.鍦ㄧ嚎璺厤缃ā寮忎笅璁剧疆閫氳繃铏氭嫙缁堢鐧诲綍鐨勭敤鎴峰彛浠や负net锛堝繀椤昏缃彛浠ゆ墠鑳戒娇鐢ㄧ鐞咺P杩滅▼鐧诲綍浜ゆ崲鏈猴級
switch(config-line)#password net
4.鍦ㄧ嚎璺厤缃ā寮忎笅浣跨敤login鍛戒护娴嬭瘯鏄惁鍙互杩滅▼鐧诲綍
switch(config-line)#login
switch(config-line)#
濡傛灉娌℃湁鍑虹幇鎻愮ず锛岃鏄庤缃垚鍔燂紝濡傛灉鍑虹幇浜旇鎻愮ず锛岃鏄庤缃湁璇€?br />鍥涖€佷娇鐢≒C1鏈鸿繙绋嬬櫥褰曚氦鎹㈡満
1.灏哖C1鐢ㄧ洿閫氱嚎杩炴帴鍒颁氦鎹㈡満鐨凢astEthernet0/3绔彛銆?br />2.鎵撳紑PC1鐨?ldquo;妗岄潰”涓婄殑“IP閰嶇疆”锛岄€夋嫨闈欐€侀厤缃紝璁剧疆IP鍦板潃涓?72.16.10.100锛屽瓙缃戞帺鐮佷负255.255.255.0銆?br />3.鎵撳紑PC1鐨?ldquo;妗岄潰”涓婄殑“鍛戒护鎻愮ず绗?rdquo;銆?br />4. 鍦ㄥ懡浠ゆ彁绀虹涓娇鐢╰elnet鍛戒护杩滅▼鐧诲綍浜ゆ崲鏈?浜ゆ崲鏈虹鐞咺P鍦板潃涓?72.16.10.99)
PC>telnet 172.16.10.99
Trying 172.16.10.99 ...
User Access Verification
Password:
鍦ㄦ帴涓嬫潵鍑虹幇鐨刾assword鎻愮ず鏂囧瓧鍚庤緭鍏ュ墠闈氦鎹㈡満涓婅瀹氱殑telnet鐧诲綍鍙d护net锛堣鍙d护杈撳叆鏃朵笉浼氭樉绀轰换浣曠鍙凤級,鍗冲彲杩涘叆浜ゆ崲鏈虹殑鐢ㄦ埛閰嶇疆妯″紡銆?br />5.杈撳叆鐗规潈妯″紡鍙d护杩涘叆鍏ㄥ眬閰嶇疆妯″紡
鍦ㄧ敤鎴烽厤缃ā寮忎笅杈撳叆enable鍛戒护锛屽啀鍚庤緭鍏ユ墍閰嶇疆鐨勭壒鏉冩ā寮忓彛浠isco锛堣鍙d护杈撳叆鏃朵笉浼氭樉绀轰换浣曠鍙凤級鍗冲彲杩涘叆鍏ㄥ眬閰嶇疆妯″紡杩涜鍚庣画缃戠粶璁剧疆銆?br />Switch>enable
Password:
28. 鎬濈閲嶅惎
鎬濈鎵€鏈夌殑閲嶅惎鍛戒护閮芥槸reload
29. 杩滅▼鐧诲綍浜ゆ崲鏈哄彲鍋氭壒澶勭悊
off
echo set sh=WScript.CreateObject("WScript.Shell") >telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "open 192.168.6.100" >>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "{enter}" >>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "root{ENTER}">>telnet_tmp.vbs
echo WScript.Sleep 300 >>telnet_tmp.vbs
echo sh.SendKeys "jjf1{ENTER}">>telnet_tmp.vbs
start telnet
cscript //nologo telnet_tmp.vbs
echo del telnet_tmp.vbs
Translating "enb"...domain server (255.255.255.255) 蹇嵎閿?nbsp;
ctrl shift + 6 no ip domain
以上是关于Cisco 浜ゆ崲鏈洪厤缃殑鍩烘湰鍛戒护的主要内容,如果未能解决你的问题,请参考以下文章