switching and routing concepts and configurations

32
Switching and Routing Concepts and Configurations Topic 1: IPv4 Addressing (2hrs) Addressing -is a key function of Network layer protocols that enables data communication between hosts on the same network or on different networks. Internet Protocol version 4 (IPv4) -provides hierarchical addressing for packets that carry our data. Anatomy of an IPv4 Addresses Three types of addresses: Network address - The address by which we refer to the network. Broadcast address - A special address used to send data to all hosts in the network. Host addresses - The addresses assigned to the end devices in the network. 1

Upload: ednabelegal

Post on 06-May-2017

224 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Switching and Routing Concepts and Configurations

Switching and Routing Concepts and Configurations

Topic 1: IPv4 Addressing (2hrs)Addressing -is a key function of Network layer protocols that enables data communication between hosts on the same network or on different networks.

Internet Protocol version 4 (IPv4) -provides hierarchical addressing for packets that carry our data.

Anatomy of an IPv4 Addresses

Three types of addresses:

Network address - The address by which we refer to the network.

Broadcast address - A special address used to send data to all hosts in the network.

Host addresses - The addresses assigned to the end devices in the network.

1

Page 2: Switching and Routing Concepts and Configurations

Calculating Host, Network Address and Broadcast Address

1.

2.

3.

4.

5.

2

Page 3: Switching and Routing Concepts and Configurations

Reserved IPv4 Ranges

Legacy IPv4 Addressing

Public and Private Addressing

Public address- designed to be used in the hosts that are publicly accessible from the Internet. It is the address assigned by the ISP.

Private Address- address that are used in networks that require limited or no Internet access.

The private address blocks are:

10.0.0.0 to 10.255.255.255 (10.0.0.0 /8)

172.16.0.0 to 172.31.255.255 (172.16.0.0 /12)

192.168.0.0 to 192.168.255.255 (192.168.0.0 /16)

3

Page 4: Switching and Routing Concepts and Configurations

Activity: Classify whether the given IP is public or private.

Planning to Address the Network

The allocation of these addresses inside the networks should be planned and documented for the purpose of:

1. Preventing duplication of addresses

2. Providing and controlling access

3. Monitoring security and performance

Static or Dynamic Addressing

Static Address- the network administrator must manually configure the network information for a host. They are useful for printers, servers, and other networking devices that need to be accessible to clients on the network. When using static IP addressing, it is necessary to maintain an accurate list of the IP address assigned to each device. These are permanent addresses and are not normally reused.

Dynamic Address- address provided by a DHCP server. DHCP enables the automatic assignment of addressing information such as IP address, subnet mask, default gateway, and other configuration information. DHCP is generally the preferred method of assigning IP addresses to hosts on large networks because it reduces the burden on network support staff and virtually eliminates entry errors.

Subnet Mask – The subnet mask is created by placing a binary 1 in each bit position that represents the network portion and placing a binary 0 in each bit

4

Page 5: Switching and Routing Concepts and Configurations

position that represents the host portion. We express the subnet mask in the same dotted decimal format as the IPv4 address.

Prefix length - the number of bits in the address giving us the network portion. The prefix is a way to define the network portion that is human readable. The data network must also have this network portion of the addresses defined.

The prefix and the subnet mask are different ways of representing the same thing - the network portion of an address.

Calculating the Address

Subnetting- allows for creating multiple logical networks from a single address block.

2 ways of Subnetting

1. Subnetting according to the number of required networks (known as standard subnetting)

- inefficient and wasteful

Note: To subnet using standard subnetting we have to learn how to count networks based on the given topology.

Every end of a router is a network.

Switch creates network.

Example 1:

Given: 192.168.1.0/24

5

Page 6: Switching and Routing Concepts and Configurations

Example 2:

Given: 192.168.1.0/24

2. Subnetting according to the number of required hosts. Also known as Classless Addressing or VLSM (Variable Length Subnet Mask)

- Subnetting a subnet

In the figure below, we will look at addressing from another view. We will consider subnetting based on the number of hosts, including router interfaces and WAN connections. This scenario has the following requirements:

