cisco查看機框 板卡 電源 SN 風扇環境運行狀態和一些常用命令 巡檢命令


查看設備運行環境及狀態

show environment 查看設備環境
show environment temperature --查設備溫度

show environment fans --查看設備風扇
show cpu usage 查看CPU利用率
show memory 查看內存
show perfmon 查看性能
show logging --查日志
show version
show processes cpu-usage --查CPU詳細進程

show processes memory --查內存詳細進程

 

show route --查路由表
show failover 查備援助線路
show nameif 查看接口
show int ip brief 查看接口狀態
show vlan --查看vlan信息

 

 

 

 

 

 

1、 清除NAT緩存:clear ip nat translation *

2、清除交換機上的所有配置:erase nvram/wrie erase------>reload(重啟) 
3、設置路由器telnet管理:en----->conf  t------>line vty 0 4------>login------>password  cisco

4設置交換機telnet管理:en----->conf  t------>interface vlan 1------>no shut------>ip  address  192.168.0.253------->enable  password  cisco   

      如果想管理其他網段的交換機需設置網關:ien----->conf  t------>p default-gateway 192.168.0.254 ------->telnet  192.168.1.253 
5查看硬件信息:show idb all       show  version      

      75系列查看機框序列號:show  diag          

       查看板卡序列號:show rsp chassis-info

      7513查看板卡序列號:show diagbus

      6509:show  module (后可加參數)   

  show  idprom (后可參數,可查如風扇、電源等序列號等)

6、使日志同步(可取消輸入命令時系統自動生成的日志):logging  synchronous  

7、超時設置:A、登陸超時(輸入用戶名和密碼時):timeout  login  response  20(20秒)

                    B、登陸后無操作超時:exec-timeout  0  0(為永不超時)

8、配置SSH:

Router(config)#ip  http  server

Router(config)#ip  http  secure-server

Router(config)#ip  http  authentication  local

Router(config)#username  cisco  privilege  15  password  0  cisco

Router(config)#line  console  0

Router(config-line)#login  local

Router(config-line)#exit

Router(config)#line  vty  0  4

Router(config-line)#privilege  level  15

Router(config-line)#login  local

Router(config-line)#transport  input  telnet

Router(config-line)#transport  input  telnet  ssh

Router(config-line)#^Z

Router#conf t

Router(config)#int  f0/0

Router(config-if)#ip  address  1.1.1.1  255.255.255.0

Router(config-if)#no  shut

Router(config-if)#do  ping  1.1.1.2

!!!!!

---------------------------------------------------------------------------------------------------

打開WEB,輸入https://1.1.1.1 進行連接測試

9、配置無線:

Router(config)#int  dotl1radio  0

Router(config-if)# ip  address  10.1.12.1  255.255.255.0

Router(config-if)#no  shut

Router(config-if)#ssid  WIRELESS

Router(config-if-ssid)#guest-mode

Router(config-if-ssid)#authentication  open

Router(config-if-ssid)#infrastructure-ssid

Router(config-if-ssid)#exit

Router(config-if)#line  con  0

Router(config-line)#password  console

Router(config-line)#logging  sync

Router(config-line)#exec-timeout  0  0

Router(config-line)#exit

.........

10、配置DHCP:

Router(config)#ip  dhcp  pool  R3WLAN

Router(dhcp-config)#network  10.11.2.0  255.255.255.0

Router(dhcp-config)#default-router  10.1.12.1

Router(dhcp-config)#exit

Router(config)#ip  dhcp  excluded-address  10.1.12.1

 11、清除ASA5510的配置:write erase/重新加載:reload

 12、

思科IOS基本配置

R(config)#hostname wildlee——設置思科IOS系統名稱

R(config)#no ip domain lookup——關閉域名解析功能

Wildlee(config)#line console 0—-指定控制線路

Wildlee(config)#line vty 0 15—–指定虛擬終端訪問線路

Wildlee(config-line)#exec-timeout 5 0—–指定線路超時時間5分0秒

Wildlee(config-line)#password wildlee—–指定console線路的訪問密碼為wildlee

