全新的cisco配置命令
配置使能密碼enable secret ciscolab 以cicsolab 為例
switch> enable
switch#c onfigure terminal
switch(conf)#hostname aptch2950
aptech2950(conf)# enable secret ciscolab
設定虛擬區域網vlan 1 inte***ce vlan 1
switch> enable
switch#c onfigure terminal
switch(conf)#hostname aptch2950
aptech2950(conf)# inte***ce vlan 1
aptech2950(conf-if)#ip address 192.168.1.1 255.255.255.0 配置交換機埠ip 和子網掩
碼aptech2950(conf-if)#no shut 是配置處於執行中
aptech2950(conf-if)#exit
aptech2950(conf)#ip default-gateway 192.168.254 設定閘道器位址
進入交換機某一埠inte***ce fasteher*** 0/17 以17 埠為例
switch> enable
switch#c onfigure terminal
switch(conf)#hostname aptch2950
aptech2950(conf)# inte***ce fasteher*** 0/17
aptech2950(conf-if)#
8:檢視命令show
switch> enable
switch# show version 察看系統中的所有版本資訊
show inte***ce vlan 1 檢視交換機有關ip 協議的配置資訊
show running-configure 檢視交換機當前起作用的配置資訊
show inte***ce fastether*** 0/1 察看交換機1 介面具體配置和統計資訊
show mac-address-table 檢視mac 位址表
show mac-address-table aging-time 檢視mac 位址表自動老化時間
9:交換機恢復出廠預設恢復命令
switch> enable
switch# erase startup-configure
switch# reload
10:雙工模式設定
switch> enable
switch#c onfigure terminal
switch2950(conf)#hostname aptch-2950
aptech2950(conf)# inte***ce fasteher*** 0/17 以17 埠為例
aptech2950(conf-if)#duplex full/half/auto 有full , half, auto 三個可選
項11:cdp 相關命令
switch> enable
switch# show cdp 檢視裝置的cdp 全域性配置資訊
show cdp inte***ce fastether*** 0/17 檢視17 埠的cdp 配置資訊
show cdp traffic 檢視有關cdp 包的統計資訊
show cdp nerghbors 列出與裝置相連的cisco 裝置
12:csico2950 的密碼恢復
拔下交換機電源線。
用手按著交換機的mode 鍵,插上電源線
在switch:後執行flash_ini 命令:switch: flash_ini
檢視flash 中的檔案: switch: dir flash:
把「config.text」檔案改名為「config.old」:
switch: rename flash: config.
text flash: config.old
執行boot: switch: boot
交換機進入是否進入配置的對話,執行no :
進入特權模式察看flash 裡的檔案: show flash :
把「config.old」檔案改名為「config.text」:
switch: rename flash: config.
old flash: config.text
把「 config.text 」 拷入系統的「 running-configure 」: copy flash: config.text system :
running-configure
把配置模式重新設定密碼存檔,密碼恢復成功。
13:交換機tel*** 遠端登入設定:
switch>en
switch#c onfigure terminal
switch(conf)#hostname aptech-2950
aptech2950(conf)#enable password cisco 以cisco 為特權模式密碼
aptech2950(conf)#inte***ce fastether*** 0/1 以17 埠為tel*** 遠端登入埠
aptech2950(conf-if)#ip address 192.168.1.1 255.255.255.0
aptech2950(conf-if)#no shut
aptech2950(conf-if)#exit
aptech2950(conf)line vty 0 4 設定0-4 個使用者可以tel*** 遠端登陸
aptech2950(conf-line)#login
aptech2950(conf-line)#password edge 以edge 為遠端登入的使用者密碼
主機設定:
ip 192.168.1.2 主機的ip 必須和交換機埠的位址在同一網路
段***mask 255.255.255.0
gate-way 192.168.1.1 閘道器位址是交換機埠位址
執行:tel*** 192.168.1.1
進入tel*** 遠端登入介面
password : edge
aptech2950>en
password: cisco
aptech#
14:交換機配置的重新載入和儲存
設定完成交換機的配置後:
aptech2950(conf)#reload
是否儲存(y/n) y: 儲存設定資訊n:不儲存設定資訊
1.在基於ios 的交換機上設定主機名/系統名:
switch(config)# hostname hostname
在基於cli 的交換機上設定主機名/系統名:
switch(enable) set system name name-string
2.在基於ios 的交換機上設定登入口令:
switch(config)# enable password level 1 password
在基於cli 的交換機上設定登入口令:
switch(enable) set password
switch(enable) set enalbepass
3.在基於ios 的交換機上設定遠端訪問:
switch(config)# inte***ce vlan 1
switch(config-if)# ip address ip-address ***mask
switch(config-if)# ip default-gateway ip-address
在基於cli 的交換機上設定遠端訪問:
switch(enable) set inte***ce sc0 ip-address ***mask broadcast-address
switch(enable) set inte***ce sc0 vlan
switch(enable) set ip route default gateway
4.在基於ios 的交換機上啟用和瀏覽cdp 資訊:
switch(config-if)# cdp enable
switch(config-if)# no cdp enable
為了檢視cisco 鄰接裝置的cdp 通告資訊:
switch# show cdp inte***ce [type modle/port]
switch# show cdp neighbors [type module/port] [detail]
在基於cli 的交換機上啟用和瀏覽cdp 資訊:
switch(enable) set cdp module/port
為了檢視cisco 鄰接裝置的cdp 通告資訊:
switch(enable) show cdp neighbors[module/port] [vlan|duplex|capabilities|detail]
5.基於ios 的交換機的埠描述:
switch(config-if)# description description-string
基於cli 的交換機的埠描述:
switch(enable)set port name module/number description-string
6.在基於ios 的交換機上設定埠速度:
switch(config-if)# speed
在基於cli 的交換機上設定埠速度:
switch(enable) set port speed moudle/number
switch(enable) set port speed moudle/number
7.在基於ios 的交換機上設定乙太網的鏈路模式:
switch(config-if)# duplex
在基於cli 的交換機上設定乙太網的鏈路模式:
switch(enable) set port duplex module/number
8.在基於ios 的交換機上配置靜態vlan:
switch# vlan database
switch(vlan)# vlan vlan-num name vla
switch(vlan)# exit
CISCO交換機配置命令大全
1.在基於ios的交換機上設定主機名 系統名 switch config hostname hostname 在基於cli的交換機上設定主機名 系統名 switch enable set system name name string 2.在基於ios的交換機上設定登入口令 switch confi...
Cisco交換機常用配置命令總結
1 配置vlan 理解vlan 乙個vlan就是乙個交換網,其邏輯上按功能 專案 應用來分而不必考慮 使用者的物理位置。任何交換口都可以屬於某一vlan,ip包 廣播包及組播包均可以傳送或廣播給在此vlan內的終端使用者。每乙個vlan均可看成是乙個邏輯網路,發往另一vlan 的資料報必須由路由器或...
華為交換機配置命令大全
第1章產品介紹 1.1 產品簡介 隨著internet 網際網路 的高速發展,人們對通訊的需求已逐漸從傳統的 傳真 電報等低速業務向高速的internet接入 可視 點播等寬頻業務領域延伸,使用者對上網速率的需求也越來越高。在這種需求條件下,乙太網接入因其成本低 速度高 使用簡單而倍受市場的關注。面...