Professional Documents
Culture Documents
Cisco Router Configuration NTW2000 / Track 2 # 1
Cisco Router Configuration NTW2000 / Track 2 # 1
NTW2000 / track 2 # 1
overview
router configuration controls the operation of the router:
interface address and netmask
NTW2000 / track 2 # 2
overview
configuration statements have different contexts:
global: enable-password mysecret interface: interface ethernet0 ip address 195.176.118.254 255.255.255.0 router: router ospf 1 network 195.176.118.0 0.0.0.255 area 0
cisco router configuration
NTW2000 / track 2 # 3
global configuration
global configuration statements are independent of any particular interface or routing protocol, e.g.:
hostname myrouter
enable-password mysecret
service password-encryption
logging facility local0 logging 195.176.118.42
NTW2000 / track 2 # 4
global configuration
ip-specific global configuration statements:
ip classless
NTW2000 / track 2 # 5
interface configuration
interfaces are named by type and position; e.g.:
ethernet0, ethernet1,... ethernet5 serial0, serial1 ... serial3
NTW2000 / track 2 # 6
interface configuration
ip address and netmask configuration, using interface commands (interactive configuration example, showing
prompts):
router#config terminal router(config)#interface e0 router(config-if)#ip address 195.176.118.254 255.255.255.0 router(config-if)#no shutdown router(config-if)#^Z router#
NTW2000 / track 2 # 7
enable mode
router> enable router# config terminal
NTW2000 / track 2 # 8
interface configuration
administratively enable/disable the interface
router(config-if)#no shutdown router(config-if)#shutdown (config-if)# no ip proxy-arp (config-if)# no ip directed broadcast (config-if)# no ip redirect
description
#description 128k circuit 123-ABC to hotel
NTW2000 / track 2 # 9
startup configuration
in NVRAM, determines how the router will operate after next reload is changed using the copy command to see it: show startup
cisco router configuration
NTW2000 / track 2 # 10
run start run tftp start tftp tftp start flash start start flash
NTW2000 / track 2 # 11
NTW2000 / track 2 # 12
NTW2000 / track 2 # 13
interactive configuration
can use direct serial connection to console port, or telnet to vtys (virtual terminals), or
NTW2000 / track 2 # 14
interactive configuration
enter configuration mode, using configure term prompt gives a hint about where you are:
router#configure terminal router(config)#hostname K-rtr K-rtr(config)#ip classless K-rtr(config)#ip subnet-zero K-rtr(config)#interface ethernet3 K-rtr(config-if)#ip address 195.176.118.253 255.255.255.0 K-rtr(config-if)#no shutdown use the no command to nullify command given: (config-if)# no ip addr 195.176.118.253 255.255.255.0
cisco router configuration
NTW2000 / track 2 # 15
requires: `tftpdon a unix host; destination file must exist before the file is written and must be world writable...
copy run tftp K-rtr#copy run tftp Remote host []? 195.176.118.42 Name of configuration file to write [K-rtr-confg]? /usr/local/tftpd/K-rtr-confg Write file /usr/local/tftpd/K-rtr-confg on... host 195.176.118.42? [confirm] Building configuration... Writing /usr/local/tftpd/K-rtr-confg !![OK]
NTW2000 / track 2 # 16
NTW2000 / track 2 # 17
getting help
IOS has a built-in help facility; use ? to get a list of possible configuration statements
subcommands, e.g.:
router#show ? router#show ip ?
cisco router configuration
NTW2000 / track 2 # 18
getting help
<partial command>? shows all possible command completions
Overwrite NV memory from TFTP.. network host Configure from the terminal
NTW2000 / track 2 # 19
getting help
this also works in configuration mode:
router(config)#ip a? accounting-list accounting-threshold accounting-transits address-pool alias as-path
address
NTW2000 / track 2 # 20
getting help
can explore a command to figure out the syntax:
router(config-if)#ip addr ? A.B.C.D IP address router(config-if)#ip addr 169.222.64.1 ? A.B.C.D IP subnet mask router(config-if)#ip addr 169.222.64.1 255.255.255.0 ? secondary Make this IP address a secondary address <cr> router(config-if)#ip addr 169.222.64.1 255.255.255.0 router(config-if)#
NTW2000 / track 2 # 21
NTW2000 / track 2 # 22
getting lazy
command history
IOS maintains short list of previously typed commands up-arrow or ^P recalls previous command down-arrow or ^N recalls next command
line editing
left-arrow, right-arrow moves cursor inside command
^D or backspace will delete character in front of cursor
cisco router configuration
NTW2000 / track 2 # 23