SydneyHQ 10 host addressesCorpusHQ 10 host addressesPerthHQ 26 host addressesAtlantaHQ 58 host addressesWAN links 2 host addresses (each)

6

Page 7: Switching and Routing Concepts and Configurations

Given: 192.168.15.0 /24

Results of VLSM Calculation

7

Page 8: Switching and Routing Concepts and Configurations

Switching and Routing Concepts and Configurations

Topic 2: Basic Routing Configurations (2hrs)Router as a Computer

Router components and their functions”

Cisco Internetwork Operating System (IOS) -is the system software in Cisco devices. It is the core technology that extends across most of the Cisco product line. The Cisco IOS is used for most Cisco devices regardless of the size and type of the device. It is used for routers, LAN switches, small Wireless Access Points, large routers with dozens of interfaces, and many other devices.

The Cisco IOS provides devices with the following network services:

-Basic routing and switching functions

-Reliable and secure access to networked resources

- Network scalability

CPU - Executes operating system instructions

Random access memory (RAM) - Contains the running copy of configuration file. Stores routing table. RAM contents lost when power is off

Read-only memory (ROM) - Holds diagnostic software used when router is powered up. Stores the router’s bootstrap program.

Non-volatile RAM (NVRAM) - Stores startup configuration. This may include IP addresses (Routing protocol, Hostname of router)

Flash memory - Contains the operating system (Cisco IOS)

Interfaces - There exist multiple physical interfaces that are used to connect network. Examples of interface types:

-Ethernet / fast Ethernet interfaces

-Serial interfaces

-Management interfaces

8

Page 9: Switching and Routing Concepts and Configurations

Router Interface is a physical connector that enables a router to send or receive packets

Each interface connects to a separate network

Consist of socket or jack found on the outside of a router

Types of router interfaces:

-Ethernet-Fastethernet -Serial-DSL-ISDN-Cable

Front View of a router

9

Page 10: Switching and Routing Concepts and Configurations

Rear View of a Router

Two major groups of Router Interfaces

LAN Interfaces:

Are used to connect router to LAN network

Has a layer 2 MAC address

Can be assigned a Layer 3 IP address

Usually consist of an RJ-45 jack

10

Page 11: Switching and Routing Concepts and Configurations

WAN Interfaces

Are used to connect routers to external networks that interconnect LANs.

Depending on the WAN technology, a layer 2 address may be used.

Uses a layer 3 IP address

How to Configure a Switch or a Router?

Note:

To configure a real switch or router; you need a console cable; composed of RJ45 connector on one end and serial interface on other end.

RJ45connector to be connected to a console port of a router or switch then serial interface of the console cable to be connected to the serial port of a PC.

To access the command line interface of a router or switch, you need to install hyperterminal or putty on your PC.

11

Page 12: Switching and Routing Concepts and Configurations

2 major types of network

1. Local area network (LAN)-connect workstations, peripherals, terminals, and other devices in a single building or other geographically limited area.

2. Wide area network (WAN)- Data Communications network that serves users across a broad geographic area and often uses transmission devices provided by common carriers.

Configure Devices and Apply Addresses

Implementing Basic Addressing Schemes

When designing a new network or mapping an existing network you must provide the following information in the form of a document:

-Topology drawing that Illustrates physical connectivity

- Connections of a Router for Ethernet

2 types of connectors can be used: Straight through and Cross-over

Straight through used to connect:

-Switch-to-Router, Switch-to-PC, Router-to-Server, Hub-to-PC, Hub-to-Server

Cross-over used to connect:

-Switch-to-Switch, PC-to-PC, Switch-to-Hub, Hub-to-Hub, Router-to-Router

- Address table that provides the following information:

Device name

Interfaces used

IP addresses

Default gateway

Basic Router Configuration

12

Page 13: Switching and Routing Concepts and Configurations

A basic router configuration should contain the following:

-Router name - Host name should be unique

-Banner - At a minimum, banner should warn against unauthorized use

