Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
OSI MODEL
TCP/IP MODEL
Presentation : Responsible for presenting the data in standard formats. Some
Presentation layer standards are JPEG, MPEG, MIDI, PICT, Quick Time, TIFF.
Application : Defines TCP/IP application protocols and how
host programs interface with transport layer services to use
the network. Ex: FTP, SMTP, Telnet
Session : Responsible for co-ordinating communication between systems/nodes.
Some of the session layer protocols and interfaces: NFS, RPC, SQL, ASP, DNA SCP
Datalink : Consists of LLC sublayer and MAC sublayer. LLC handles error control, flow Physical : Controls the hardware devices and media that make
flow control, framing etc. MAC handles access to shared media such as ethernet. up the network.
1
Cisco™ CCENT : IOS
ROM : Memory containing micro-code for basic functions to start and maintain the router. <ctrl> A: Move to the beginning of the command line
RAM/DRAM : Stores the running configuration, routing tables, and packet buffers. <ctrl> E: Move to the end of the command line
NVRAM : Memory that does not lose information when power is lost. Stores the system’s <ctrl> F: Move forward one character, same as using “Right Arrow”
configuration file and the configuration register. <ctrl> B: Move backward one character, same as using “Left Arrow".
Flash Memory : Stores the compressed IOS image. <ctrl> P: Repeat Previous command, same as using “Up Arrow”
<ctrl> N: Repeat Next (more recent) command, same as using "Down Arrow"
Router Default Boot Sequence for Cisco IOS Router boot configuration commands <esc> B: Moves to beginning of previous word.
<esc> F: Moves to beginning of next word.
1. NVRAM 3. TFTP server boot system ROM : boots from system ROM <ctrl>R: Creates new command prompt, followed by all the
2. Flash (sequential) 4. ROM boot system flash <IOS file name> : boots characters typed at the last one.
IOS from flash memory
boot system tftp <IOS file name>
The router first looks at Startup Config file in NV
RAM, if not available, it falls back to Flash, then <tftp_addr> : boots IOS from a tftp server
to TFTP and then to ROM.
2
Cisco™ CCENT : Password Recovery
Procedure 1 Procedure 2
Complete these steps in order to recover your password: Complete these steps in order to recover your password:
1. Attach a terminal or PC with terminal emulation to the console port of the router and 1. Shut down the router.
set terminal settings to 9600 baud rate, No parity, 8 data bits, 1 stop bit, No flow 2. Remove the compact flash that is at the back of the router.
control. 3. Power on the router.
The configuration register is usually set to 0x2102 or 0x102. If you can no longer 4. Once the Rommon1> prompt appears, enter this command:
access the router you can safely assume that your configuration register is set to confreg 0x2142
0x2102. 5. Insert the compact flash.
2. Use the power switch in order to turn off the router, and then turn the router back on. 6. Type reset.
3. Press Break on the terminal keyboard within 60 seconds of power up in order to put 7. When you are prompted to enter the initial configuration, type No, and press Enter.
the router into ROMmon. 8. At the Router> prompt, type enable.
4. Type confreg 0x2142 at the rommon 1> prompt in order to boot from Flash. This step 9. At the Router# prompt, enter the configure memory command, and press Enter in
bypasses the startup configuration where the passwords are stored. order to copy the startup configuration to the running configuration.
5. Type reset at the rommon 2> prompt. 10. Use the config t command in order to enter global configuration mode.
The router reboots, but ignores the saved configuration. 11. Use this command in order to create a new user name and password:
6. Type no after each setup question, or press Ctrl-C in order to skip the initial setup router(config)#username cisco password cisco
procedure. 12. Use this command in order to change the boot statement:
7. Type enable at the Router> prompt. config-register 0x2102
You are in enable mode and should see the Router# prompt. 13. Use this commnd in order to save the configuration:
8. Type configure memory or copy startup-config running-config in order to copy write memory
the nonvolatile RAM (NVRAM) into memory.
9. Type configure terminal. Reload the router, and then use the new user name and password to log in to the
The router(config)# prompt appears. router.
10. Type enable secret <password> in order to change the enable secret password.
For example:
router(config)#enable secret cisco
11. Issue the no shutdown command on every interface that you use.
12. Type write memory or copy running-config startup-config in order to commit the
changes.
Note : The given procedures are generic in nature, and for exact sequence of steps, please refer to product manual.
3
Cisco™ CCENT : IPv4 Addressing
Binary is a base 2 system with only two numbers 0 or 1. Decimal is a Base 10 system with 10 possible values (0 to 9)
The weightage of binary digits from right most bit position to the left most bit
position is given below. To convert decimal to binary, simply divide the decimal value by 2 and then write
down the remainder, repeat this process until you cannot divide by 2 anymore.
10011101 = 157
To convert, you simply take a value from the top row wherever there is a 1 below,
and then add the values together.
= 128 + 0 + 0 + 16 + 8 + 4 + 0 + 1
4
Cisco™ CCENT : IPv4 Addressing
1. An IP address (32 bit number, 4 bytes) consists of four octets seperated Class Format Leading-bit-pattern Network-addr-range Max-netw Max-hosts
by dots.
A N.H.H.H 0 0-126 127 16,777,214
The octet is a binary number of eight digits, which equals the decimal numbers
from 0 to 255. B N.N.H.H 10 128-191 16,384 65,534
Class D addresses are used for multicasting, they begin with “1110” and the addr range is 224-239.
Class E addresses are reserved addresses that begin with “11110” and the range is 240-254.
2. The internet protocol defines the special network address 127.0.0.1 as a Private addr range : Class A : 10.0.0.0 to 10.255.255.255, Class B : 172.16.0.0 to 172.31.255.255,
local loopback address. Class C : 192.168.0.0 to 192.168.255.255
A Subnet mask is a 32-bit number that masks an IP address, and divides the IP address into network
address and host address.
Subnet Mask is made by setting network bits to all "1"s and setting host bits to all "0"s.
CIDR Notation : Classless Inter Domain Routing (CIDR) is a method for assigning IP addresses without
using the standard IP address classes like Class A, Class B or Class C.
In CIDR notation, an IP address is represented as A.B.C.D /n, where "/n" is called the IP prefix or network
prefix. The IP prefix identifies the number of significant bits used to identify a network.
Ex: 216.3.128.12, with subnet mask of 255.255.255.128 may be written as 216.3.128.12/25 using
CIDR Notation.
5
Cisco™ CCENT : IPv6 Addressing
IPv6 Addressing
Version (4 bits) : IP version number (6)
IPv6 address consists of 8 groups of four hexadecimal digits separated by colons and which mainly consists
of 3 segments called Global Prefix which is of 48 bits, subnet part with 16 bits and Interface ID called as Host Traffic Class (8 bits) : Used for QoS
part with 64 bits.
Flow Label (20 bits) : Used for packet labelling
The first 3 octets constitute Global Prefix, the fourth octet constitute subnet part and the last four form the
Interface ID. Payload Length (16 bits) : Length of the IPv6 payload
Next Header (8 bits) : Identifies the type of header following the IPv6 header
Hop Limit (8 bits) : Number of hops until the packet gets discarded.
EUI-64 Format
IPv6 Communication Types IPv6 Address Scopes
MAC to EUI-64 conversion inserts hex “FFFE” in the middle of a MAC addr, Then flips
the U/L bit to 1, in order to create a 64-bit interface ID from a 48-bit Mac address.
Unicast : used for one-to-one communication.
There are 3 types of unicast addresses namely
::/0----------------> Default Route
global, unique-local and link-local
::/128------------> Unspecified
::1/128-----------> Loopback
Multicast : used for one-to-many communication FC00::/7---------> Unique Local Unicast
IPv6 multicast address begins with "FF" FE80::/10--------> Link-Local Unicast
FEC0::/10-------> Site-Local Unicast
Anycast : used for one-to-one-of-many FF00::/8----------> Multicast
communication
6
Cisco™ CCENT : Subnetting
You want X number of subnets, what is the subnet mask ? (Assume we need 10 subnets, i.e, X=10)
Tip : Convert X to binary, determine how many low order bits need to make the number, that many bits is number of high order bits that make up your subnet mask, convert high order bits to
decimal value.
Solution :
Consider the Class C address – N.N.N.H where N is the Network portion and H is the host portion. Host Portion is as shown ----->
Step 2: Number of low order bits required to make the number is 4 (from the figure shown above)
Step 3: Therefore 4 high-order bits make up the subnet mask, i.e, 128, 64, 32, 16
Add 4 high order bits to create subnet mask i.e. 128+64+32+16=240 (11110000). The subnet mask is 255.255.255.255.240
7
Cisco™ CCENT : Subnetting
Determine the range of valid IP Addresses for an X subnet mask ? (Assume X value to be 240 in this case)
Tip : Convert X to binary and determine the decimal value of lowest high order bit, start the range of addresses at that value, and increment the range by that value.
.
Solution :
Step 2: The decimal value of lowest high order bit is 16 (24) as seen from the figure above. Therefore, this number becomes the increment value to determine the IP address ranges.
Note: All zeros and all ones host addresses cannot be used.
8
Cisco™ CCENT : Subnetting
How many subnet bits are required for X number of hosts ? (Assume X value to be 5 in this case)
Tip : Convert X (for the subnets) to binary, determine the number of bits needed for the host portion, additionally determine the subnet mask from the remaining bits, using formula 2ⁿ, find the
relevant number of subnets in this scenario.
.
Solution :
Step 1: Consider the Class C address N.N.N.H, where H is the host portion whose binary and decimal representation is as shown ---->
Step 2: As shown in the figure above, the number of bits needed for the host portion are 3. Therefore, 2bits-2=23-2=6 (6>5)
Step 3 (Additional): To know the subnet mask , add the decimal value of the remaining 5 bits i.e, (128+64+32+16+8) = 248
Number of subnet bits: 29, here 5 bits are used from the host portion of our subnet mask
Therefore number of subnets required is (2n), where 'n' is the number of bits being used from the host portion of our subnet mask i.e. 5
9
CiscoTM CCENT : EIGRP and OSPF
EIGRP
Important terms used in EIGRP Routing metrics used by IGRP
Successor: A route (or routes) selected as the primary route(s) used to Bandwidth: This is represents the maximum throughput of a link.
transport packets to reach destination. Note that successor entries are kept in MTU (Maximum Transmission Unit): This is the maximum message length that is acceptable to
the routing table of the router. all links on the path. The larger MTU means faster transmission of packets.
Feasible successor: A route (or routes) selected as backup route(s) used Reliability: This is a measurement of reliability of a network link. It is assigned by the
to transport packets to reach destination. Note that feasible successor entries administrator or can be calculated by using protocol statistics.
are kept in the topology table of a router. Delay: This is affected by the band width and queuing delay.
DUAL (Diffusing Update Algorithm): Enhanced IGRP uses DUAL algorithm to Load: Load is based among many things, CPU usage, packets processed per sec
calculate the best route to a destination
For IGRP routing, you need to provide AS (Autonomous System) number in the command. Routers need AS number to exchange routing information.
Routers belonging to same AS exchange routing information.
OSPF is a link state technology that uses Dijkstra algorithm to compute routing 1. Use the address configured by the ospf router-id command The ip ospf priority command is
information. 2. Use the highest numbered IP address of a loopback used to set manually which router
interface becomes the DR. The range is 0-
3. Use the highest IP address of any physical interface 255 and the default is 1. 0 means it
An OSPF area is a collection of networks and routers that have the same area
4. If no interface exists, set the router-ID to 0.0.0.0 will never be DR or BDR.
identification.OSPF process identifier is locally significant.
When two or more routers are contending to be a DR (designated Router) on a network segment, the router with the highest OSPF priority will become the DR for that
segment. The same process is repeated for the BDR. In case of a tie, the router with the highest RID will win.
Standard Area : Default OSPF area type Internal Router : All interfaces reside within the same area
Stub Area : External link (type 5) LSAs are replaced with a default route Backbone Router : A router with an interface in area 0 (the backbone)
Totally Stubby Area : Type 3, 4, and 5 LSAs are replaced with a default route Area Border Router (ABR) : Connects two or more areas
Not So Stubby Area (NSSA) : A stub area containing an ASBR; type 5 LSAs are AS Boundary Router (ASBR) : Connects to additional routing domains; typically located in
converted to type 7 within the area the backbone
10
Cisco™ CCENT : NAT
Address Classification
Static NAT
Inside Local : An actual address assigned to an inside host
Maps an unregistered IP address to registered IP (globally unique) addresses on one-to-one basis.
Inside Global : An inside address seen from the outside
The command, ip nat inside source static <local ip> <global ip> configures address translation for
static NAT. Outside Global : An actual address assigned to an outside host
Maps an unregistered IP address to a registered (globally unique) IP address from a group of registered NAT Pool : A pool of IP addresses to be used as inside global or
(globally unique) IP addresses. outside local addresses in translations
The command, ip nat inside source list <access-list-number> pool <name>
is used to map the access-list to the IP NAT pool during the configuration of Dynamic NAT.
Overloading
Configuring NAT
A special case of dynamic NAT that maps multiple unregistered IP addresses to a single registered (globally
unique) IP address by using different port numbers.
Dynamic NAT with overloading is also known also as PAT (Port Address Translation). When configuring NAT, NAT should be enabled on at least
one inside and one outside interface.
Overlapping
1. The command for enabling NAT on inside interface is:
R1(config-if)#ip nat inside
This occurs when your internal IP addresses belong to global IP address range that belong to another
network.
2. The command for enabling NAT on the outside interface
is:
11
Cisco™ CCENT : Access-Lists
IP access lists are a sequential list of permit and deny conditions that apply to IP addresses or upper Wild card masking is used to permit or deny a group of addresses.
layer protocols. Access Control Lists are used in routers to identify and control traffic. For example, if we have a source address 185.54.13.2 and want all the
hosts on the last octet to be considered, we use a wild card mask,
185.54.13.255.
The 32 bit wildcard mask consists of 1’s and 0’s
1 = ignore this bit
Types of IP Access Lists 0 = check this bit
Purpose of Access Lists
1. Controlling traffic through a router, and Standard IP Access Lists Special Case: Host 185.54.13.2 is same as 185.54.13.2 with a wild card
2. Controlling VTY access to a router’s VTY Extended IP Access Lists mask of 0.0.0.0, considers only specified IP.
ports Named Access Lists Any is equivalent to saying 0.0.0.0 with a wild card mask of
3. Filter incoming and outgoing packets 255.255.255.255. This means none of the bits really matter. All IP
4. Restrict contents of routing updates addresses need to be considered for meeting the criteria.
5. Trigger dial-on-demand routing (DDR) calls
Standard Access List Extended Access Lists and Named Access Lists
1. These have the format, access-list [number] [permit or deny] [source_address] Extended Access lists have the format,
Ex: access-list 1 permit 192.168.2.0 0.0.0.255 access-list {number}{permit or deny} {protocol} {source}source-wildcard [operator
2. Place standard access lists as near the destination as possible and extended access lists [port]]{destination} destination-wildcard [operator [port]]
as close to the source as possible. With extended IP access lists, we can act on any of the following:
3. Access lists have an implicit deny at the end of them automatically. Because of this, an - Source address - Port information (WWW, DNS, FTP, etc.)
access list should have at least one permit statement in it; otherwise the access list will - Destination address
block all remaining traffic. - IP protocol (TCP, ICMP, UDP, etc.)
4. Access lists applied to interfaces default to outbound if no direction is specified. Ex: access-list 101 permit icmp host 192.168.3.2 any
Named Access lists have the format, ip access-list {standard /extended} name
Ex: ip access-list extended denyping
1-99: IP standard access list 100-199: IP extended access list 800-899: IPX standard access list
1000-1099: IPX SAP access list 1100-1199: Extended 48-bit MAC address access list 900-999: IPX extended access list
12
Cisco™ CCENT : VLANs and VTP
Creating VLANs
SW1#vlan database
Access Port configuration
SW1(vlan)#vtp mode (Server/Client/Transparent)
SW1#vlan database SW1(config-if)#switchport mode access
SW1(vlan)#vtp domain <name>
SW1(vlan)#vlan 10 name firstvlan SW1(config-if)#switchport access vlan 10 SW1(vlan)#vtp password <password>
SW1(vlan)#vlan 20 name secondvlan SW1(config-if)#switchport access vlan 20 SW1(vlan)#vtp pruning
Troubleshooting commands
Access port config to a range of interfaces Trunk Port configuration
13
Cisco™ CCENT : Configuration Commands
A. Setting Passwords
Sl. No. Task Commands
R1(config)#line console 0
1 Configure router console password as "ciscocs" R1(config-line)#login
R1(config-line)#password ciscocs
R1(config)#line vty 0 4
2 Configure router vty password as "ciscovty" R1(config-line)#login
R1(config-line)#password ciscovty
R1(config)#line aux 0
3 Configure router auxiliary password as "ciscoaux" R1(config-line)#login
R1(config-line)#password ciscoaux
4 Set the encrypted enable password as "cisco" R1(config)#enable secret cisco
7 Copy the startup-configuration to running-configuration (NVRAM to DRAM) R1#copy startup-config running-config (copy start run)
8 Copy the startup-configuration to a TFTP server R1#copy startup-config tftp (copy start tftp)
9 Copy the running-configuration to a TFTP server R1#copy running-config tftp (copy run tftp)
C. Routing Commands
R1(config)#router rip
12 Enable RIP version1 on all 192.168.x.x interfaces
R1(config-router)#network 192.168.0.0
R1(config)#router rip
13 Enable RIP version 2
R1(config-router)#version 2
14
Cisco™ CCENT : Show Commands
Router Show commands
Sl. No. Command Explanation
1. show access-list Displays all accesslists from all protocols present in a specified router.
2. show banner Displays the banner set on the router.
3. show cdp Shows the status of CDP such as holdtime value,no.of packets for every 60sec.
4. show cdp interface It tells the CDP configuration on an interface-by-interface basis.
5. show cdp neighbor|detail Displays info on directly connected neighbors.
6. show cdp traffic Displays the CDP traffic info.
7. show clock Displays the clock (time, date).
8. show flash Used to view all IOS images and file stored in flash(Default location of IOS images is in flash).
9. show history Shows the previously executed commands.IOS device stores the last ten commands that are executed.
10. show hosts Displays the host table.
11. show interfaces To view interfaces,status,and statistics for an interface.If u don't lists a specific interface,all of the interfaces on the router are listed.
12. show ip interfaces Displays status and global parameters associated with the interfaces on the router.
13. show ip interface brief Displays the interface operational status and IP addresses for all router interfaces.
14. show ip nat statistics Displays NAT statistics.
15. show ip nat translations Displays the NAT translations.
16. show ip route Displays the IP routing table.
17. show protocols Displays the routing protocols that have been configured and running on a specified router.
18. show running-config Shows the current config stored in RAM.
19. show sessions Shows the telnet sessions that are currently suspended.
20. show startup-config Shows the configuration stored in NVRAM.
21. show version Display version information for the hardware and firmware.
22. show arp Displays entries in the ARP table.
23. show ip protocols Displays parameters and current state of the active routing protocol process.
24. show users Displays users connected to the router.
15
Cisco™ CCENT : Show Commands
Switch Show commands
Sl. No. Command Explanation
1. show banner Displays the banner.
2. show flash Displays the file contents of the flash.
3. show history Displays the last 10 commands entered.
4. show interfaces To view interfaces,status,and statistics for an interface.
5. show interfaces vlan 1 Displays the VLAN status and the IP address of VLAN 1.
6. show ip interface brief Verifies the IP configuration.
7. show running-config Displays the config held in DRAM.
8. show startup-config Displays the NVRAM config.
9. show users Displays the users currently logged on.
10. show version Display IOS version information for the hardware and firmware.
11. show vlan Displays vlan information.
12. show vlan-membership Displays vlan membership information.
13. show mac-address-table Displays mac-address-table information.
14. show vtp status Displays vtp status information such as vtp mode, vtp domain etc.
16