Sei sulla pagina 1di 13

CCNA Commands

BY SANAM
List of Router Commands
Sl.
Command Comments, if any.
No.
Only standard access list of
access-list <list-num> {permit | deny}
1 the format given is
<source-ip-address>
supported.
access-list <100-199> {permit/deny}
protocol source-addr [source-mask] Global command for
2
[operator operand] destination-addr extended access-lists
[destination-mask] [operator operand]
access-list <list-num> {permit/deny}
3 protocol <source-addr> any operator
operand
access-list <list-num> {permit/deny}
4
protocol <source-addr> any
access-list <list-num> {permit/deny}
5 protocol host <source-addr> <dest-
addr><dest-mask>
access-list <list-num> {permit/deny}
6
protocol any any
access-list <list-num>{permit/deny}
7 protocol any host <dest-addr> operator
operand
access-list <list-num> {permit/deny}
8 protocol host <source-addr> any
operator operand
access-list <list-num> {permit/deny}
9 protocol <source-addr> <source-
wmask> host <dest-addr>
10 banner motd <banner>
Required bandwidth, in
11 bandwidth <kilobits>
kilobits per second.
12 cdp advertise-v2
13 cdp enable
14 cdp run
15 cdp holdtime <seconds>
16 cdp timer <seconds>
17 clear arp-cache
Desired clock rate in bits per
second: 1200, 2400, 4800,
18 clock rate <bps>
9600, 19200, 38400, 56000,
64000 etc.
Hexadecimal or decimal
value that represents the 16-
bit configuration register
value. It is used at the router
19 config-register <value>
start-up. The value range is
from 0x0 to 0xFFFF (0 to
65535 in decimal). Normally,
the default value is 0x2102
20 configure terminal
21 copy running-config startup-config
22 copy startup-config running-config
Character string from 1 to 80
23 description <string>
characters.
Terminates the suspended
24 disconnect telnet session and then logout
it.
Running configuration file is
25 copy running-config tftp:
copied to TFTP server
Copies configuration file
26 copy tftp: running-config from TFTP server to new
router
Copies configuration file
27
copy tftp: startup-config from TFTP server to new
new
router
28 debug ip packet
29 disable
30 disconnect
31 disconnect <TELNET_ID>
Assigns the domain-name to
32 domain-name <domain_name>
the client.
dns-server <IP_address> Allows assigning upto 8 DNS
33
[IP_address_2......IP_address_8] server addresses to the client
Allows assigning upto 8
default-router <IP_address> default-gateway addresses to
34
[IP_address_2......IP_address_8] the client for this range of
addresses.
35 enable
36 enable password <password>
37 enable secret <password>
38 erase startup-config
Command for router in
39 encapsulation dot1q <vlan id>
interface configuration mode
Only PPP/HDLC are
supported at this time by the
40 encapsulation <encapsulation-type>
simulator.
ex: encapsulation hdlc
41 encapsulation framerelay [cisco][ietf]
42 end
43 exec-timeout <minutes> [seconds] seconds is optional.
LMI type is specific to the
44 frame-relay lmi-type <lmi_type>
entire interface,not to a VC.
frame-relay map<protocol-name> <ip- It configures the manual
45
address> <dlci_num> resolution of PVC's.
frame-relay map<protocol-name> <ip-
46
address> <dlci_num> broadcast
frame-relay map<protocol-name> <ip-
47
address> <dlci_num> broadcast cisco
frame-relay map<protocol-name> <ip-
48
address> <dlci_num> broadcast ietf
frame-relay map<protocol-name> <ip-
49
address> <dlci_num> cisco
frame-relay map<protocol-name> <ip-
50
address> <dlci_num> ietf
51 hostname <host-name>
52 interface ethernet 0
53 interface fa <Port-number>
interface fa <Slot-number>/<Port-
54
number>
interface fa <Port-number>.<Subint-
55
number>
interface fa <Slot-number>/<Port-
56
number>.<Subint-number>
Loop back interface numbers
57 interface loopback <port-number>
0 to 9 are supported
58 interface serial 0
Interface sub command to
59 ip access-group <named ACL>
enable named access-list
60 ip access-group <num> in
61 ip access-group <num> out
Global command for Named
62 ip access-list extended <named ACL>
Access-List
ip address <ip-address> <sub-net
63
mask>
64 ip default-network <ip-address>
65 ip domain-lookup
66 ip name-server<ip-address>
ip nat inside source list <ANUM> pool
67
<WORD>
ip nat inside source static <ip-address>
68
<ip-address>
69 ip nat inside
ip nat outside source static <ip-
70
address> <ip-address>
71
ip nat outside
new
ip nat pool <WORD> <ip-address>
72
<ip-address> netmask <ip-address>
ip nat inside source list <num>
73 PAT command
interface <int> overload
The command supported by
the simulator are:
ip route <prefix> <mask> {next-hop- ip route <prefix> <mask>
74
ip-addr | interface-type} <next-hop-ip> and
ip route <prefix> <mask>
serial
75 ip route 0.0.0.0 0.0.0.0 <ip-address>
ip route<ip-address> <ip-address> <ip-
76
address>
ip route <ip-address> <ip-address>
77 Not supported at this time
serial 0
Complete syntax for this
command: ip host name [tcp-
78 ip host <name> <ip-address>
port-number] address1
[address2...address8]
79 ip routing
80 ipx routing
Enables the forwarding of
81 ipv6 unicast-routing ipv6 unicast datagrams
globally on the router.
Configures IPV6 RIP routing
process and enters router
82 ipv6 router rip <word>
configuration mode for the
IPV6 RIP routing process.
Enters router configuration
mode and creates an EIGRP
83 ipv6 router eigrp <as-number> IPV6 routing process. The
"AS" stands for Autonomous
System number.
ipv6 address <ipv6-prefix/prefix- Assigns ipv6 address to an
84
length> interface.
Enables ipv6 processing on
85 ipv6 enable
the interface.
86 ipv6 rip <name> enable Enables specified IPV6 RIP
routing process on an
interface.
Enables EIGRP for IPV6 on
a specified interface. The
87 ipv6 eigrp <as-number>
"AS" stands for Autonomous
System number.
Enables OSPF for IPV6 on a
88 ipv6 ospf <process-id> area <area-id>
specified interface.
89 ip dhcp pool <pool_name> Creates an addressing pool
Command to use DHCP to
90 ip address dhcp
acquire its IP address
91 keepalive <seconds>
92 line aux
93 line console 0
94 line vty
95 logging synchronous
96 login
97 logout
Specifies the duration of the
98 lease <days [hours][min] | infinite>
lease
Used with routing rip, igrp
99 network <ip-address>
etc.
network <ip-address> < ip-address >
100 (For ospf routing)
area <Area-id>
101 no cdp enable
102 no ip address
103 no ip routing
104 no cdp run
no frame map <protocol name> <ip-
105
address> <dlci_num>
no frame map<protocol-name> <ip-
106
address> <dlci_num> broadcast
no frame map<protocol-name> <ip-
107
address> <dlci_num> cisco
no frame map<protocol-name> <ip-
108
address> <dlci_num> ietf
109 no ip domain-lookup
no ip nat pool <WORD><ip-address>
110 Nat pool related command
<ip-address> netmask <mask-addr>
no ip nat inside source list <ANUM>
111
pool <WORD>
no ip nat inside source static <ip-
112
address> <ip-address>
113 no router eigrp
114 no router ospf
115 no router rip
116 no shutdown
Unconfigures any address
117 no ip address dhcp
that was acquired
118 password <password>
119 ping <host-name>
120 ping <ip-address>
121 ping ipv6 <ipv6-address> Used to test the connectivity.
122 reload
123 resume <TELNET_ID>
124 router eigrp <aut_sys>
Process_id is locally
significant and is used to
125 router ospf <proc_id> differentiate different ospf
processes running on a
router.
126 router rip
127 shutdown
128 show access-list
Displays entries in the ARP
129 show arp
table
130 show cdp neighbor
131 show flash
132 show history
Shows the detailed statistics
133 show frame-relay lmi
regarding LMI.
134 show frame-relay map
Shows all the frame relay
135 show frame-relay pvc <dlci_num> PVC's terminated and their
statistics at a specified router
136 show hosts
137 show ip arp
138 show ip eigrp neighbors detail
139 show ip eigrp neighbors
140 show ip eigrp topology
141 show ip eigrp traffic
142 show ip interface brief
143 show ip interface
144 show ip ospf interface
145 show ip nat statistics
146 show ip nat translations
147 show ip ospf database
148 show ip ospf neighbor detail
Displays parameters and
149 show ip protocols current state of the active
routing protocol process.
150 show ip route
151 show interfaces
152 show interfaces ethernet 0
153 show interfaces serial 0
show interfaces loopback Loopback interface number,0
154
<Loopback_num> to 9 are supported
155 show protocols
156 show running-config
157 show sessions
158 show startup-config
Displays users connected to
159 show users
the router
160 show version
Displays information about
161 show ipv6 rip all current IPV6 RIP
processes.
Displays ipv6 interface
162 show ipv6 interface <interface-name>
configuration information.
Displays general information
163 show ipv6 ospf about OSPF routing
processes.
Displays routes in the IPV6
164 show ipv6 route
routing table.
Displays parameters and
current state of the active
165 show ipv6 protocols
IPV6 routing protocol
processes.
Enables and disables the
166 service dhcp DHCP server feature on
router
To view the addresses
167 show ip dhcp binding assigned to clients on dhcp
server
168 telnet <host-name>
169 telnet <IP-address>
Lists all routers along path to
170 traceroute <hostname> destination and finds the
routing problems if any.
171 traceroute <ip-address>
Traceroute command to
172 traceroute ipv6 <ipv6-address> determine path of a packet to
its destination.
username <name> password
173
<password>
174 version 2 For RIPv2 routing
175 write erase
176 write memory
177 write terminal

