Beruflich Dokumente
Kultur Dokumente
4 – Switching Concepts
Routers
Switches, Bridges
Hub, Repeaters
• Ethernet networks used to be built using repeaters.
• When the performance of these networks began to suffer because too
many devices shared the same segment, network engineers added
bridges to create multiple collision domains.
• As networks grew in size and complexity, the bridge evolved into the
modern switch, allowing microsegmentation of the network.
• Today’s networks typically are built using switches and routers, often
with the routing and switching function in the same device.
Rick Graziani graziani@cabrillo.edu 5
Ethernet/802.3 LAN development
• Distance limitations
• Ethernet is fundamentally a shared technology where all users on a given LAN
segment compete for the same available bandwidth.
• This situation is analogous to a number of cars all trying to access a one-lane
road at the same time.
• Because the road has only one lane, only one car can access it at a time.
• The introduction of hubs into a network resulted in more users competing for
the same bandwidth.
• Collisions are a by-product of Ethernet networks.
• Transmission time equals the number of bits being sent times the bit
time for a given technology.
• Another way to think about transmission time is the time it takes a
frame to be transmitted.
• Small frames take a shorter amount of time. Large frames take a
longer amount of time.
• Each 10 Mbps Ethernet bit has a 100 ns transmission window.
– Therefore, 1 byte takes a minimum of 800 ns to transmit.
– A 64-byte frame, the smallest 10BASE-T frame allowing CSMA/CD
to function properly, takes 51,200 ns ( 51.2 microseconds).
– Transmission of an entire 1000-byte frame from the source station
requires 800 microseconds.
Rick Graziani graziani@cabrillo.edu 16
The benefits of using repeaters
3333 1111
Hey, that’s
Nop e me! Nop e
1111 222 2 333 3 nnnn Ab brevi ated
MAC
Ad dres ses
3333 1111
• Each NIC card compares its own MAC address with the Destination
MAC Address.
• If it matches, it copies in the rest of the frame.
• If it does NOT match, it ignores the rest of the frame.
– Unless you are running a Sniffer program
Rick Graziani graziani@cabrillo.edu 22
Sending and receiving Ethernet frames on a bus
Collision!
Noti ce the
loc ati on of
th e DA!
3333 1111
And as we said,
• When information (frame) is transmitted, every PC/NIC on the shared
media copies part of the transmitted frame to see if the destination
address matches the address of the NIC.
• If there is a match, the rest of the frame is copied
• If there is NOT a match the rest of the frame is ignored.
Rick Graziani graziani@cabrillo.edu 28
•
Sending and receiving Ethernet frames via a hub
3333 1111
111 1
• So, what does a hub do
? 222 2
when it receives
information?
• Remember, a hub is
nothing more than a
multiport repeater.
555 5
333 3 444 4
Rick Graziani graziani@cabrillo.edu 29
•
Sending and receiving Ethernet frames via a hub
Hub or
3333 1111
2222 1111
555 5
Nop e
Wa st ed
ban dwi dt h
Sourc e Ad dress T ab le
Port Source MAC Add. Port Source MAC Add.
333 3 111 1
Sourc e Ad dress T ab le
Port Source MAC Add. Port Source MAC Add.
1 1 111 333 3 111 1
111 1 3333
• Next, in our scenario, the
Abbreviated switch will flood the frame out
MAC
addresses
all other ports, because the DA
is not in the source address
2222 4444
table.
Rick Graziani graziani@cabrillo.edu 35
•
Destination Address in table, Filter
Sourc e Ad dress T ab le
Port Source MAC Add. Port Source MAC Add.
1 1 111 6 3 333 111 1 333 3
Sourc e Ad dress T ab le
Port Source MAC Add. Port Source MAC Add.
1 1 111 6 3 333 333 3 111 1
switch
111 1 333 3
switch
333 3 444 4
Sourc e Ad dress T ab le
Port Source MAC Add. Port Source MAC Add.
1 1 111 6 3 333 333 3 111 1
9 44 44
Co llis io n
switch Domai ns
333 3 444 4
Sourc e Ad dress T ab le
Port Source MAC Add. Port Source MAC Add.
1 1 111 6 3 333
9 44 44 • How long are addresses kept in the
Source Address Table?
switch – 5 minutes is common on most
vendor switches.
• How do computers know the
Destination MAC address?
• ARP Caches and ARP
Requests
• How many addresses can be kept
in the table?
111 1 3333 – Depends on the size of the
cache, but 1,024 addresses is
Abbreviated common.
MAC
addresses
• What about Layer 2 broadcasts?
– Layer 2 broadcasts (DA = all
2222 4444
1’s) is flooded out all ports.
Rick Graziani graziani@cabrillo.edu 40
Side Note - Transparent Bridging
3333
• Where is the
collision domain?
3333
Co llisi on Domai n
3333
(routing)
Cut-through
• Fast-forward – Offers the lowest level of latency.
– Fast-forward switching immediately forwards a packet after reading
the destination address.
– There may be times when packets are relayed with errors.
– Although this occurs infrequently and the destination network
adapter will discard the faulty packet upon receipt.
Cut-through
• Fragment-free – Fragment-free switching filters out collision fragments before
forwarding begins.
– Collision fragments are the majority of packet errors.
– In a properly functioning network, collision fragments must be smaller than
64 bytes.
– Anything greater than 64 bytes is a valid packet and is usually received
without error.
– Fragment-free switching waits until the packet is determined not to be a
collision fragment before forwarding.
• Adaptive cut-through
– In this mode, the switch uses cut-through until it detects
a given number of errors.
– Once the error threshold is reached, the switch changes
to store-and-forward mode.
“Learning bridges” or
Learning switches”
• If a switch has the frame’s destination address in its CAM table (or
Source Address Table) it will only send the frame out the appropriate
port.
• If a switch does not have the frame’s destination MAC address in its
CAM table, it floods (sends) it out all ports except for the incoming port
(the port that the frame came in on) known as an Unknown Unicast, or
if the destination MAC address is a broadcast.
• Note: A CAM table may contain multiple entries per port, if a hub or a
switch is attached to that port.
•RickMost Ethernet bridges can filter broadcast and multicast frames.
Graziani graziani@cabrillo.edu 57
Filter or Flood (Switch)
Hub Switch
switch
Co llisi on
Domai ns
• A switch employs
111 1 3333 “microsegmentation” to
reduce the collision
Abbreviated
MAC domain on a LAN.
addresses
2222 4444
• The switch does this by
creating dedicated network
segments, or point-to-point
connections.
S w itc h 1
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 6
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3 1 7 2 .3 0 .2 .1 2 S w itc h 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
•A l l ARP
S w i t c hRequest
e d N e tw o rk
T w o S u b n e ts
- T w o N e tw o rk s
1 7 2 .3 0 .1 .2 5
S e v e r a l C o llis io n D o m a in s 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 7
O n e p e r s w itc h p o r t 1 7 2 .3 0 .2 .1 4 2 5 5 .2 5 5 .2 5 5 .0
O n e B r o a d c a s t D o m a in 2 5 5 .2 5 5 .2 5 5 .0
• Even though the LAN switch reduces the size of collision domains, all
hosts connected to the switch are still in the same broadcast domain.
• Therefore, a broadcast from one node will still be seen by all the other
nodes connected through the LAN switch.
Rick Graziani graziani@cabrillo.edu 61
•
Switches and broadcast domains
Hubs to VLANs
Part 1
• Layer 1 devices
• Inexpensive
• In one port, out the others
• One collision domain
• One broadcast domain
Hub 1
1 7 2 .3 0 .1 .2 1 1 7 2 .3 0 .1 .2 4
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 2 1 7 2 .3 0 .1 .2 3
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
S in g le H u b
O n e N e tw o r k ( I P N e t w o r k A d d r e s s - u s u a lly )
O n e C o llis io n D o m a in
O n e B r o a d c a s t D o m a in
Hub 1
1 7 2 .3 0 .1 .2 1 1 7 2 .3 0 .2 .2 2
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
Hub 1
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 7
1 7 2 .3 0 .1 .2 3 Hub 2 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
A ll H u b s
1 7 2 .3 0 .1 .2 4
O ne N e tw o rk A d d re s s 2 5 5 .2 5 5 .2 5 5 .0
O ne C o llis io n D o m a in 1 7 2 .3 0 .1 .2 6
1 7 2 .3 0 .1 .2 5 2 5 5 .2 5 5 .2 5 5 .0
O ne B r o a d c a s t D o m a in 2 5 5 .2 5 5 .2 5 5 .0
• Layer 2 devices
• Layer 2 filtering based on Destination MAC addresses and
Source Address Table
• One collision domain per port
• One broadcast domain across all switches
Hub
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 7
1 7 2 .3 0 .1 .2 3 S w itc h 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
S w itc h a n d H u b N e tw o r k
1 7 2 .3 0 .1 .2 4
O n e N e tw o rk 2 5 5 .2 5 5 .2 5 5 .0
S e v e r a l C o llis io n D o m a in s 1 7 2 .3 0 .1 .2 6
1 7 2 .3 0 .1 .2 5 2 5 5 .2 5 5 .2 5 5 .0
O n e p e r s w it c h p o r t 2 5 5 .2 5 5 .2 5 5 .0
O n e fo r th e e n tir e H u b
O n e B r o a d c a s t D o m a in
Hub
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 7
1 7 2 .3 0 .1 .2 3 S w itc h 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
S w itc h a n d H u b N e tw o r k
1 7 2 .3 0 .1 .2 4
O n e N e tw o rk 2 5 5 .2 5 5 .2 5 5 .0
S e v e r a l C o llis io n D o m a in s 1 7 2 .3 0 .1 .2 6
1 7 2 .3 0 .1 .2 5 2 5 5 .2 5 5 .2 5 5 .0
O n e p e r s w it c h p o r t 2 5 5 .2 5 5 .2 5 5 .0
O n e fo r th e e n tir e H u b
O n e B r o a d c a s t D o m a in
Hub
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 7
1 7 2 .3 0 .1 .2 3 S w itc h 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
S w itc h a n d H u b N e tw o r k
1 7 2 .3 0 .1 .2 4
O n e N e tw o rk 2 5 5 .2 5 5 .2 5 5 .0
S e v e r a l C o llis io n D o m a in s 1 7 2 .3 0 .1 .2 6
1 7 2 .3 0 .1 .2 5 2 5 5 .2 5 5 .2 5 5 .0
O n e p e r s w it c h p o r t 2 5 5 .2 5 5 .2 5 5 .0
O n e fo r th e e n tir e H u b
O n e B r o a d c a s t D o m a in
Hub
Frames
1 7 2 .3 0 .1 .2 1 buffered
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 7
1 7 2 .3 0 .1 .2 3 S w itc h 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
S w itc h a n d H u b N e tw o r k
1 7 2 .3 0 .1 .2 4
O n e N e tw o rk 2 5 5 .2 5 5 .2 5 5 .0
S e v e r a l C o llis io n D o m a in s 1 7 2 .3 0 .1 .2 6
1 7 2 .3 0 .1 .2 5 2 5 5 .2 5 5 .2 5 5 .0
O n e p e r s w it c h p o r t 2 5 5 .2 5 5 .2 5 5 .0
O n e fo r th e e n tir e H u b
O n e B r o a d c a s t D o m a in
The switch keeps the frames in buffer memory, and queues the traffic for
the host 172.30.1.25.
This means that the sending hosts do not know about the collisions and do
not have to re-send the frames.
Rick Graziani graziani@cabrillo.edu 75
•
Other Switching Features
Review
• Asymmetric ports: 10 Mbps and 100 Mbps
• Full-duplex ports
• Cut-through versus Store-and-Forward switching
S w itc h 1
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 8
1 7 2 .3 0 .1 .2 2 1 7 2 .3 0 .1 .2 3 1 7 2 .3 0 .1 .2 4 S w itc h 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
A ll S w itc h e d N e tw o r k
1 7 2 .3 0 .1 .2 5
O n e N e tw o rk 2 5 5 .2 5 5 .2 5 5 .0
S e v e r a l C o llis io n D o m a in s 1 7 2 .3 0 .1 .2 7
1 7 2 .3 0 .1 .2 6 2 5 5 .2 5 5 .2 5 5 .0
O n e p e r s w itc h p o r t 2 5 5 .2 5 5 .2 5 5 .0
O n e B r o a d c a s t D o m a in
• Ports between switches and server ports are good candidates for
higher bandwidth ports (100 Mbps) and full-duplex ports.
• Most switch ports today are full-duplex.
Rick Graziani graziani@cabrillo.edu 77
• Introducing Multiple Subnets/Networks
without Routers
• Switches are Layer 2 devices
• Router are Layer 3 devices
• Data between subnets/networks must pass through a
router.
Switch 1
172.30.1.21
255.255.255.0
172.30.2.16
172.30.2.10 172.30.1.23 172.30.2.12 Switch 2 255.255.255.0
255.255.255.0 255.255.255.0 255.255.255.0
S w itc h 1
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 6
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3 1 7 2 .3 0 .2 .1 2 S w itc h 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
A ll S w itc h e d N e tw o r k - T w o N e tw o r k s
T w o S u b n e ts
1 7 2 .3 0 .1 .2 5
S e v e r a l C o llis io n D o m a in s 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 7
O n e p e r s w itc h p o r t 1 7 2 .3 0 .2 .1 4 2 5 5 .2 5 5 .2 5 5 .0
O n e B r o a d c a s t D o m a in 2 5 5 .2 5 5 .2 5 5 .0
• All devices see the ARP Request, even those on the other subnets that do not need to
see it.
• One broadcast domain means the switches flood all broadcast out all ports, except the
incoming port.
• Switches have no idea of the layer 3 information contained in the ARP Request.This
consumes bandwidth on the network and processing cycles on the hosts.
Rick Graziani graziani@cabrillo.edu 80
•
One Solution: Physically separate the subnets
S w itc h 1
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 6
1 7 2 .3 0 .1 .2 3 1 7 2 .3 0 .1 .2 5 1 7 2 .3 0 .1 .2 6 S w itc h 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
T w o S w itc h e d N e tw o r k s
T w o S u b n e ts
1 7 2 .3 0 .2 .1 0
S e v e r a l C o llis io n D o m a in s 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 4
O n e p e r s w itc h p o r t 1 7 2 .3 0 .2 .1 2 2 5 5 .2 5 5 .2 5 5 .0
T w o B r o a d c a s t D o m a in 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .1
2 5 5 .2 5 5 .2 5 5 .0
S w itc h 1 1 7 2 .3 0 .2 .1
1 7 2 .3 0 .1 .2 1
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
R o u te r
1 7 2 .3 0 .2 .1 6
1 7 2 .3 0 .1 .2 3 1 7 2 .3 0 .1 .2 5 1 7 2 .3 0 .1 .2 6 S w itc h 2 2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
R o u te d N e tw o rk s
T w o S u b n e ts
1 7 2 .3 0 .2 .1 0
S e v e r a l C o llis io n D o m a in s 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 4
O n e p e r s w itc h p o r t 1 7 2 .3 0 .2 .1 2 2 5 5 .2 5 5 .2 5 5 .0
C o m m u n ic a tio n b e tw e e n s u b n e ts 2 5 5 .2 5 5 .2 5 5 .0
ARP Request
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
R o u te d N e tw o rk s 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
T w o S u b n e ts
C o m m u n ic a tio n b e tw e e n s u b n e ts
• When a single interface is used to route between subnets or networks,
this is know as a router-on-a-stick.
• To assign multiple ip addresses to the same interface, secondary
addresses or subinterfaces are used.
Rick Graziani graziani@cabrillo.edu 84
•
Router-on-a-stick or One-Arm-Router (OAR)
interface e 0 1 7 2 .3 0 .1 .1
ip address 172.30.1.1 255.255.255.0 1 7 2 .3 0 .2 .1 s e c
ip address 172.30.2.1 255.255.255.0 secondary R o u te r 2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
R o u te d N e tw o rk s 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
Advantages T w o S u b n e t s
• Useful when C o m are
there m u limited
n i c a t i o Ethernet
n b e t w e interfaces
e n s u b n e on
t s the router.
Disadvantage
• Because a single link is used to connect multiple subnets, one link is having
to carry the traffic for multiple subnets.
• Be sure this is link can handle the traffic.
Rick Graziani graziani@cabrillo.edu 85
•
Router-on-a-stick or One-Arm-Router (OAR)
interface e 0 1 7 2 .3 0 .1 .1
ip address 172.30.1.1 255.255.255.0 1 7 2 .3 0 .2 .1 s e c
ip address 172.30.2.1 255.255.255.0 secondary R o u te r 2 5 5 .2 5 5 .2 5 5 .0
ARP Request
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
R o u te d N e tw o rk s 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
T w o S u b n e ts
C o m m u n ic a tio n b e tw e e n s u b n e ts
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
R o u te d N e tw o rk s 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
T w o S u b n e ts
C o m m u n ic a tio n b e tw e e n s u b n e ts
Remember to have the proper default gateway set for each host.
• 172.30.1.0 hosts - default gateway is 172.30.1.1
• 172.30.2.0 hosts - default gateway is 172.30.2.1
Rick Graziani graziani@cabrillo.edu 87
•
Interface for each subnet
1 7 2 . 3 0 . 1 . 1 E0 E1 1 7 2 . 3 0 . 2 . 1
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
R o u te r
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
R o u te d N e tw o rk s 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
T w o S u b n e ts
C o m m u n ic a t io n b e t w e e n s u b n e t s
• An Ethernet router interface per subnet may be used instead of one.
• However this may be difficult if you do not have enough Ethernet ports
on your router.
Rick Graziani graziani@cabrillo.edu 88
•
Still one broadcast domain
1 7 2 .3 0 .1 .1 1 7 2 .3 0 .2 .1
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
R o u te r
ARP Request
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
R o u te d N e tw o rk s 2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
T w o S u b n e ts
C o m m u n ic a t io n b e t w e e n s u b n e t s
• VLAN = Subnet
• VLANs create separate broadcast domains within the
switch.
• Routers are needed to pass information between different
VLANs
• This is only an introduction, as we will discuss VLANs
and Inter-VLAN Routing in later chapters.
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
VLAN 1
VLAN 2
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
VLAN 2 VLAN 1 123456. Port
121221. VLAN
Tw o VLANs
T w o S u b n e ts
• An ARP Request from 172.30.1.21 for 172.30.1.23 will only be seen by
hosts on that VLAN.
• The switch will flood broadcast traffic out only those ports belonging to
that particular VLAN, in this case VLAN 1.
Rick Graziani graziani@cabrillo.edu 91
•
Layer 2 Broadcast Segmentation
123456. Port
121221. VLAN
Port-centric VLAN Switches
• As the Network Administrator, it is your job to assign switch
ports to the proper VLAN.
• This assignment is only done at the switch and not at the
host.
• Note: The following diagrams show the VLAN below the
host, but it is actually assigned on the switch.
Rick Graziani graziani@cabrillo.edu 92
•
Without VLANs – No Broadcast Control
ARP Request
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
No VLANs
S a m e a s a s in g le V L A N
T w o S u b n e ts
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
VLAN 1
VLAN 2
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
VLAN 2 VLAN 1 123456. Port
121221. VLAN
Tw o VLANs
T w o S u b n e ts
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
VLAN 1
VLAN 2
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
VLAN 2 VLAN 1 123456. Port
121221. VLAN
1 7 2 .3 0 .1 .2 1
S w itc h 1
1 7 2 .3 0 .2 .1 2
2 5 5 .2 5 5 .2 5 5 .0
2 5 5 .2 5 5 .2 5 5 .0
VLAN 1
VLAN 2
1 7 2 .3 0 .2 .1 0 1 7 2 .3 0 .1 .2 3
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
VLAN 2 VLAN 1 123456. Port
121221. VLAN
Tw o VLANs
T w o S u b n e ts
• A switch cannot route data between different VLANs.
• Note: The host will not even send the Packet unless it has a
default gateway to forward it to.
Rick Graziani graziani@cabrillo.edu 96
•
Inter-VLAN Routing needs a Router
1 7 2 .3 0 .1 .1 1 7 2 .3 0 .2 .1
2 5 5 .2 5 5 .2 5 5 .0 2 5 5 .2 5 5 .2 5 5 .0
(V L A N 1 ) R o u te r (V L A N 2 )
123456. Port
121221. VLAN