Cisco Basic Commands
1 switch#show running-config View the current running configuration
2 switch#show startup-config View saved configuration information
3 switch#cwrite save the current configuration information
4 switch#erase nvran delete saved configuration information
5 Command line card can be pressed ctrl+shift+6
6 reload reset
Configure console password
Router>enable 进入特权模式
Router#configure terminal 进入全局配置模式
Router(config)#line console 0 进入控制台接口
Router(config-line)#login 登录
Router(config-line)#password 1234 设置密码为1234
Set password to enter privileged mode
Router>enable
Router#configure terminal
Router(config)#enable password adc set clear text password (visible)
Router(config)#enable secret adc123 Set ciphertext password (invisible)
R1(config)#no enable password delete password
R1(config)#no enable secret
router password recovery
Principle: The router finds the operating system from the flash and loads it into the memory; then finds the router configuration from the nvram and loads it into the memory. If the second step is skipped and the router does not read nvram, then you can enter privileged mode without knowing the router password. After entering the privileged mode, load the nvram information, so that the router configuration can be loaded. Finally, change the router password
The default value of the router configuration register is 0x2102 (0x indicates that the following number is a hexadecimal number)
Operation process
When the router starts up (when the # sign appears on the screen), press ctrl+break(pause)
Router>enable
Router#copy start run
Router#config terminal
Router(config)#enable secret 1234
Router(config)#config-register ox2102
Router(config)#end
Router#write
Router#reload
Switch Password Recovery
1. Principle: When the switch is saved, the stored file name is config.text. When the switch starts up, it looks for config.text and loads the user configuration.
2. When recovering the password, just rename config.text, such as config.text.old. After the switch starts, change the file name back.
3. Detailed steps
(1) The switch does not have a power switch. After unplugging the power cord, press and hold the MODE button and then plug in the power until the switch appears on the screen and let go.
(2) Initialize
switch: flash_init
(3) Change the file name
switch: rename flash:config.text flash:config.text.old
(4) Start the switch
switch: boot After booting, the configuration config.text will be read, but it cannot be found (5) After entering the
privileged mode, change the file name back to
switch# rename flash:config.text.old flash:config.text
(6) Load the contents of the save disk into the memory
switch# copy flash:config.text system:running -config
(7) save the file after changing the password