chap 4 - inplementing inter-vlan routing

Upload: b0bsp4m

Post on 04-Jun-2018

247 views

Category:

Documents


2 download

TRANSCRIPT

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    1/16

    1Chapter 4

    Chapter 4 - Implementing Inter-VLAN RoutingObjectives

    Configure inter-VLAN routing on a router to enablecommunications between end-user devices onseparate VLANs

    Configure CEF-based Multi-layer switching

    Troubleshoot common inter-VLAN connectivityissues.

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    2/16

    2Chapter 4

    Inter-VLAN Routing

    Fa0/1

    S2

    PC1

    172.17.10.21/24(VLAN 10)

    Fa0/11

    PC2

    172.17.20.22/24(VLAN 20)

    PC3

    172.17.30.23/24(VLAN 30)

    Fa0/18

    S3 S1Fa0/1

    Fa0/6

    Fa0/2 Fa0/2

    Fa0/3

    Fa0/1

    Fa0/4Fa0/3Fa0/4

    Fa0/4

    Fa0/2 Fa0/3

    Inter-VLAN routing can be performedby connecting differentphysical routerinterfacesto different physical switchports.

    The switch ports connect to the router

    in access mode, and different staticVLANs are assigned to each portinterface.

    Each switch interface would be

    assigned to a different static VLAN.Each router interface can then accepttraffic from the VLAN associated withthe switch interface that it is connectedto, and traffic can be routed to theother VLANs connected to the other

    interfaces.

    R1Link to VLAN 20

    Link to VLAN 30

    Link to VLAN 10

    Computer Computer Computer

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    3/16

    3Chapter 4

    Router-on-a -Stick

    Fa0/1

    S2

    PC1

    172.17.10.21/24(VLAN 10)

    Fa0/11

    Computer

    PC2

    172.17.20.22/24(VLAN 20)

    Computer

    PC3

    172.17.30.23/24(VLAN 30)

    Fa0/18

    S3 S1Fa0/1

    Fa0/6

    Computer

    Fa0/2 Fa0/2

    Fa0/3

    Fa0/1

    Fa0/4Fa0/3Fa0/4

    Fa0/4

    Fa0/2 Fa0/3

    R1R1 - Fa0/0 Sub-interfaces

    Fa0/0.10 172.17.10.1 Default Gateway to VLAN 10

    Fa0/0.20 172.17.20.1 Default Gateway to VLAN 20

    Fa0/0.30 172.17.30.1 Default Gateway to VLAN 30

    Fa0/0

    "Router-on-a-stick" is a type of routerconfiguration in which a single physicalinterface routes traffic between multipleVLANs on a network.

    Sub-interfaces are configured fordifferent subnets corresponding to theirVLAN assignment to allow logical routingbefore data frames are VLAN taggedand sent back out the physical interface.

    Sub-interfaces are multiple virtualinterfaces, associated with onephysicalinterface. These sub-interfaces areconfigured with an IP address and VLANassignment to operate on a specific VLAN.

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    4/16

    4Chapter 4

    Fa0/1

    S2

    PC1

    172.17.10.21/24(VLAN 10)

    Fa0/11

    Computer

    PC2

    172.17.20.22/24(VLAN 20)

    Computer

    PC3

    172.17.30.23/24(VLAN 30)

    Fa0/18

    S3 S1Fa0/1

    Fa0/6

    Computer

    Fa0/2 Fa0/2

    Fa0/3

    Fa0/1

    Fa0/4Fa0/3Fa0/4

    Fa0/4

    Fa0/2 Fa0/3

    R1Fa0/0.10

    172.17.10.1/24

    Fa0/0.30

    172.17.30.1/24

    Configure Router Interfaces

    To avoid confusion, name the sub-interface after the VLAN to whichit is attached e.g. Fa0/0.10 isconnected to VLAN 10

    Fa0/5

    Sub-Interface Configuration

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    5/16

    5Chapter 4

    Sub-Interface Configuration

    Fa0/1

    S2

    PC1

    172.17.10.21/24(VLAN 10)

    Fa0/11

    Computer

    PC2

    172.17.20.22/24(VLAN 20)

    Computer

    PC3

    172.17.30.23/24(VLAN 30)

    Fa0/18

    S3 S1Fa0/1

    Fa0/6

    Computer

    Fa0/2 Fa0/2

    Fa0/3

    Fa0/1

    Fa0/4Fa0/3Fa0/4

    Fa0/4

    Fa0/2 Fa0/3

    R1Fa0/0.10

    172.17.10.1/24

    Fa0/0.30

    172.17.30.1/24

    Fa0/5

    S1 Fa0/5 must be configured

    as a trunkto allow it to carrytagged data from multiple

    VLANs

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    6/16

    6Chapter 4

    Interface and Sub-Interface Comparison

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    7/16

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    8/168Chapter 4

    Computer

    Computer

    Computer

    Computer

    Computer

    ManagementVLAN 99

    172.17.99.10/24

    StudentVLAN 20

    172.17.20.22/24

    StudentVLAN 20

    172.17.20.25/24

    GuestVLAN 30

    172.17.30.26/24

    GuestVLAN 30

    172.17.30.23/24

    Fa0/1

    Fa0/1 Fa0/3

    Fa0/3Fa0/18 Fa0/18

    Fa0/6 Fa0/6

    Connecting VLANs Using L3 Switch

    SVI VLAN20

    SVI VLAN30

    SVI VLAN99

    Layer 3 Switch

    Switch Virtual Interface(SVI) is a logical interface configured for a

    specific VLAN, and is used by layer 3 switches to route betweenVLANs or to provide IP host connectivity to a switch.

    A Layer 3 switch has theability to routetransmissions betweenVLANs.

    The process is the sameas when using a separaterouter, except that theSVIs act as the routerinterfaces for routing thedata between VLANs.

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    9/169Chapter 4

    Layer-3 Switch SVI Configuration

    Fa0/1

    S2

    PC1

    172.17.10.21/24(VLAN 10)

    Fa0/11

    Computer

    PC2

    172.17.20.22/24(VLAN 20)

    Computer

    PC3

    172.17.30.23/24(VLAN 30)

    Fa0/18

    S3 S1Fa0/1

    Fa0/6

    Computer

    Fa0/2 Fa0/2

    Fa0/3

    Fa0/1

    Fa0/4Fa0/3Fa0/4

    Fa0/4

    Fa0/2 Fa0/3

    S1(config)#int vlan 10S1(config-if)#ip add 172.17.10.1 255.255.255.0S1(config-if)#int vlan 20S1(config-if)#ip add 172.17.20.1 255.255.255.0S1(config-if)#int vlan 30S1(config-if)#ip add 172.17.30.1 255.255.255.0

    S1(config)#ip routingS1(config)#exitS1#sh ip route

    172.17.0.0/24 is subnetted, 3 subnetsC 172.17.10.0 is directly connected, Vlan10C 172.17.20.0 is directly connected, Vlan20C 172.17.30.0 is directly connected, Vlan30

    Configure SVI Addresses:

    Configure Routing:

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    10/1610Chapter 4

    Layer-3 Switch Routed Port Configuration

    Fa0/1

    S2

    PC1

    172.17.10.21/24(VLAN 10)

    Fa0/11

    Computer

    PC2

    172.17.20.22/24(VLAN 20)

    Computer

    PC3

    172.17.30.23/24(VLAN 30)

    Fa0/18

    S3 S1Fa0/1

    Fa0/6

    Computer

    Fa0/2 Fa0/2

    Fa0/3

    Fa0/1

    Fa0/4Fa0/3Fa0/4

    Fa0/4

    Fa0/2 Fa0/3

    Configure Routed Port:

    Fa0/0172.17.40.1/30

    R1Fa0/5

    172.17.40.2/30

    S1(config)#int fa0/5S1(config-if)#no switchport

    S1(config-if)#ip add 172.17.40.2 255.255.255.0S1(config-if)#no shS1(config-if)#exitS1(config)#router eigrp 1S1(config-router)#network 172.17.40.0 0.0.0.3

    A routed port has the following characteristics and functions:

    Physical switch port with Layer 3 capabilityNot associated with any VLANServes as the default gateway for devices out that switch portLayer 2 port functionality must be removed before it can beconfigured

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    11/1611Chapter 4

    Layer 3 Switch Processing

    Layer 3 switching software employs

    a distributed architecture in whichthe control pathand data patharerelatively independent.

    The control path code, such asrouting protocols, runs on the route

    processor, whereas most of the datapackets are forwarded by theEthernet interface module and theswitching fabric.

    Layer 3 switching uses one of these two methods, depending on the platform:

    Route caching:Also known as flow-based or demand-based switching, a Layer 3route cache is built in hardware, since the switch seestraffic flow into theswitch.

    Topology-based:Information from the routing table is used to populate the routecache regardless of traffic flow. The populated route cache is called the

    forwarding information base (FIB). CEF builds the FIB.

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    12/1612Chapter 4

    Multilayer Switch Packet Forwarding Process

    CEF expediently switches data packets to their destination.It cachesinformation generated by the Layer 3 routingengine.

    CEF caches routing information in the ForwardingInformation Base(FIB), and caches Layer 2 next-hopaddresses for all FIB entries in an adjacency table.

    Because CEF maintains multiple tables for forwarding

    information, parallel paths can exist and enable CEF to loadbalance per packet.

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    13/1613Chapter 4

    When traffic cannot be processed in hardware, the traffic

    must receive processing in software by the Layer 3 engine. Anumber of different packet types may force the Layer 3engine to process them:

    1. IP packets that use IP header options. (Packets that useTCP header options are switched in hardware because

    they do not affect the forwarding decision.)2. Packets that have an expiring IP Time to Live (TTL)

    counter.3. Packets that are forwarded to a tunnel interface.4. Packets that arrive with non-supported encapsulation

    types.5. Packets that are routed to an interface with non-

    supported encapsulation types.6. Packets that exceed the maximum transmission unit

    (MTU) of an output interface and must be fragmented.

    Multilayer Switch Packet Forwarding Process

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    14/1614Chapter 4

    CEF Based MLS switching

    ARP x 1

    ARP Throttling (2 seconds)

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    15/1615Chapter 4

    Configure & Verify CEF

    If CEF is enabled globally, it is automatically enabled on all interfaces aslong as IP routing is enabled on the device.

    CEF can be enabled/disabled on a per interface basis.

    Cisco recommends that CEF be enabled on all Layer 3 interfaces.

    Configure CEF:

    S1 (conf)#ip cefS1 (conf-if)#ip route-cache cef

    Verify CEF:

    S1#sh ip cefS1#sh ip cef fa0/1 detailS1#sh adjacency fa0/1 detailS1#show ip cef summaryS1#show ip cef vlan 10

  • 8/13/2019 Chap 4 - Inplementing Inter-VLAN Routing

    16/1616Chapter 4

    Any

    Questions?