Cisco Command Summary
Cisco Router Configuration Commands - Lists how to enable and disable interfaces, add
IP addresses to interfaces, enable RIP or IGRP and set passwords.
Cisco Router Show Commands - Handy show commands to check on the status of
interfaces.
Cisco Router Basic Operations - Covers getting into and out of different modes. Also,
some handy shortcut keys are included.
Cisco Router Copy Commands - How to save and backup your router configuration and
IOS file.
Cisco Router Debug Commands - Some useful debug commands.
Cisco Router Configuration Commands
Requirement Cisco Command
Set a console password to cisco Router(config)#line con 0
Router(config-line)#login
Router(config-line)#password cisco
Set a telnet password Router(config)#line vty 0 4
Router(config-line)#login
Router(config-line)#password cisco
Stop console timing out Router(config)#line con 0
Router(config-line)#exec-timeout 0 0
Set the enable password to cisco Router(config)#enable password cisco
Set the enable secret password to peter. Router(config)#enable secret peter
This password overrides the enable password and is encypted
within the config file
Enable an interface Router(config-if)#no shutdown
To disable an interface Router(config-if)#shutdown
Set the clock rate for a router with a DCE cable to 64K Router(config-if)clock rate 64000
Set a logical bandwidth assignment of 64K to the serial interface Router(config-if)bandwidth 64
Note that the zeroes are not missing
To add an IP address to a interface Router(config-if)#ip addr 10.1.1.1
255.255.255.0
To enable RIP on all 172.16.x.y interfaces Router(config)#router rip
Router(config-router)#network
172.16.0.0
Disable RIP Router(config)#no router rip
To enable IRGP with a AS of 200, to all interfaces Router(config)#router igrp 200
Router(config-router)#network
172.16.0.0
Disable IGRP Router(config)#no router igrp 200
Static route the remote network is 172.16.1.0, with a mask of Router(config)#ip route 172.16.1.0
255.255.255.0, the next hop is 172.16.2.1, at a cost of 5 hops 255.255.255.0 172.16.2.1 5
Disable CDP for the whole router Router(config)#no cdp run
Enable CDP for he whole router Router(config)#cdp run
Disable CDP on an interface Router(config-if)#no cdp enable
Cisco Router Show Commands
Requirement Cisco Command
View version information show version
View current configuration (DRAM) show running-config
View startup configuration (NVRAM) show startup-config
Show IOS file and flash space show flash
Shows all logs that the router has in its memory show log
View the interface status of interface e0 show interface e0
Overview all interfaces on the router show ip interfaces brief
View type of serial cable on s0 show controllers 0 (note the space between the 's'
and the '0')
Display a summary of connected cdp devices show cdp neighbor
Display detailed information on all devices show cdp entry *
Display current routing protocols show ip protocols
Display IP routing table show ip route
Display access lists, this includes the number of show access-lists
displayed matches
Check the router can see the ISDN switch show isdn status
Check a Frame Relay PVC connections show frame-relay pvc
show lmi traffic stats show frame-relay lmi
Display the frame inverse ARP table show frame-relay map
Cisco Router Basic Operations
Requirement Cisco Command
Enable Enter privileged mode
Return to user mode from privileged disable
Exit Router Logout or exit or quit
Recall last command up arrow or <Ctrl-P>
Recall next command down arrow or <Ctrl-N>
Suspend or abort <Shift> and <Ctrl> and 6 then x
Refresh screen output <Ctrl-R>
Compleat Command TAB
Cisco Router Copy Commands
Requirement Cisco Command
Save the current configuration from DRAM to copy running-config startup-config
NVRAM
Merge NVRAM configuration to DRAM copy startup-config running-config
Copy DRAM configuration to a TFTP server copy runing-config tftp
Merge TFTP configuration with current router copy tftp runing-config
configuration held in DRAM
Backup the IOS onto a TFTP server copy flash tftp
Upgrade the router IOS from a TFTP server copy tftp flash
Cisco Router Debug Commands
Requirement Cisco Command
Enable debug for RIP debug ip rip
Enable summary IGRP debug information debug ip igrp events
Enable detailed IGRP debug information debug ip igrp transactions
Debug IPX RIP debug ipx routing activity
Debug IPX SAP debug IPX SAP
Enable debug for CHAP or PAP debug ppp authentication
Switch all debugging off no debug all
undebug all
Cisco Pix Firewall
Download most current software from WEB. If using a DOS/Windows PC choose the
executable file (pixnnn.exe). This file has the rawrite.exe program compressed into it. The
rawrite program creates a bootable floppy disk that has the latest firewall software installed.
Follow the readme.txt file instructions that you get once you run the pixnnn.exe.
Get a console session established to the PIX firewall.
Configure Network Routers
Set default routes
Set access lists
Set any filters
Configure the PIX Firewall
pixfirewall> enalble
Password:
pixfirewall# configure t - Enter configuration mode.
Identify each interface - you are forced to use the name outside for the outside interface to
attain maximum security.
pixfirewall(config)# nameif ethernet0 outside security0
pixfirewall(config)# nameif ethernet1 inside security100
Assign each interface an ip address.
pixfirewall(config)# ip address inside 192.168.100.1 255.255.255.0
pixfirewall(config)# ip address outside 200.100.100.50 255.255.255.0
Specify network card speed and duplex. Auto uses automatic detection. The AUTO option
exists only for ethernet.
pixfirewall(config)# interface ethernet0 auto
pixfirewall(config)# interface ethernet1 auto
This is a good place to save our work.
pixfirewall(config)# exit --- Exit config mode.
pixfirewall # wr mem --- Save our work.
Show a little of what we have done.
pixfirewall# sh nameif
nameif ethernet0 outside security0
nameif ethernet1 inside security100
Continue with the configuration
pixfirewall# config t ---- Enter configuration mode
Enable Network Address Translation for the outside interface
pixfirewall(config)# nat (inside) 1 0 0
The number 1 is the local NAT ID (between 0 and 2 billion).
The 0 0 is the internal IP address and subnet mask to be translated 0 stands for all
Specify NAT and PAT parameters.
pixfirewall(config)# global (outside) 1 200.100.100.100 netmask
255.255.255.0
The number 1 is the Local NAT ID (see above nat statement)
The address and subnet mask is the address to be used for port address translation.
PAT will not work with multimedia applications and does not work with H.323
application and caching nameservers.
pixfirewall(config)# global (outside) 1 200.100.100.110-200.100.100.150
netmask 255.255.255.0
The number 1 is the Local NAT id (see nat statement)
The network address range and mask are used for network address translation. NAT
gives a limited number of addresses. There has to be a one for one address translation
for NAT to work properly.
Create a default route to the outside router
pixfirewall(config)# route outside 0 0 200.100.100.1 1
The 0 0 stands for all ip addresses.
The ip address is the address of the router to the ISP
The 1 tells how many hops away the router is from the firewall.
Permit ICMP traffic through the firewall
pixfirewall(config)# conduit permit icmp any any
check with your security policy
Set a host name for the firewall. This also sets the prompt.
pixfirewall(config)# hostname wally
Set the enable passwork for the firewall.
pixfirewall(config)# enable password snnug
Exit configuration mode and save our work
pixfirewall(config)# exit - Exit
pixfirewall# wr mem - Save
Building configuration...
Cryptochecksum: 975d086a f1df1506 86647656 021580bc
[OK]
Check out the configuration
pixfirewall# sh ip address
System IP Addresses:
ip address outside 200.100.100.50 255.255.255.0
ip address inside 192.168.100.50 255.255.255.0
Current IP Addresses:
ip address outside 200.100.100.50 255.255.255.0
ip address inside 192.168.100.50 255.255.255.0
pixfirewall# sh global
global (outside) 1 200.100.100.100 netmask 255.255.255.0
global (outside) 1 200.100.100.110-200.100.100.150 netmask 255.255.255.0
pixfirewall# sh nat
nat (inside) 1 0.0.0.0 0.0.0.0 0 0
pixfirewall# sh route
outside 0.0.0.0 0.0.0.0 200.100.100.1 1 OTHER static
pixfirewall# write t
Cisco Loopback Tests
Loopback Modes
BERT Tests
Loopback Modes
There are three main loopback modes as follows: local, network (both line and payload), and
remote (line and payload). Specify the loopback format using the loopback [local | network |
remote] command.
Examples of specific loopback modes follow:
Set the first T1 into local loopback as follows:
Router# config t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)# interface serial 3/0:1
Router(config-if)# loopback local
In the preceding example, local loopback loops the router output data back toward the
router at the T1 framer and sends an AIS signal out toward the network.
Set the first T1 into network line loopback as follows:
Router# config t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)# interface serial 3/0:1
Router(config-if)# loopback network line
In the preceding example, network line loopback loops the data back toward the
network (before the T1 framer).
Set the first T1 into network payload loopback as follows:
Router# config t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)# interface serial 3/0:1
Router(config-if)# loopback network payload
In the preceding example, network payload loopback loops just the payload data back
toward the network at the T1 framer.
The syntax of the loopback remote command follows:
loopback [remote {line {fdl ansi | inband} | payload fdl ansi}]
Set the first T1 into remote line inband loopback, as follows:
Router# config t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)# int serial 3/0:1
Router(config-if)# loop remote line inband
In the preceding example, remote line inband loopback sends a repeating 5-bit inband
pattern (of 00001) to the remote end requesting that it enter into a network line
loopback.
Set the first T1 into remote line FDL ANSI bit loopback, as follows:
Router# config t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)# int serial 3/0:1
Router(config-if)# loop remote line fdl ansi
In the preceding example, remote line FDL ANSI bit loopback sends a repeating 16-bit
ESF data link code word (of 00001110 11111111) to the remote end requesting that it
enter into a network line loopback.
Set the first T1 into remote payload FDL ANSI bit loopback, as follows:
Router# config t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)# int serial 3/0:1
Router(config-if)# loop remote payload fdl ansi
In the preceding example, remote payload ANSI bit loopback sends a repeating 16-bit
ESF data link code word (of 00010100 11111111) to the remote end requesting that it
enter into a network payload loopback.
Checking Bit Errors Using a BERT
To check bit errors using a bit error test (BERT), use the following command:
[no] t1 t1 channel bert pattern {2^15 | 2^20 | 2^23 | 0s |
1s} interval minutes
where t1 channel is 1-28, 2^15 is an exponential number that represents a pseudo-random
repeating pattern that is 32767 bits long, 2^20 is a pseudo-random repeating pattern that is
1048575 bits long, 2^23 is a pseudo-random repeating pattern that is 8388607 bits long, 0s
is a pattern of all zeroes (00000000...), 1s is a pattern of all 1s (111111...), and minutes are
1-14400, which designate the time the BERT will run. To stop the BERT, use the optional no
form of the command. Following is an example of this command, where the pseudo-random
pattern 2^20 is sent and repeats on the first T1 channel for 60 minutes:
Router# t1 1 bert pattern 2^20 interval 60
Note that the BERT command is not saved in NVRAM. The test patterns from the PA-CT3/4T1
port adapter are framed test patterns; therefore, they are inserted into the payload of a
framed T1 signal.
To display the BERT results, use the following EXEC commands: sh cont t3 number or sh cont
t3 number brief. Following are examples of displaying BERT results output:
1. Display BERT output results during a test, as follows:
2. Router# sh cont t3 5/0 b
3. T3 5/0 is up.
4. CT3 H/W Version : 4, CT3 ROM Version : 0.116, CT3 F/W Version :
20.2.0
5. Mx H/W version : 2, Mx ucode ver : 1.25
6. Applique type is Channelized T3
7. No alarms detected.
8. FEAC code received : No code is being received
9. Framing is M23, Line Code is B3ZS, Clock Source is Internal.
10. T1 1 is down, speed: 1536 kbs, non-inverted data
11. timeslots: 1-24
12. FDL per ANSI T1.403 and AT&T 54016 spec.
13. Configured for FDL Remotely Line Looped
14. No alarms detected.
15. Framing is ESF, Line Code is B8ZS, Clock Source is Internal.
16. BERT test result (running)
17. Test Pattern : All 0's, Status : Sync, Sync Detected : 1
18. Interval : 4 minute(s), Time Remain : 4 minute(s)
19. Bit Errors(Sync BERT Started) : 0 bits
20. Bit Errors(Sync last Sync) : 0 bits , Bits Received : 7
Mbits
Note When the T1 is under BERT, its line state is down. When under BERT (in the
running state), the "Total Bit Errors" value is not valid if the "Status" field is "Not
Sync."
21. When the test is done, display BERT results output as follows:
22. Router# sh cont t3 5/0 b
23. T3 5/0 is up.
24. CT3 H/W Version : 4, CT3 ROM Version : 0.116, CT3 F/W
Version : 20.2.0
25. Mx H/W version : 2, Mx ucode ver : 1.25
26. Applique type is Channelized T3
27. No alarms detected.
28. FEAC code received : No code is being received
29. Framing is M23, Line Code is B3ZS, Clock Source is Internal.
30. T1 1 is up, speed: 1536 kbs, non-inverted data
31. timeslots: 1-24
32. FDL per ANSI T1.403 and AT&T 54016 spec.
33. Configured for FDL Remotely Line Looped
34. No alarms detected.
35. Framing is ESF, Line Code is B8ZS, Clock Source is Internal.
36. BERT test result (done)
37. Test Pattern : All 0's, Status : Not Sync, Sync Detected :
1
38. Interval : 4 minute(s), Time Remain : 0 minute(s)
39. Bit Errors(Sync BERT Started) : 0 bits
40. Bit Errors(Sync last Sync) : 0 bits , Bits Received : 368
Mbits
Note The "Status" field is irrelevant when the BERT is done. If the "Sync Detected"
counter is 0, the Bit Errors fields have no meaning.
41. When the test is stopped prematurely, display BERT results output as follows:
42. Router# sh cont t3 5/0 b
43. T3 5/0 is up.
44. CT3 H/W Version : 4, CT3 ROM Version : 0.116, CT3 F/W
Version : 20.2.0
45. Mx H/W version : 2, Mx ucode ver : 1.25
46. Applique type is Channelized T3
47. No alarms detected.
48. FEAC code received : No code is being received
49. Framing is M23, Line Code is B3ZS, Clock Source is Internal.
50. T1 1 is up, speed: 1536 kbs, non-inverted data
51. timeslots: 1-24
52. FDL per ANSI T1.403 and AT&T 54016 spec.
53. Configured for FDL Remotely Line Looped
54. No alarms detected.
55. Framing is ESF, Line Code is B8ZS, Clock Source is Internal.
56. BERT test result (done)
57. Test Pattern : All 0's, Status : Not Sync, Sync Detected :
1
58. Interval : 4 minute(s), Time Remain : 2 minute(s) (unable
to complete)
59. Bit Errors(Sync BERT Started) : 0 bits
60. Bit Errors(Sync last Sync) : 0 bits , Bits Received : 368
Mbits
Note In the preceding three examples, the "Sync Detected" counter indicates the
number of times the pattern sync is detected (from No Sync to Sync), the "Bit
Errors(Sync BERT Started)" counter indicates the number of bit errors during BERT,
and the "Bit Errors(Sync last Sync)" counter shows the number of bit errors since the
last pattern sync is detected.