List of Switch Commands Supported


Sl.No. commands Comments, if any.
1 banner motd <phrase>
2 copy startup-config running-config
3 configure terminal
4 cdp advertise-v2
5 copy running-config startup-config
6 cdp holdtime <seconds>
7 cdp timer <seconds>
clock set hh:mm:ss <1-31> Month
8
<2004-2035>
9 cdp run
10 duplex <duplex-type>
11 description <phrase>
12 disable
13 enable
14 erase startup-config
15 enable secret <secret>
16 enable password <password>
17 end
18 hostname <name>
Depends on the switch type.
For module 0, port 1 the
19 interface fastethernet <0-0>/<0-24>
command is interface
fastethernet 0/1
20 ip default-gateway <ip-address>
21 ip host<hostname> <ip-address>
interface range fastethernet <0-0>/<0-
22
12>
You can enter interface
config mode.
23 interface vlan <vlan #> example: interface vlan 1
(config-if)#ip address
192.168.10.1 255.255.255.0
24 ip name-server <ip-address>
A switch can have one IP
address. The IP address of
ip address <ip-address> <subnet the switch can be accessed
25
mask> only through ports that
belong to the management
VLAN.
26 line vty 0 15
27 line console 0
28 login
29 logout
mac-address-table static <mac-
30 address> vlan <valn_num> interface
fastethernet <pnum>
31 no ip address
It re-enables the interface
when the interface is
32 no shutdown
disabled.By default interfaces
are enabled.
33 no switchport mode
34 no switchport <port_security>
35 password <password>
36 reload

