router basic configuration
Post on 01-Mar-2018
258 Views
Preview:
TRANSCRIPT
-
7/26/2019 Router Basic configuration
1/47
Router ConfigurationBasics
-
7/26/2019 Router Basic configuration
2/47
Overview Router configuration controls the operationof the routers:
Interface IP address and netmask
Routing information (static, dynamic ordefault)Boot and startup informationSecurity (passwords and authentication)
-
7/26/2019 Router Basic configuration
3/47
Where is the Configuration?Router always has two configurations:
Running configuration
Startup confguration
-
7/26/2019 Router Basic configuration
4/47
Where is the Configuration?Running configuration:
In RAM, determines how the router iscurrently operatingIs modified using the configure commandTo see it: show running-config
Startup confguration:
In NVRAM, determines how the router willoperate after next reloadIs modified using the copy commandTo see it: show startup-config
-
7/26/2019 Router Basic configuration
5/47
Where is Startup Configuration?Can also be stored in more permanent places:
External hosts, using TFTP (Trivial File TransferProtocol)
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
-
7/26/2019 Router Basic configuration
6/47
Router Access ModesUser EXEC mode: Limited, show only
Router>
Privileged EXEC mode: Detailed---configuration of router, debugging, testing,file manipulationetc.
Router#
ROM Monitor useful for password recovery
& new IOS upload session
Setup Mode available when router has nostartup-config file
-
7/26/2019 Router Basic configuration
7/47
Network Configuration Modes
User EXECMode
Router>
PrivilegedMode Router#
GlobalConfiguration
Mode
Router(config)#
SpecificConfiguration
Mode
Router(config-xx)
-
7/26/2019 Router Basic configuration
8/47
Router Prompts How to tell where you are on the router
You can tell in which area of the routers configurationyou are by looking at the router prompts:
Router> USER prompt mode
Router# PRIVILEGED EXEC prompt mode
Router(config) terminal configuration prompt
Router(config-if) interface configuration prompt
Router(config-subif) sub-interface configurationprompt
-
7/26/2019 Router Basic configuration
9/47
Logging into the RouterConnect router to console port or telnet torouter.
router> router>enable
password router#router#?
Configuring the router: To configure router
parameters need to load into RAM.router# configure terminalrouter(config)#
-
7/26/2019 Router Basic configuration
10/47
Logging into the RouterConfiguring the router: To configure routerparameters need to load into RAM.
router# configure terminalrouter(config)#
-
7/26/2019 Router Basic configuration
11/47
Check & Adjust Clock
RouterA# show clockRouterA# clock ?RouterA# clock set?RouterA# clock set 13:03:10?RouterA# clock set 13:03:10 9?RouterA# clock set 13:03:10 9 Feb?RouterA# clock set 13:03:10 9 Feb 2016RouterA# show clock
-
7/26/2019 Router Basic configuration
12/47
Name Your RouterRouterA> ----- User ModeRouterA>enableRouterA# ----- Privileged Mode
To configure router parameters, needto enter into RAM---
RouterA# Configure TerminalRouterA(config)#
Personalized your Router Identity ---RouterA(config)# Hostname (Name)
-
7/26/2019 Router Basic configuration
13/47
-
7/26/2019 Router Basic configuration
14/47
Setting PasswordNumber one priority to make sure youhave set this password on your router.To set Global password do the following:
Enter into Global configuration Mode---RouterA# Configure TerminalRouterA(config)#RouterA(config)# enable password (your password)
OR
RouterA(config)# enable secret (your password)
-
7/26/2019 Router Basic configuration
15/47
Setting PasswordTo set user mode password for theconsole line, perform the following:
RouterA# Configure TerminalRouterA(config)#RouterA(config)# line console 0RouterA( config-line )# LoginRouterA( config-line )# Password ( yourpassword)
-
7/26/2019 Router Basic configuration
16/47
Setting PasswordTo set this password for users accessingthe router remotely via telnet, performthe following:
RouterA# Configure TerminalRouterA(config)#RouterA(config)# line vty 0 4
RouterA( config-line )# LoginRouterA( config-line )# Password ( yourpassword)
* line vty [first line number] [last line number] command. By default, Cisco IOS enables 5 virtualterminal lines lines 0 through 4.
-
7/26/2019 Router Basic configuration
17/47
Review
Set Clock
Set BannerSet Password
Configure Interfaces
-
7/26/2019 Router Basic configuration
18/47
Interface ConfigurationTypes of interfaces ----
GigabitEthernet interface
FastEthernet interfaceEthernet interfaces
Serial interfaces
-
7/26/2019 Router Basic configuration
19/47
Interface ConfigurationInterfaces are named by typeslot/port; e.g. :
ethernet0, ethernet1,... Ethernet5/1
Serial0/0, serial1 ... Serial3
Can be abbreviated:ethernet0 or eth0 or e0Serial0/0 or ser0/0 or s0/0FastEthernet0/0 or fe0/0GigabitEthernet0/1 or ge0/1
-
7/26/2019 Router Basic configuration
20/47
Interface ConfigurationBy default interfaces are down.
Need to enable after configuration.
router( config-if )#no shutdown
To disable any interface.router( config-if )#shutdown
Descriptionrouter( config-if )#description ethernetlink to admin building router
-
7/26/2019 Router Basic configuration
21/47
Interface ConfigurationConfiguring Ethernet interface:
RouterA# config terminal
RouterA(config)#interface ethernet 0/0RouterA(config-if)# Description xxxxxRouterA(config-if)# ip address n.n.n.n
m.m.m.m
RouterA(config-if)#no shutdownRouterA(config-if)#exitRouterA#
-
7/26/2019 Router Basic configuration
22/47
Interface ConfigurationConfiguring FastEthernet interface:
RouterA# config terminal
RouterA(config)#interface fastethernet 0/0RouterA(config-if)# Description xxxxxRouterA(config-if)# ip address n.n.n.n
m.m.m.m
RouterA(config-if)#no shutdownRouterA(config-if)#exitRouterA#
-
7/26/2019 Router Basic configuration
23/47
Interface ConfigurationConfiguring GigabitEthernet interface:
RouterA# config terminal
RouterA(config)#interface ge 0/0RouterA(config-if)# Description xxxxxRouterA(config-if)# ip address n.n.n.n
m.m.m.m
RouterA(config-if)#no shutdownRouterA(config-if)#exitRouterA#
-
7/26/2019 Router Basic configuration
24/47
Interface ConfigurationConfiguring Serial interface:
RouterA# config terminal
RouterA(config)#interface serial 0/0/0RouterA(config-if)# Description xxxxxRouterA(config-if)# ip address n.n.n.n
m.m.m.m
RouterA(config-if)#no shutdownRouterA(config-if)#exitRouterA#
-
7/26/2019 Router Basic configuration
25/47
Saving Configuration ParametersAll the changes are performed onrunning configuration file ie. RAM.Need to store those changes atNVRAM/Flash for using in next reload.
RouterA#copy running-config startup-configOR
RouterA# copy run start
-
7/26/2019 Router Basic configuration
26/47
Review
Set ClockSet Banner
Set PasswordInterface Configuration
Save ConfigurationBackup Configuration
-
7/26/2019 Router Basic configuration
27/47
5 Frequent IOS Commands(1)To know what interfaces are on yourrouter, important statistics about thoseinterfaces, and whether they are up ordown.
RouterA# show interfaces
-
7/26/2019 Router Basic configuration
28/47
5 Frequent IOS Commands(2)Whatever configuration changes, needto save those changes. This commandcopies the configuration in RAM that youhave been modifying to theconfiguration in flash
RouterA# copy running-configstartup-config
OR RouterA# copy run start
OR
RouterA# wr (Write Memory)
-
7/26/2019 Router Basic configuration
29/47
5 Frequent IOS Commands(3)Once you know that your interfaces areup and you have saved yourconfiguration, you need to know --- areyour routing protocols working?
RouterA# show ip route
-
7/26/2019 Router Basic configuration
30/47
5 Frequent IOS Commands(4)
To get the the best summary of thestatus and IP addresses of yourinterfaces, use following ---
RouterA# show ip interface brief
-
7/26/2019 Router Basic configuration
31/47
5 Frequent IOS Commands(5)
To see the entire routers configurationie. to see the IP addresses, interfaces,passwords (that are in clear text),
routing protocols, and other settings..
RouterA# show running config
-
7/26/2019 Router Basic configuration
32/47
IOS Commands - show There is one privileged mode commandthat you will find yourself usingextensively for:
Viewing routers configurationVerifying interfaces configurationViewing interfaces status
RouterA# show running configurationRouterA# show clockRouterA# show interfacesRouterA# show ip interfaces brief
RouterA# show interfaces description
-
7/26/2019 Router Basic configuration
33/47
Configuring your RouterSet the enable (secret) password:
router(config)# enable secret your pswd
This MD5 encrypts the password
The old method was to use the enable password command. But this is not secure (weak encryption) andis ABSOLUTELY NOT RECOMMENDED. DO NOT USE!
Ensure that all passwords stored on router are(weakly) encrypted rather than clear text:
router(config)# service password-encryption
-
7/26/2019 Router Basic configuration
34/47
The NO CommandUsed to reverse or disable commands e.g
ip domain-lookup
no ip domain-lookup
ip address 1.1.1.1 255.255.255.0no ip address
-
7/26/2019 Router Basic configuration
35/47
Getting Help
-
7/26/2019 Router Basic configuration
36/47
Getting Online HelpIOS has a built-in help facility;
use ? to get a list of possible configurationstatements
? after the prompt lists all possiblecommands:router#?
? lists all possiblesubcommands, e.g.:
router#show ?router#show ip ?
-
7/26/2019 Router Basic configuration
37/47
Getting Online Help ? shows all possible commandcompletions
router#con?
configure connect
-
7/26/2019 Router Basic configuration
38/47
Getting Online HelpThis also works in configuration mode:router(config)#ip a?
accounting-list accounting-threshold
accounting-transits address-poolalias as-path
router(config)#int e0/0
router(config-if)#ip a?access-group accounting address
-
7/26/2019 Router Basic configuration
39/47
Getting Online HelpCan explore a command to figure out the syntax:
router(config-if)#ip addr ? A.B.C.D IP address
router(config-if)#ip addr n.n.n.n ? A.B.C.D IP subnet mask
router(config-if)#ip addr n.n.n.n m.m.m.m ?secondary Make this IP address a secondary address
router(config-if)#ip addr n.n.n.n m.m.m.m router(config-if)#
-
7/26/2019 Router Basic configuration
40/47
Getting Lazy Online HelpTAB character will complete a partial wordhostel-rtr(config)#int hostel-rtr(config)#interface et hostel-rtr(config)#interface ethernet 0
hostel-rtr(config-if)#ip add hostel-rtr(config-if)#ip address n.n.n.n m.m.m.m
Not really necessary; partial commands can beused:router#conf trouter(config)#int e0/0router(config-if)#ip addr n.n.n.n
-
7/26/2019 Router Basic configuration
41/47
Getting Lazy Online HelpCommand 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
Ctrl-a takes you to start of line
Ctrl-e takes you to end of line
-
7/26/2019 Router Basic configuration
42/47
Backing Up Router ConfigurationRunning configuration can be backedup into TFTP server or some otherlocations.
RouterA# copy run tftp --- to copy the runningconfiguration into FTFT server.
Address or name of remote host []?172.16.10.2 the ip address of TFTP
serverDestination filename [routername-confg]?/Backup/Router01.cfg the folder path on theserver where the configuration file will be stored)
-
7/26/2019 Router Basic configuration
43/47
Restore Router Configuration
RouterA# show run --- to see the runningconfigurationRouterA# copy tftp run --- to copy theconfiguration file from TFTP server to the runningconfiguration of the router/RAMAddress or name of remote host []? 172.16.10.2 TFTP server addressSource filename[]? /Backup/Router01.cfg the configuration file to be copied to the router[router name]# show run[router name]# show interfaces[router name]# copy run start
-
7/26/2019 Router Basic configuration
44/47
View ConfigurationUse show running-configuration to seethe current configuration
Use show startup-configuration to see
the configuration in NVRAM, that willbe loaded the next time the router isrebooted or reloaded
-
7/26/2019 Router Basic configuration
45/47
What Next?????
-
7/26/2019 Router Basic configuration
46/47
Deleting your Routers Configuration
To delete your routers configuration
Router#erase startup-config
OR Router#write eraseRouter#reload
Router will start up again, but in setupmode, since startup-config file does notexists
-
7/26/2019 Router Basic configuration
47/47
Cisco RouterConfiguration Basics
Questions?
top related