-Passwords - Use strong passwords

-Interface configurations - Specify interface type, IP address and subnet mask. Describe purpose of interface. Issue no shutdown command. If DCE serial interface issue clock rate command.

After entering in the basic configuration the following tasks should be completed

-Verify basic configuration and router operations.

-Save the changes on a router

13

Page 14: Switching and Routing Concepts and Configurations

Verify Basic Router Configuration

-Issue the show running-config command

-Save the basic router configuration by Issuing the copy running-config startup-config command

-Additional commands that will enable you to further verify router configuration are:

Show running-config - Displays configuration currently in RAM

Show startup-config - Displays configuration file NVRAM

Show IP route - Displays routing table

Show interfaces - Displays all interface configurations

Show IP int brief - Displays abbreviated interface configuration information

Note: See attached activity LAB 1.5.2 Basic Router Configuration for the details of the commands for configuring a Router.

14

Page 15: Switching and Routing Concepts and Configurations

Routing Table Structure

Routing Table is stored in ram and contains information about:

Directly connected networks - this occurs when a device is connected to another router interface

Remotely connected networks - this is a network that is not directly connected to a particular router

Detailed information about the networks include source of information, network address & subnet mask, and Ip address of next-hop router

Show ip route command is used to view a routing table

Adding a connected network to the routing table

-Router interfaces

Each router interface is a member of a different network

Activated using the no shutdown command

In order for static and dynamic routes to exist in routing table you must have directly connected networks

Static routes in the routing table

-Includes: network address and subnet mask and IP address of next hop router or exit interface

-Denoted with the code S in the routing table

-Routing tables must contain directly connected networks used to connect remote networks before static or dynamic routing can be used

15

Page 16: Switching and Routing Concepts and Configurations

When to use static routes

-When network only consists of a few routers

-Network is connected to internet only through one ISP

-Hub & spoke topology is used on a large network

Connected and Static routes

Dynamic routing protocols

-Used to add remote networks to a routing table

-Are used to discover networks

-Are used to update and maintain routing tables

Automatic network discovery

-Routers are able discover new networks by sharing routing table information

Maintaining routing tables

-Dynamic routing protocols are used to share routing information with other router & to maintain and update their own routing table.

IP routing protocols. Example of routing protocols include:

-RIPv1

-RIPv216

Page 17: Switching and Routing Concepts and Configurations

-EIGRP

-OSPF

Static Routing

Functions of a Router

-Best Path Selections

-Forwarding packets to destination

Interfaces

Examining Router Interfaces

-Physically connecting a WAN Interface.

-A WAN Physical Layer connection has sides:

Data Circuit-terminating Equipment (DCE) – This is the service provider. CSU/DSU is a DCE device. This is the interface where you set the clock rate.

Data Terminal Equipment (DTE) – Typically the router is the DTE device.

Static Routes with Exit Interfaces

Purpose of a static route

A manually configured route used when routing from a network to a stub network

IP route command

To configure a static route use the following command: ip route

17

Page 18: Switching and Routing Concepts and Configurations

Example:

-Router(config)# ip route network-address subnet-mask {ip-address | exit-interface }

Dissecting static route syntax

ip route - Static route command

172.16.1.0 – Destination network address

255.255.255.0 - Subnet mask of destination network

172.16.2.2 - Serial 0/0/0 interface IP address on R2, which is the "next-hop" to this network

Configuring routes to 2 or more remote networks18

Page 19: Switching and Routing Concepts and Configurations

Use the following commands for R1

-R1(config)#ip route 192.168.1.0 255.255.255.0 172.16.2.2

-R1(config)#ip route 192.168.2.0 255.255.255.0 172.16.2.2

Modifying Static routes

Existing static routes cannot be modified. The old static route must be deleted by placing no in front of the ip route

Example:

-no ip route 192.168.2.0 255.255.255.0 172.16.2.2

A new static route must be rewritten in the configuration

Note: See attached activity LAB 2.8.1 Basic Static RouteConfiguration for the details of the commands for configuring Static Route.

Switching and Routing Concepts and Configurations

19

Page 20: Switching and Routing Concepts and Configurations

Topic 3: Local Area Network Design (2hrs) 2 types of Switch

1. manageable switch- switch with console port

- configurable and plug&play

2. unmanageable switch- plug&play

LAN Design

-Process that explains how a LAN is to be implemented

-Factors to consider in LAN design include

Collision domains-the network area within which frames that have collided are propagated. Repeaters and hubs propagate collisions: LAN switches, bridges and routers do not.

Broadcast domains- the set of all devices that will receive broadcast frames originating from any device within the set.

Network latency- time a frame or a packet takes to travel from the source station to the final destination.

Sources of Latency

1. Time it takes the source NIC to place voltage pulses on the wire, and the time it takes the destination NIC to interpret these pulses.

2. Actual propagation delay as the signal takes time to travel through the cable.

3. Number of network devices that are in the path between two devices. Each device in the path introduces latency.

-The predominant cause of network latency in a switched LAN is more a type of the media being transmitted, routing protocols used, and types of applications running on the network.

LAN segmentation-The primary reason for segmenting a LAN into smaller parts is to isolate traffic and to achieve better use of bandwidth per user. Without segmentation, a LAN quickly becomes clogged with traffic and collisions. LANs are segmented into a number of smaller collision and broadcast domains using routers and switches.

How to count Broadcast Domain and Collision Domain

Note:

20

Page 21: Switching and Routing Concepts and Configurations

Switch is one big broadcast domain.

Every port of a switch is collision domain.

Hub is one big collision domain.

Example 1: 4 Broadcast Domain and 11 Collision Domain

Example 2:

Traditional LAN vs. Virtual Local Area Network (VLAN)

• In traditional switched LANs, the physical topology is closely related to the logical topology.

• Generally, workstations must be grouped by their physical proximity to a switch.

• To communicate among LANs, each segment must have a separate port on the backbone device or a connection to a common backbone.

21

Page 22: Switching and Routing Concepts and Configurations

Defining VLANs

• VLANs provide segmentation based on broadcast domains.

• VLANs logically segment switched networks based on the functions, project teams, or applications of the organization regardless of the physical location or connections to the network.

• Communication among VLANs still require a router. BUT, only one physical connection will handle all routing.

22

Page 23: Switching and Routing Concepts and Configurations

• VLANs are created to provide segmentation services traditionally provided by physical routers in LAN configurations.

• They address:

• Scalability

• Security

• Network Management

• Broadcast Filtering

• Traffic Flow Management

• Switches may not forward any traffic between VLANs, as this would violate the integrity of the VLAN broadcast domain.

• Traffic must be routed between VLANs.

• A VLAN, then, is a broadcast domain (IP Subnet) created by one or more switches.

• A VLAN allows:

• Creation of groups of logically networked devices.

23

Page 24: Switching and Routing Concepts and Configurations

• The devices to act as if they are on their own independent network.

• The devices can share a common infrastructure.

• Each VLAN is a separate broadcast domain.

• Broadcast traffic is controlled.

• Each VLAN is a separate IP subnet.

• To communicate among VLANs, you must use a router.

Benefits of VLANs

• Security:

• Groups with specific security needs are isolated from the rest of the network.

• Cost Reduction:

• Need for expensive hardware upgrades is reduced.

• Better use of existing bandwidth and links.

• Higher Performance:

• Dividing large, flat Layer 2 networks into separate broadcast domains reduces unnecessary traffic on each new subnet.

• Broadcast Storm Mitigation:

• Dividing a network into VLANs prevents a broadcast storm from propagating to the whole network.

• Improved IT Staff Efficiency:

• Easier to manage the network because users with similar network requirements share the same VLAN.

• Simpler Project or Application Management:

• Having separate functions makes working with a specialized application easier. For example, ane-learning development platform for faculty.

VLAN ID Ranges

• When configured, the number that is assigned to the VLAN becomes the VLAN ID.

• The numbers to be assigned are divided into two different ranges:

• Normal Range: 1 – 1005

• Extended Range: 1006 - 4096

• Each range has its own characteristics.

24

Page 25: Switching and Routing Concepts and Configurations

Types of VLANs

• Defined by the type of traffic they support or by the functions they perform.

• Data VLAN- Configured to carry only user-generated traffic.

• Default VLAN-The default VLAN for Cisco switches is VLAN 1.

• Native VLAN-carries untagged traffic.

• Management VLAN- in order for you to access a switch remotely you need to configure a management VLAN. In the sample activity VLAN 99 is used as the management VLAN. You can only assign an IP address to a switch through a management VLAN.

• Voice VLAN-is designed to carry voice traffic.

Configuring VLANs:

• Must assign a VLAN number.

• Can configure a port specifying to what VLAN it belongs

• Configure Trunk port and access port

- An interface should be configured as trunk port if the port of a switch is connected to a port of another switch.

Command:

Switch(config)#int fa0/1 Switch(config-if) #switchport mode trunk Switch(config-if) #switchport trunk native vlan 99

Note: All trunk port must be configured with the same native vlan on all interconnected switches.

25

Page 26: Switching and Routing Concepts and Configurations

- An interface should be configured as access port if the port of a switch is connected to end devices such as PC.

Command:

Switch(config)#int fa0/11Switch(config-if) #switchport mode access

Switch(config-if) # switchport access vlan 10 – this command is used to assign port to specific VLANs

Note: See attached activity LAB 3.5.1 Basic VLAN Configuration for the details of the commands for configuring VLAN.

Introducing Inter-VLAN Routing

• What is Inter-VLAN Routing?

• Each VLAN is a unique broadcast domain.

• Computers on separate VLANs are, by default, not able to communicate.

• Each VLAN is a unique IP subnetwork.

• To allow VLANs to communicate, we need a router to communicate among separate broadcast domains and unique IP subnetworks.

• Inter-VLAN routing, then, is a process of forwarding traffic from one VLAN to another VLAN using a router.

Methods:

• Traditional Inter-VLAN Routing.

• Router-on-a-stick Inter-VLAN Routing.

• Switch Based Inter-VLAN Routing.

• Router-on-a-stick Inter-VLAN Routing:

• Subinterfaces:

• Overcomes the hardware limitation of a router.

• Subinterfaces are software-based virtual interfaces that are assigned to physical interfaces.

• Each subinterface is configured with its own IP address, subnet mask, and unique VLAN assignment.

• Connected to a switch trunk link.

• Functionally the same as using the traditional routing model.

• Router-on-a-stick Inter-VLAN Routing:

26

Page 27: Switching and Routing Concepts and Configurations

Configuring Subinterfaces:

• Similar to configuring physical interfaces.

• Create the subinterface.

• Assign it to a VLAN.

• Assign an IP Address.

• Enable the interface.

• Router-on-a-stick Inter-VLAN Routing:

• Create the subinterface:

• The syntax for the subinterface is always the physical interface, followed by a period and a subinterface number.

• The subinterface number is configurable, but it is typically associated to reflect the VLAN number.

R1(config)#interface [interface].nn

NOTE: The management VLAN must also be configured if you wish to use it on multiple switches that are not directly connected by trunk links.

• Assign it to a VLAN:

• Before assigning an IP Address, the interface must to be configured to operate on a specific VLAN using the proper encapsulation.

R1(config-subif)#encapsulation dot1q vlan-id

• Assign an IP Address:

• The IP Address assigned here will become the default gateway for that VLAN.

R1(config-subif)#ip address [address] [mask]

• Enable the interface:

• Subinterfaces are not enabled individually.

• When the physical interface is enabled, all associated subinterfaces are enabled.

R1(config-if)#no shutdown

27

Page 28: Switching and Routing Concepts and Configurations

Note: See attached activity LAB 6.4.1 Inter-VLAN Configuration for the details of the commands for configuring Inter-VLAN.

Thank you!!!Hope You Learned!!!

28

Page 29: Switching and Routing Concepts and Configurations

29