ios device command

設定設備名稱
(config)#hostname < name>

ex:設定此設備為taiwan
(config)hostname taiwan

新增使用者
(config)#username < username> password < password> [level < value>]

ex:設定使用者raymond的密為cisco
(config)#username raymond password cisco

設定登入訊息
(config)#banner motd #< free type>#
登入設備時會看到的訊息,不論是telnet,console,aux,...等都看得到
也可以打第一個#就按enter
ex:
(config)#banner motd #
Enter TEXT message. End with the character '#'.
haha
#
(config)#

ps:#可換成其他字元,但前後要相同

設定逾時登出
(config-line)#exec-timeout < minute> [sec]

可設定console及telnet超過時間沒輸入指令自動跳出
ps:在指令前加no或exec-timeout 0 0可取消此功能
ex:設定1分10秒後登出
(config-line)#Exec-timeout 1 10

........................... 

設定時間
#clock set < time>

設定時區
(config)#clock timezone < zone >

設定日光節約時間生效與結束
(config)#clock summer-time < parameter > 

設定ntp
(config)#ntp server < ntp ip> [prefer]
在設定多個ntpserver時,會先使用有prefer選項的ntp
ex:10.1.1.2的ntp server優先使用 
(config)#ntp server 10.1.1.1
(config)#ntp server 10.1.1.2 prefer

顯示時間
>show clock

...............................

顯示最後輸入的前10筆命令
>show history

設定歷史緩衝區大小
>terminal history size < num>

列出終端機組態
>show terminal
可確任歷史緩衝區大小
畫面大致如下
Line 0, Location: "", Type: ""
Length: 24lines, Width: 80 columns
Status: PSI Enabled, Ready, Active, Automore On
Capabilities: none
Modem state: Ready
Group codes: 0
Special Chars: Escape Hold Stop Start Disconnect Activation
   ^^x none - - none
Timeouts: Idle EXEC Idle Session Modem Answer Session Dispatch
   00:10:00 never none not set
     Idle Session Disconnect Warning
     never
     Login-sequence User Response
     00:00:30
     Autoselect Intial Wait
     not set
Modem type is unknown
Session limit is not set
Time since activation: 00:01:32
Editing is enabled
History size is enabled, history size is 10
DNS resolution in show commands is enabled
Full user help is disabled
Allowed input transports are none
Allowed output transports are lat pad v120 mop telnet rlogin nasi
Preferred transport is lat
No output characters are padded
No special data dispatching characters

.........................

設定log緩衝
(config)#logging buffered 4096 warnings

設定僅顯示該等級以上的log
(config)#logging console < level>

ex:顯示emergency,alert,critical,error,warning的log 
(config)#logging console warnings

level name如下,第0級最嚴重,第7級最輕微
0 Emergencies 緊急
1 Alerts 警戒
2 Critical 緊要
3 Errors 錯誤
4 Warnings 警告
5 Notifications 通知
6 Informational 資訊
7 Debugging 偵錯 

檢視log緩衝
#show logging history
畫面大致如下
Syslog History Table:1 maximum table entries,
saving level warnings or higher
 4 messages ignored, 0 dropped, 0 recursion drops
 7473 table entries flushed
 SNMP notifications not enabled
  entry number 7474 : CDP-4-NATIVE_VLAN_MISMATCH
   Native VLAN mismatch discovered on GigabitEthernet8/38 (131), with Switch FastEthernet0/8 (1).
   timestamp: 44733696

 

...............................

啟動syslog
(config)#logging on

傳送訊息到syslog伺服器
(config)#logging [hostname|ip address]

設定紀錄嚴重層級
(config)#logging trap [level name]

將時間戳併入訊息中
(config)#service timestamps log datetime

...............................

Cisco IFS(IOS File System)
相關命令如下
#dir //List files on a filesystem
#copy //Copy from one file to another
#more //Display the contents of a file
#show file
#delete //Delete a file
#erase //Erase a filesystem
#format
#cd //Change current directory
#pwd //Display current working directory
#mkdir/rmdir


2008-10-10 00:21:11發表 2013-08-23 15:06:57修改   

數據分析
程式開發
計算機組織與結構
資料結構與演算法
Database and MySql
manage tool
windows
unix-like
linux service
network
network layer3
network layer2
network WAN
network service
作業系統
數位鑑識
資訊安全解決方案
資訊安全威脅
Cisco security
Cisco network

Cisco layer3
Cisco layer2



  登入      [牛的大腦] | [單字我朋友] Powered by systw.net