Upload
buithien
View
226
Download
0
Embed Size (px)
Citation preview
1
Configuring a Network Operating Systemy
Objectives
Explain the purpose of Cisco IOS.Explain how to access and navigate Cisco IOS to configure network devices.Describe the command structure of Cisco IOS software.Configure hostnames on a Cisco IOS device using the CLI.Use Cisco IOS commands to limit access to device configurations.Use Cisco IOS commands to save the running configuration.Explain how devices communicate across network media.Configure a host device with an IP address.Verify connectivity between two end devices.
2
Cisco IOSOperating Systems
All networking equipment depend on operating systems:End users (PCs laptops smart phones tablets)End users (PCs, laptops, smart phones, tablets)SwitchesRoutersWireless access pointsFirewalls
Cisco Internetwork Operating System (IOS)Collection of network operating systems used on Cisco devices
3
Cisco IOS
Operating Systems
4
Cisco IOS
Purpose of OS
PC ti t (Wi d 8 Li & OS X) f t h i lPC operating systems (Windows 8, Linux & OS X) perform technical functions that enable • Use of a input and output devices• Manage processes and programs• Manage file systems, security, hardware, etc.
Switch or router IOS provides options to • Same functions as host operating systems• Configure interfaces• Enable routing and switching functions
All networking devices come with a default IOS (switches, routers, firewalls)Possible to upgrade the IOS version or feature set 5
Cisco IOS
Location of the Cisco IOS
IOS stored in FlashNon-volatile storage – not lost when power is lostCan be changed or overwritten as neededCan be used to store multiple versions of IOSIOS copied from flash to volatile RAM when bootedQuantity of flash and RAM memory determines IOS that can be used
6
2
Cisco IOS
IOS FunctionsMajor functions performed or enabled by Cisco routers and switches include:
7
Router/Switch Bootup Process (more in later course)
8
Bootup Process
9
running-configIOS (running)
startup-config IOSios (partial)Bootup program
Where is the permanent configuration file stored used during boot-up? NVRAM (B)Where is the diagnostics software stored executed by hardware modules? ROM (D)
Where is the backup (partial) copy of the IOS stored? ROM (D)
Where is IOS permanently stored before it is copied into RAM? FLASH (C)
Where are all changes to the configuration immediately stored? RAM (A)
10
running-configIOS (running)
startup-config IOSios (partial)Bootup program
A B C D
?
?
?
?
?
?
11
running-configIOS (running)
startup-config IOSios (partial)Bootup program
?
?
startup-config
IOS
Bootup program
ios (partial)
running-config
IOS (running)
A B D
B A D
C D A
12
running-configIOS (running)
startup-config IOSios (partial)Bootup program
A B C D
3
Accessing a Cisco IOS DeviceConsole Access Method
Most common methods to access the Command Line InterfaceConsoleTelnet or SSHAUX port
13
Accessing a Cisco IOS Device
Console Access Method
C l tConsole portDevice is accessible even if no networking serviceshave been configured (out-of-band)Need a special console cable (aka rollover cable)Allows configuration commands to be enteredShould be configured with passwords to prevent unauthorized accessDevice should be located in a secure room so console port can not be easily accessed
14
Establishing a HyperTerminal session
Rollover cable
Console portTerminal or a PC with terminal
Router
15
Connect PC using the RJ-45/mini-USB to Serial/USB rollover cable. Configure the terminal or PC terminal emulation software for:
9600 baud8 data bitsno parity1 stop bitno flow control
Com1 or Com2 serial port Or USB port with USB-to-Serial adapter
emulation software
Terminal (Serial) Settings)
16
Configure the terminal or PC terminal emulation software for: 9600 baud8 data bitsno parity1 stop bitno flow control.
Establishing a Terminal/Serial/Console session
Important: A console connection is not the same as a network connection!
• PuTTY• Tera Term• SecureCRT• HyperTerminal• OS X Terminal• Zoc
17
=
Dumb Terminal
Accessing a Cisco IOS Device
Telnet, SSH, and AUX Access MethodsTelnet
Method for remotely accessing the CLI over a networkRequire active networking services and one active interface that is configured
Secure Shell (SSH) – Preferred over TelnetRemote login similar to Telnet but utilizes more securitySt d th ti tiStronger password authenticationUses encryption when transporting data
Aux Port (not used too much)Out-of-band connectionUses telephone lineCan be used like console port
18
4
C:\> ssh
C:\> ping
Ethernet ConnectionNetwork connection needed
19
When can you use a network connection to connect to the router?
What software/command do you need?
What cable and ports do you use?
When should you not use a network connection to configure the router?
When there is a network connection to the router (telnet).
TCP/IP, Terminal prompt (DOS), Tera Term, etc.
PC & Router: Ethernet NICEthernet straight-through cable
When the change may disconnect the telnet connection.
NIC
Accessing a Cisco IOS Device
Terminal Emulation Programs
Software available for connecting to a networking device (usually same as terminal/serial/console connection):
PuTTYTera TermSecureCRTHyperTerminalOS X TerminalZoc
20
Navigating the IOSCisco IOS Modes of Operation
21
Navigating the IOS
Cisco IOS Modes of Operation
enable
configure terminal
interface < >router < >line < >line < >
22
Navigating the IOS
Primary Modes
enableenable
23
Navigating the IOS
Global Configuration Mode and Submodes
Global configuration mode and interface configuration modes can only be reached from the privileged EXEC mode. 24
5
Navigating the IOS
Navigating between IOS Modes
Similar IOS commands for switches and routers25
Navigating the IOS
Navigating between IOS Modes (cont.)Switch> user modeSwitch> enable go to privilege mode Switch# configure terminal go to global configuration
modeSwitch(config)# interface vlan 1 go to interface modeSwitch(config-if)# exitSwitch(config)# exitSwitch# config t Shortened commands and parametersSwitch(config)# vlan 1 go to VLAN configuration modeSwitch(config-vlan)# end go to privilege-EXEC mode Switch# disable Switch> enableSwitch# config t Switch(config)# line vty 0 4 go to interface (line) modeSwitch(config-line)# exitSwitch(config)#
26
Common Commands for Switches and RoutersSwitch> user modeSwitch> enableSwitch# privilege mode
Switch# configure terminalSwitch(config)# exitSwitch# config t
Switch(config)# hostname name
Switch(config)# enable secret password privilege password
27
g p p g pSwitch(config)# line console 0 console passwordSwitch(config-line)# password passwordSwitch(config-line)# loginSwitch(config)# line vty 0 4 telnet passwordSwitch(config-line)# password passwordSwitch(config-line)# login
Switch(config)# banner motd # message # banner
Switch(config)# interface type number configure interfaceSwitch(config-if)# description description
Making your life easier!
Switch# enableSwitch(config)# line console 0 Console portSwitch(config-line)# logging synchronous IOS will notSwitch(config-line)# exec-timeout 0 0 passwordSwitch(config)# no ip domain-lookup passwordSwitch(config-line)# login
28
Switch(config)# banner motd # message # banner
Switch(config)# interface type number configure interfaceSwitch(config-if)# description description
Navigating the IOS
Navigating between IOS Modes
29
The Command StructureIOS Command Structure
30
6
The Command Structure
Cisco IOS Command ReferenceIOS Command ConventionsThe general syntax for a command is the command followed by any appropriate keywords (defined) and arguments (undefined). An argument is generally not a predefined word. An argument is a value or variable defined by the user.
Switch(config-if)# description string
Boldface text indicates commands and keywords that are typed as shown Italic text indicates an argument for which you supply the value. For the description command, the argument is a string value. The string value can be any text string of up to 80 characters.Example:
Switch(config-if)# description MainHQ Office Switch
31
The Command Structure
Cisco IOS Command ReferenceFor the ping command:
Switch> ping IP-addressSwitch> ping 10.10.10.5
The command is ping and the user defined argument is the 10.10.10.5.
Similarly, the syntax for entering the traceroute command is:Switch> traceroute IP-addressSwitch> traceroute 192.168.254.254
The command is traceroute and the user defined argument is the 192.168.254.254.
32
The Command Structure
Context Sensitive Help
33
The Command Structure
Command Syntax Check
34
The Command Structure
Command Syntax Check
35
The Command Structure
Command Syntax Check
36
7
The Command Structure
Hot Keys and ShortcutsTab - Completes the remainder of a partially typed command or keywordCtrl-R - Redisplays a lineCtrl-A – Moves cursor to the beginning of the lineCtrl-Z - Exits configuration mode and returns to user EXECD A All th t ll f d th h fDown Arrow - Allows the user to scroll forward through former commandsUp Arrow - Allows the user to scroll backward through former commandsCtrl-Shift-6 - Allows the user to interrupt an IOS process such as ping or traceroute. Ctrl-C - Aborts the current command and exits the configuration mode
37
The Command Structure
IOS Examination Commands
38
The Command Structure
The show version Command
39
The Command Structure
Navigating the IOS
40
HostnamesWhy the Switch
Let’s focus on Creating a two PC network connected via a switchSetting a name for the switchLimiting access to the device configurationConfiguring banner messages Saving the configuration
41
Hostnames
Device NamesHostnames allow devices to be identified by network administrators over a network or the Internet.Some guidelines for naming conventions are that names should:
Start with a letterContain no spacesEnd with a letter or digitUse only letters, digits, and dashesBe less than 64 characters in length
Without names, network devices are difficult to identify for configuration purposes.
42
8
Hostnames
Configuring Hostnames
Switch(config)# hostname Sw-Floor-3Sw-Floor3(config)#
Switch(config)# hostname Sw-Floor-2Sw-Floor2(config)#
Switch(config)# hostname Sw-Floor-1Sw-Floor1(config)#
43
Limiting Access to Device ConfigurationsSecuring Device AccessThe passwords introduced here are:
Enable password - Limits access to the privileged EXEC mode
Enable secret - Encrypted, limits access to the privileged EXEC mode
Console password - Limits device access using the console connection
VTY password - Limits device access over Telnet
Note: In most of the labs in this course, we will be using simple passwords such as cisco or class.
44
Limiting Access to Device Configurations
Securing Privileged EXEC Access
use the enable secret command, not the older enable password commandenable secret provides greater security because the password is encrypted
class
45
Limiting Access to Device Configurations
Securing User EXEC Access
Console port must be secured• reduces the chance of unauthorized personnel physically
plugging a cable into the device and gaining device access
vty lines allow access to a Cisco device via Telnet• number of vty lines supported varies with the type of
device and the IOS version
46
Limiting Access to Device Configurations
Encrypting Password Display
service password-encryption
prevents passwords from showing up as plain text when viewing the configuration
purpose of this p pcommand is to keep unauthorized individuals from viewing passwords in the configuration file
once applied, removing the encryption service does not reverse the encryption
47
Limiting Access to Device Configurations
Banner Messages
Important part of the legal process in the event that someone is
Switch(config)# banner motd # This is a secure system Authorized Access Only!!! #
Sw-Floor3(config)#
p p g pprosecuted for breaking into a deviceWording that implies that a login is "welcome" or "invited" is not appropriate
48
9
Saving Configurations
Configuration FilesSwitch# show running-config
Switch# copy running-config startup-config
<Changes made>Switch# delete vlan.datDelete filename [vlan.dat]?
Delete flash:vlan.dat? [confirm]Switch# erase startup-configSwitch# reloadSystem configuration has been modified. Save? [yes/no]: nProceed with reload? [confirm]
49
Saving Configurations
Capturing Text
50
Saving Configurations
Capturing Text
51
Ports and AddressesIP Addressing in the Large
Each end device on a network must be configured with an IP addressStructure of an IPv4address is called dotted decimalIP address displayed in p ydecimal notation, with four decimal numbers between 0 and 255With the IP address, a subnet mask is also necessaryIP addresses can be assigned to both physical ports and virtual interfacesIPv4 and IPv6 addresses will be discussed in more detail later
52
Ports and Addresses
Interfaces and PortsTerms are used interchangeablySome interfaces can be can be configured with an IP address such as:
NIC (Ethernet interface) on a host/computerRouter’s Ethernet or Serial interfaces
Switches have ports (interfaces) but do not typically have IP addresses assigned to themUsed to connect devices on LANs that do have IP addresses such as hosts, routers, printers.
53
Addressing Devices
Configuring a Switch Virtual Interface
Allows the network administrator to communicate (SSH, telnet, ping) with the switch.It is OPTIONALIt is OPTIONAL“Layer 2” switches do NOT need an IP address to forward Ethernet frames.IP address - together with subnet mask, uniquely identifies end device on internetwork (more later)Subnet mask - determines which part of a larger network is used by an IP address interface VLAN 1 - interface configuration mode ip address 192.168.10.2 255.255.255.0 - configures the IP address and subnet mask for the switch no shutdown - administratively enables the interfaceSwitch still needs to have physical ports configured and VTY lines to enable remote management 54
10
Addressing DevicesManual IP Address Configuration for End Devices
More later!
55
Addressing DevicesAutomatic IP Address Configuration for End Devices
More later!
56
Addressing Devices
IP Address Conflicts
More later!
57
Verifying ConnectivityTest the Loopback Address on an End Device
C:\> ping 127.0.0.1Reply from 127.0.0.1: bytes=32 time<1ms TTL=128Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 58
Verifying Connectivity
Testing the Interface Assignment
59
Verifying Connectivity
Testing End-to-End Connectivity
60
11
Configuring a Network Operating System
SummaryServices provided by the Cisco IOS accessed using a command-line interface (CLI)• accessed by either the console port, the AUX port, or through
telnet or SSH• can make configuration changes to Cisco IOS devices• a network technician must navigate through various hierarchicala network technician must navigate through various hierarchical
modes of the IOSCisco IOS routers and switches support a similar operating systemIntroduced the initial settings of a Cisco IOS switch device• setting a name• limiting access to the device configuration• configuring banner messages • saving the configuration
61
Thanks to Rick Graziani for using manyof his lecture slides
62