Wildlee(config)#enable secret wildlee——設置特權訪問密碼為wildlee

Wildlee(config)#service password-encryption——加密明文密碼

Wildlee(config)#banner motd $this is text$——歡迎廣告詞

 

VLAN配置命令

1.創建vlan

Wildlee(config)#vlan {vlan id}——–給vlan設置ID

Wildlee(config-vlan)#name {vlan name}———給vlan取名

2.配置中繼端口

wildlee(config-if)#switchport trunk encapsulation dot1q———-定義中繼端口封裝模式

wildlee(config-if)#switchport mode trunk ————-配置端口為中繼端口

3.划分端口

wildlee(config)#interface {interface}——-指定要加入vlan的接口

wildlee(config)#interface  range {interface},{interface}——-將多個不連續端口划分到vlan

wildlee(config)#interface  range {interface 0/1 – 20}———將多個連續的端口划分到vlan

wildlee(config-if)#speed {10|100|1000}——指定接口速率

wildlee(config-if)#duplex {auto|half|full}——-指定雙工模式

wildlee(config-if)#switchport mode access————將指定接口定義為訪問端口

wildlee(config-if)#switchport access vlan id———–將指定端口分配到特定vlan

wildlee#show mac-address-table ——-查看接口MAC地址列表

wildlee#show mac-address-table aging-time ———-查看交換機MAC地址學習老化時間

wildlee(config)#mac-address-table aging-time  time[s]———修改此時間值

4.給vlan配置IP

wildlee(config)#interface vlan {vlan id}———指定VLAN號

wildlee(config-vlan)#ip address {ip address與 netmask}—–給vlan配置IP地址用於vlan間路由

5.查看配置

wildlee#show interface fastEthernet {interface}———查看指定接口

wildlee#show interface fastEthernet {interface} switchport——-查看交換機端口狀態及封裝模式

wildlee#show ip interface brief———查看接口摘要信息

wildlee#show vlan-switchport——-查看vlan接口配置情況

 

VTP配置命令

Wildlee(config)#vtp domain {vtp name}———配置vtp域名

Wildlee(config)#vtp mode {server|client|transparent}——–配置配置vtp工作模式

Wildlee(config)#vtp password {vtp password}——-給vtp設置密碼

Wildlee(config)#vtp pruning ——-啟用vtp修剪

Wildlee#show vtp status——查看vtp配置情況

Wildlee#show vtp counters——-顯示vtp消息發送與接收情況

 

典型VTP與VLAN配置過程

a.設置VTP DOMAIN(核心、分支交換機上都設置)

b.配置中繼(核心、分支交換機上都設置)

c.創建VLAN(在server上設置)

d.將交換機端口划入VLAN

e.配置三層交換


STP生成樹協議

wildlee(config)#spanning-tree vlan {vlan id}——-開啟生成樹協議

wildlee(config)#spanning-tree vlan {vlan id} root primary——-設置為根交換機

wildlee(config)#spanning-tree vlan {vlan id} priority {bridge priority}——-設置交換機ID優先級值

wildlee(config-if)#spanning-tree vlan {vlan id} cost {cost}———設置交換機端口成本值

wildlee(config-if)#spanning-tree vlan {vlan id} port-priority {priority}———設置端口優先級

wildlee#show spanning-tree——-查看生成樹信息

 
設定交換機MAC地址老化時間  
switch(config)#mac-address-table aging-time <10-1000000>--------默認是300秒

設定交換機端口/MAC綁定
switch(config)#mac-address-table static 0100.5e00.0005 vlan 1 interface f0/1

 

13、ip unnumbered Loopback0  借用端口IP地址命令

“借用IP地址”實際就是:一個接口上沒有配置IP地址,但是還想使用該接口。就向其它有IP地
址的接口借一個IP地址來。如果被借用接口有多個IP地址,只能借來主IP地址。如果被借用接口沒有
IP地址,則借用接口的IP地址為0.0.0.0。該功能通過Ip unnumbered命令來實現。


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM