Transcript Lans-4-wb

CS3502:
Data and Computer Networks
Local Area Networks - 4
Bridges / LAN internetworks
Bridges : connecting LANs together
 why
do we need to connect LANs
 what
is a bridge?
 types
of bridges
 routing
in LAN internetworks
 comparison:
bridges, routers, repeaters
 connecting
similar LANs
 connecting
dissimilar LANs
why LANs need to be connected
1. connect 2 existing LANs (CS, math)
-- different organizations want to be connected
2. LAN too big; need to split it, but stay connected
-- too many stations or traffic for one LAN
3. connect geographically separate LANs.
-- eg, 2 offices in different towns need connecting
4. reduce collisions
-- help increase efficiency
5. security
--help restrict traffic to one LAN
bridge : what is it?
 low
level “switch” that connects two or more
LANs. “low level” => “MAC layer”
 transparent
: there is no change in the LANs or in
the protocols of the networks
 must
be able to do simple routing
 retains
the simplicity and flexibility of the LANs
it connects
 faster
than “software” switches (routers)
 reasonable
cost; generally cheaper than routers
types of bridges and LAN connectors
 local
bridge
 remote
 same
(2 half bridges)
LAN, different LAN
 two
port, multiport
 hub
(not a bridge)
 repeater
(not a bridge)
 router(not
a bridge)
bridge : basic function
suppose a bridge B connects networks X and Y.
Then B :
1. reads all packets on X and Y, noting the
destination, source addresses (DA, SA)
2. each packet on Y with DA on Y is copied and
transmitted on X.
3. each packet on X with DA on Y is copied,
transmitted on Y.
 the
bridge operates on X, Y using the MAC
protocol of those LANs.
bridge connecting 2 ethernets
notes on bridges
 all
stations have unique MAC addresses
 bridge must “know” which LAN station is on
 multi-port bridges - similar; extends to multiple
LANs
 no change or adjustment in NIC needed; bridge
completely transparent
 bridge operates on each LAN using the MAC
protocol
 remote (half bridge) - may use another protocol
between the 2 half bridges, while using MAC on
each LAN
LAN internet
half - bridge, connecting 2 LANs
2
halves communicate through some other
protocol, eg, PPP, HDLC.
bridges - routing
 how
do bridges “know” which packets to
forward, and in which direction?
2 basic techniques :
1. fixed routing - the information is loaded
manually into the bridge (typing it in, etc.). This
info is then stored in a routing table.
2. dynamic routing: “learning bridges” the bridge “learns” where the stations are by
watching the traffic on its ports
bridges - routing
 for
fixed routing, many topologies possible
 dynamic routing - the internet must be
configured as a tree; this simplifies routing
 tree : LANs and bridges are the nodes, and the
links between them are the edges, and - LANs
can be connected only to bridges, not (directly)
to other LANs
 if
a cycle exists, the bridges will detect it and
remove one from the active network, so that a
tree structure is maintained
bridges - dynamic routing
 bridge
has a routing table, 3 fields :
[ dest.address | next port | time]
when bridge receives a packet [DA,SA] on port X:
1. if SA found in table, reset timer,
else add [SA, time, X ] to table
2. if [DA] found in table send packet out on next
port indicated; else send packet on all ports
except X.
bridge dynamic routing
 timer:
typical value : 300 seconds (why have the
timer? is this a good default value?)
 given
the tree structure, bridges will learn a
station’s direction (explain how?)
 MAC
addresses could be divided into (network,
station) parts. If so, tables can be made smaller,
but same algorithm applies
bridges, routers, repeaters, hubs
 repeaters
: simply connect 1 cable to another,
repeat the bits. No routing decisions or filtering.
 hubs : serve to extend the ethernet. No routing or
filtering of messages.
 bridges - connect LANs together at the MAC
layer; filter and rout messages at the MAC layer.
 routers - connect LANs to LANs and/or the
Internet. Layer 3/3.5 (internet). Software, IP
protocol. Considerably more “intelligent” than
above, but also in software so run slower. Usually
more expensive. Discussed in CS4550 ....