37 show interfaces

38 show history
Displays mac-address-table
39 show mac-address-table
information
40 show version Display version information
for the hardware and
firmware
41 show vlan Displays vlan information
Displays vlan membership
42 show vlan-membership
information
Displays vtp status
43 show vtp status
information
44 show startup-config
45 show flash
46 show running-config
47 show ip interface brief
Disables a port and shuts-
down management vlan. no
48 shutdown
shutdown command enables
a port.
49 snmp-server enable traps vtp
Enter switch port speed
50 speed <speed>
10,100, auto.
51 switchport access vlan <vlan_num>
Access mode of the switch is
52 switchport mode access
set to access
Access mode of the switch is
53 switchport mode trunk
set to trunk
switchport port-security mac-address
54
sticky<mac_addr>
switchport port-security maximum
55
<max_macadd>
switchport port-security violation
56
<violat_mode>
Command for switch in
57 switchport trunk encapsulation dot1q
interface configuration mode
VLAN numbers can range 1-
1000,However only
58 vlan<vlan_num>
64VLANs can be active at a
time.
VLAN numbers can range 1-
59 vlan <vlan_num> name <vlan_name> 1000, VLAN name can be
upto 32 characters
Place the switch in VTP
client mode. But it does not
60 vtp client
store VLAN information in
non-volatile memory.
61 vlan database
SW(vlan)# vtp transparent
62 vtp transparent Sets the switch to VTP
TRANSPARENT mode.
Passwords are case sensitive.
Passwords should match on
63 vtp password <password>
all switches in the same
domain.
VTP domain name can be 1
to 32 characters long and
identifies the VTP
64 vtp domain <name>
administrative domain for the
switch. The domain name is
case sensitive.
65 vtp pruning
Place the switch in VTP
server mode. Stores VLAN
66 vtp server information in non-volatile
memory. Generates VLAN
advertisements.

Potrebbero piacerti anche