Set a console password to cisco: Set the console password to Cisco. |
Router(config)#line con 0
Router(config-line)#login
Router(config-line)#password cisco |
Set a telnet password: Set a telnet password. |
Router(config)#line vty 0 4
Router(config-line)#login
Router(config-line)#password cisco |
Stop console timing out: Console is not logged off. |
Router(config)#line child 0
Router(config-line)#exec-timeout 0 0 |
Set the enable password to cisco: Set the enable password to cisco. |
Router(config)#enable password cisco |
Set the enable secret password to peter:
Set the secret password to peter. This password overrides the enable password and is encrypted in the configuration file.
|
Router(config)#enable secret peter |
Enable an interface: Enable the interface. |
Router(config-if)#no shutdown |
To disable an interface: Turn off the interface. |
Router(config-if)#shutdown |
Set the clock rate for a router with a DCE cable to 64K: Set the clock rate for the router with a DCE cable to 64000. |
Router(config-if)clock rate 64000 |
Set a logical bandwidth assignment of 64K to the serial interface: Assign logical bandwidth to the serial interface. |
Router(config-if)bandwidth 64 |
To add an IP address to an interface: Add an IP to the interface. |
Router(config-if)#ip addr 10.1.1.1 255.255.255.0 |
To enable RIP on all 172.16.xy interfaces: Enable RIP on all 172.16.xy interfaces |
Router(config)# router rip
Router(config-router)#network 172.16.0.0 |
Disable RIP: Disable RIP. |
Router(config)#no router rip |
To enable IRGP with an AS of 200, to all interfaces: Enable IRGP with AS 200 for all interfaces. |
Router(config)#router igrp 200
Router(config-router)#network 172.16.0.0 |
Disable IGRP: Disable IGRP. |
Router(config)#no router igrp 200 |
The remote network static route is 172.16.1.0, with mask 255.255.255.0, next hop 172.16.2.1, with cost 5 hops. |
Router(config)#ip route 172.16.1.0 255.255.255.0 172.16.2.1 5 |
Disable CDP for the whole router: Disable CDP for the whole router. |
Router(config)#no cdp run |
Enable CDP for the whole router: Enable CDP for the whole router. |
Router(config)#cdp run |
Disable CDP on an interface: Turn off CDP on the interface. |
Router(config-if)#no cdp enable |
Enable the http server to SDM can be used: Enable the http server to use SDM.
|
Router(config)#ip http server
|
Defines a username and password: Sets a username (sue) and password (cisco). Can be used for PPP authentication or user access.
|
Router(config)#username sue password cisco
|
Define local hosts file in unix, like:
/etc/hosts in unix
|
Router(config)#ip host mypc 10.1.1.3
|
Disables DNS lookup. Useful when commands are mistyped.
|
Router(config)#no ip domain-lookup
|
Sets the logical (not physical) bandwidth for the interface. Commonly used by routing protocols, SNMP queries.
|
Router(config)#int s0
Router(config-if)#bandwidth
|
Set physical clock
|
Router(config-if)#clock rate 64000
|
Set the serial interface WAN encapsulation: In addition to hdlc, other options are PPP and frame-relay.
|
Router(config-if)#encapsulation hdlc
|
Authentication on PPP is optional: This command enables chap on the interface, the other option is PAP.
|
Router(config-if)#ppp authentication chap
|
Select LMI type. If LMI type is not configured correctly it will be detected automatically.
|
Router(config-if)#frame-relay lmi-type cisco
|
Static routing. Static routing type has Administrative Distance (AD) of 1, so it will override any dynamic routing.
|
Router(config)#ip route 50.0.0.0 255.0.0.0
10.1.2.1
|
Enables RIP version 1 on all LOCAL interfaces which have a 10.xxx address: Enables RIP v1 on all LOCAL interfaces which have a 10.xxx address
Enables RIP version 2: Enable RIP v2
|
Router(config)#router rip
Router(config-router)#network 10.0.0.0
Router(config-router)#version 2
|
Enable the router to provide a DHCP service: Set up DHCP on the router.
|
Router(config)#ip dhcp pool MYPOOL
Router(dhcp-config)#network 10.1.1.0 255.255.255.0
Router(dhcp-config)#default-router 10.1.1.1 Router(dhcp-config)#exit
Router(config)#ip dhcp excluded-address 10.1.1.1 10.1.1.99
|
Config register settings: Specifies what the router will do when it boots.
|
Router(config)#config-register 0x2102
|
Create a sub logical interface under the physical interface.
Enable 802.1q trunking on the interface.
Set IP address.
|
Router(config)#int fa0/0.1
Router(config-subif)#encapsulation dot1Q 1
Router(config-subif)#ip address 10.1.1.1
255.255.255.0
|
Enable OSPF on any local interface starting with IP address 10.1.xx
|
Router(config-)#router ospf 1
Router(config-router)#network 10.1.0.0
0.0.255.255 area 0
|
EIGRP can be configured the same as RIP or using the mask option.
|
Router(config)#router eigrp 1
Router(config-router)#network 172.16.0.0 Or
Router(config-router)#network 172.16.2.0
0.0.0.255
|
Set the ACL standard. This standard uses numbers from 1 to 99.
|
Router(config)#access-list 1 permit
172.16.1.1
|
Set up Extended ACL. The first address is the source IP address.
|
Router(config)#access-list 101 deny tcp host
172.16.1.1 host 172.16.2.1 eq telnet Router(config)#access-list 101 permit ip any any
|
Use the group command to attach an ACL to an interface: Use the group command to attach an ACL to an interface.
|
Router(config)#interface fa0/0
Router(config-if)#ip access-group 1 out
|
Example of using ACL names instead of numbers.
|
Router(config)#ip access-list extended my_list
Router(config-ext-nacl)# deny tcp host
172.16.1.1 host 172.16.2.1 eq ftp
Router(config-ext-nacl)# permit ip any any
|
Assign ACL to interface by name.
|
Router(config)#int fa0/0
Router(config-if)#ip access-group my_list in
|
Configuring a static NAT to allow a server to be access via the Internet, using the IP address on interface s0/0/1: Configuring a static NAT to allow a server to be access via the Internet, using the IP address on interface s0/0/1.
|
Router(config)#ip nat inside source static
10.1.1.2 interface s0/0/1
|
Defining interface which NAT takes place between: Defines the interface which NAT takes place between.
|
Router(config)#int fa0/0.1
Router(config-if)#ip nat inside
|
Enables RIPng: Enables RIPng
|
Router(config)#ipv6 unicast-routing
Router(config)#ipv6 router rip ccna
Router(config)#int s0/0/0
Router(config-if)#ipv6 rip ccna enable
|