cisco router configuration NTW2000 / track 2 # 1 cisco router configuration basics
cisco router configuration NTW2000 / track 2 # 2 overview ärouter configuration controls the operation of the router: äinterface address and netmask ärouting information (static or dynamic) äbooting and startup information äsecurity (passwords)
cisco router configuration NTW2000 / track 2 # 3 overview äconfiguration statements have different contexts: äglobal: enable-password mysecret äinterface: interface ethernet0 ip address router: router ospf 1 network area 0
cisco router configuration NTW2000 / track 2 # 4 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
cisco router configuration NTW2000 / track 2 # 5 global configuration äip-specific global configuration statements: ip classless ästatic route creation: ip route
cisco router configuration NTW2000 / track 2 # 6 interface configuration äinterfaces are named by type and position; e.g.: ethernet0, ethernet1,... ethernet5 serial0, serial1... serial3 äand can be abbreviated: ethernet0 or eth0 or e0 serial0 or ser0 or s0
cisco router configuration NTW2000 / track 2 # 7 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 router(config-if)#no shutdown router(config-if)#^Z router#
cisco router configuration NTW2000 / track 2 # 8 There are two modes on a cisco router ä normal mode router> äenable mode ärouter> enable ärouter# config terminal
cisco router configuration NTW2000 / track 2 # 9 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
cisco router configuration NTW2000 / track 2 # 10 where is the configuration? ärouter always has two configurations: ärunning configuration äin RAM, determines how the router is currently operating is changed by using the configuration command to see it: show running ä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 # 11 where is the configuration? äcan also be stored in more permanent places: äexternal hosts, using TFTP to move it around äin flash memory in the router äcopy command is used to move it around copy run start copy run tftp copy start tftp copy tftp start copy flash start copy start flash
cisco router configuration NTW2000 / track 2 # 12 looking at the configuration use “show running-configuration” to see the current configuration use “show startup-configuration” to see the configuration in NVRAM, that will be loaded the next time the router is rebooted or reloaded
cisco router configuration NTW2000 / track 2 # 13 changing the configuration äconfiguration statements can be entered interactively at the console, or in a telnet session, äor, edited in a text file and uploaded to the router at a later time; äsome configuration statements, especially access lists, are very difficult to work with interactively, so editing and uploading the file is the only practical way to work; äalso allows version control and auditing changes
cisco router configuration NTW2000 / track 2 # 14 interactive configuration äcan use direct serial connection to console port, or ätelnet to vty’s (“virtual terminals”), or ämodem connection to aux port äin every case, changes are made (almost) immediately, to the running configuration
cisco router configuration NTW2000 / track 2 # 15 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 K-rtr(config-if)#no shutdown use the no command to nullify command given: (config-if)# no ip addr
cisco router configuration NTW2000 / track 2 # 16 storing the configuration on a host requires: `tftpd’ on 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 []? 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 ? [confirm] Building configuration... Writing /usr/local/tftpd/K-rtr-confg !![OK]
cisco router configuration NTW2000 / track 2 # 17 restoring the configuration from a host äuse ‘tftp’ to pull file from unix host, copying to running config or startup K-rtr#copy tftp start Address of remote host [ ]? Name of configuration file [K-rtr-confg]? Configure using K-rtr-confg from ? [confirm] Loading K-rtr-confg from (via Ethernet0): ! [OK / bytes] [OK] K-rtr# reload
cisco router configuration NTW2000 / track 2 # 18 getting help äIOS has a built-in help facility; use “?” to get a list of possible configuration statements ä“?” after the prompt lists all possible commands: router#? “ ?” lists all possible subcommands, e.g.: router#show ? router#show ip ?
cisco router configuration NTW2000 / track 2 # 19 getting help ä“ ?” shows all possible command completions router#con? configure connect äthis is different (space before “?”): router#conf ? memory Configure from NV memory network Configure from a TFTP network host overwrite-network Overwrite NV memory from TFTP... network host terminal Configure from the terminal
cisco router configuration NTW2000 / track 2 # 20 getting help äthis also works in configuration mode: router(config)#ip a? accounting-list accounting-threshold accounting-transits address-pool alias as-path router(config)#int e0 router(config-if)#ip a? access-group accounting address
cisco router configuration NTW2000 / track 2 # 21 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 ? A.B.C.D IP subnet mask router(config-if)#ip addr ? secondary Make this IP address a secondary address router(config-if)#ip addr router(config-if)#
cisco router configuration NTW2000 / track 2 # 22 getting lazy help äTAB character will complete a partial word router(config)#int router(config)#interface et router(config)#interface ethernet 0 router(config-if)#ip add router(config-if)#ip address änot really necessary; partial commands can be used: router#conf t router(config)#int e0 router(config-if)#ip addr
cisco router configuration NTW2000 / track 2 # 23 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