Sample Elements of Computer Networking

Embed Size (px)

Citation preview

  • 8/20/2019 Sample Elements of Computer Networking

    1/34

    Elements of Computer Networking Networking Devices

    4.1 Glossary 77

    NetworkingDevices

    Chapter 

    4

    4.1 Glossary

      : Network segments that typically use the same communication protocoluse bridges to pass information from one network segment to the other.

      : When different communications protocols are used by networks,gateways are used to convert the data from the sender’s

      :Another name for a hub is a concentrator. Hubs reside in the core of theLAN cabling system. The hub connects workstations and sends everytransmission to all the connected workstations.

         : A MDA is a plug-in module allowing selection amongfiber-optic, twisted pair, and coaxial cable.

        : When the electrical characteristics of various networks aredifferent, media filter adapter connectors make the connections possible.

         : MAUs are special concentrators or hubs for use in Token Ring networks instead of Ethernet networks.

      : Modem is a device that  digital signals to analog signals andanalog signals to digital signals.

        :NICs are printed circuit boards that are installed incomputer workstations. They provide the physical connection and circuitryrequired to access the network.

      : Connectivity device used to regenerate and amplify weak signals,thus extending the length of the network. Repeaters perform no other actionon the data.

      : Links two or more networks together, such as an Internet Protocolnetwork. A router receives packets and selects the optimum path to forwardthe packets to other networks.

      ℎ: A connection device in a network that functions much like a bridge,but directs transmissions to specific workstations rather than forwarding datato all workstations on the network.

      : The name transceiver is derived from the combination of thewords transmitter and receiver. It is a device that both transmits and receives

    signals and connects a computer to the network. A transceiver may beexternal or located internally on the NIC.

  • 8/20/2019 Sample Elements of Computer Networking

    2/34

    Elements of Computer Networking Networking Devices

    4.2 End Devices 78

      : Firewall provides controlled data access. Firewalls can be hardwareor software based and between networks. These are an essential part of anetwork’s security strategy. 

    4.2 End DevicesIn computer networks, the computers that we use on a daily basis are called  (also called ℎ  or end systems). They are called ℎ  because they host theapplication-level programs such as a Web browser or an electronic-mail program.

    Sometimes, they are also called as   because they sit at the edge of thenetwork connection. A node can be a computer or some other device, such as aprinter. Every node has a unique network address, sometimes called a    (DLC) address or     (MAC) address.

    An end device acts as the source (i.e., generates and sends messages) or as thedestination (i.e., receives and consumes content) of the communication process.

    In modern networks, a host can act as a client, a server, or both. Software installed onthe host determines which role it plays on the network. Servers are hosts that havesoftware installed that enables them to provide information and services, like e-mail orweb pages, to other hosts on the network.

    Some examples of end devices are:

      Computers, laptops, file servers, web servers.

      Network printers

      VoIP phones

      Security cameras

      Mobile handheld devices

    4.3 Intermediary DevicesIn addition to the end devices that people are familiar with, computer networksdepends on intermediary devices to provide connectivity. These intermediary deviceswork behind the scenes to ensure that data flows across the network. Also, theyconnect the individual systems to the network and can connect multiple individualnetworks to form an   (also called ). Examples of intermediarynetwork devices are:

      Network Access Devices (hubs, switches, and wireless access points)

      Internetworking Devices ()

      Communication Servers and Modems  Security Devices ( )

     The management of data as it flows through the network is also a role of theintermediary devices. These devices use the destination host address, along withinformation about the network interconnections, to determine the path that messagesshould take through the network. Processes running on the intermediary networkdevices perform these functions:

      Regenerate and retransmit data signals

      Maintain information about what pathways exist through the network and

    internetwork

      Notify other devices of errors and communication failures

      Direct data along alternate pathways when there is a link failure

      Classify and direct messages according to priorities

  • 8/20/2019 Sample Elements of Computer Networking

    3/34

    Elements of Computer Networking Networking Devices

    4.3 Intermediary Devices 79

      Permit or deny the flow of data, based on security settings

     The intermediate devices can be further classified by on their functionality as:

       : Connectivity devices are devices used to make physicalnetwork connections. They do   ℎ to the data or transmission

    route. Connectivity devices operate at the physical layer of the OSI model.   : Internetworking devices move data across a network.

     They  data to specific locations within the network and/or  datainto alternative formats. Internetworking devices operate at OSI layers abovethe physical layer.

    4.4 Connectivity Devices 

    4.4.1 Introduction

    Connectivity devices are those devices used to make physical network connections.

    Connectivity devices operate at the physical layer of the Open Systems InterconnectionReference Model (OSI) model. The OSI model describes how computer services andprocedures are standardized.

     This standardization allows computers to share information and enables theinterconnection of various networking connectivity devices regardless of vendor.

    4.4.2 Network Interface Cards

    A    is a piece of computer hardware and its main functionality isto allow a computer to connect to a network. A network interface card is also calledLAN ,  ,   ,    or simply .

    Regardless of the name, they enable computers to communicate across a network.With this device, information packets can be transferred back and forth through alocal area network (LAN). It acts a communication source for sending and receivingdata on the network.

    NIC provides physical access to a networking medium and often provides a low-leveladdressing system through the use of MAC addresses. It allows users to connect toeach other either by using  or .

     The network interface card (NIC) is an add-on component for a computer, much like avideo card or sound card is. On most of the systems the NIC is integrated into the

    system board. On others it has to be installed into an expansion slot.

    Most network interface cards have the ℎ protocol as the language of the datathat is being transferred back and forth. However, network interface cards do not all

  • 8/20/2019 Sample Elements of Computer Networking

    4/34

    Elements of Computer Networking Networking Devices

    4.3 Intermediary Devices 80

    necessarily need physical Ethernet or other cables to be functional. Some havewireless capabilities through including a small -  that uses radio wavesto transmit information.

     The computer must have a software driver installed to enable it to interact with theNIC. These drivers enable the operating system and higher-level protocols to controlthe functions of the adapter.

    Each NIC has a unique       (MAC) address to direct traffic. Thisunique MAC address ensures that information is only being sent to a specificcomputer name and not to multiple ones if not intended to. Circled in the picturebelow is an example of an integrated network interface card.

     The MAC (Media Access Layer) address, or hardware address, is a 12-digit numberconsisting of digits 0-9 and letters A-F. It is basically a hexadecimal number assignedto the card. The MAC address consists of two pieces: the first signifies which vendor itcomes from, the second is the serial number unique to that manufacturer.

    Example MAC addresses:

    00-B0-D0-86-BB-F7 01-23-45-67-89-AB 00-1C-B3-09-85-15

     The NIC performs the following functions:

      It translates data from the parallel data bus to a serial bit stream for

    transmission across the network.

      It formats packets of data in accordance with protocol.

      It transmits and receives data based on the hardware address of the card.

    4.4.3 Transceivers

     The term  does not necessarily describe a separate network device butrather embedded in devices such as network cards.

     Transceiver is a short name for -. It is a device that both transmitsand receives analog or digital signals. The term transceiver is used most frequently todescribe the component in local-area networks (LANs) that actually applies signalsonto the network wire and detects signals passing through the wire. For many LANs,the transceiver is built into the network interface card (NIC). Older types of networks,however, require an external transceiver.

     The transceiver does not make changes to information transmitted across thenetwork; it adapts the signals so devices connected by varying media can interpretthem. A transceiver operates at the physical layer of the OSI model.

     Technically, on a LAN the transceiver is responsible to place signals onto the networkmedia and also detecting incoming signals traveling through the same cable. Given the

  • 8/20/2019 Sample Elements of Computer Networking

    5/34

    Elements of Computer Networking Networking Devices

    4.3 Intermediary Devices 81

    description of the function of a transceiver, it makes sense that that technology wouldbe found with network cards (NICs).

    4.4.4 Amplifiers and Repeaters

    A repeater is an electronic device that receives a signal and retransmits it at a higherlevel or higher power, so that the signal can cover longer distances without

    degradation.

     Transmitter sends a signal containing some information and after travelling somedistance, usually, a signal get weakened (attenuated) due to energy loss in themedium. Therefore, it should be improved (or ).  is the circuit whichmagnifies the weak signal to a signal with more power.

    Sometimes, this signal attenuation happens much before the arrival to thedestination. In this case, signal is amplified and retransmitted with a power gain inone or more mid points. Those points are called . Therefore an amplifier is anessential part of a repeater.

     AmplifierAmplifier is an electronic circuit that increases the power of an input signal. There aremany types of amplifiers ranging from voice amplifiers to optical amplifiers at differentfrequencies.

    Repeater

     The repeater is an electronic circuit that receives a signal and retransmits the samesignal with a higher power. Therefore, a repeater consists of a signal receiver, an and a . Repeaters are often used in submarine communicationcables as signal would be attenuated to just a random noise when travelling such a

    distance.Different types of repeaters have different types of configurations depending on thetransmission medium. If the medium is microwaves, repeater may consist of antennasand waveguides. If the medium is optical it may contain photo detectors and lightemitters.

    Difference between an Amplifier and a Repeater

    1.  Amplifier is used to magnify a signal, whereas repeater is used to receive and

    retransmit a signal with a power gain.

    2.  Repeater has an amplifier as a part of it.

    3.  Sometimes, amplifiers introduce some noise to the signal, whereas repeaterscontain noise eliminating parts.

  • 8/20/2019 Sample Elements of Computer Networking

    6/34

    Elements of Computer Networking Networking Devices

    4.3 Intermediary Devices 82

    Sending Node

    Receiving Node

    Repeater

    6000 meters

    ℎ can normally transmit a distance of 500 meters and this can be extended byintroducing repeaters. ℎ can normally transmit a distance of 185 meters, andcan also be extended by using a repeater. This is the advantage to using a repeater. Ifa network layout exceeds the normal specifications of cable we can use repeaters tobuild network. This will allow for greater lengths when planning cabling scheme.

    Repeaters  no other action on the data. Repeaters were originally separatedevices. Today a repeater may be a separate device or it may be incorporated into ahub. Repeaters operate at the physical layer of the OSI model.

    4.4.5 Hubs

    Hubs are commonly used to connect segments of a LAN. A hub contains multipleports. When a packet arrives at one port, it is copied to the other ports so that allsegments of the LAN can see all packets.

    A ℎ contains multiple ports. When a packet arrives at one port, it is copied to all(broadcast) the ports of the hub. When the packets are copied, the destination addressin the frame does not change to a  address. It does this in a rudimentaryway; it simply copies the data to all of the nodes connected to the hub.

    Hub

    Hub Hub

  • 8/20/2019 Sample Elements of Computer Networking

    7/34

    Elements of Computer Networking Networking Devices

    4.3 Intermediary Devices 83

     The main function of the hub is to broadcast signals to different workstations in aLAN. General speaking, the term hub is used instead of repeater when referring to thedevice that serves as the center of a network.

    4.4.6 Modems

    Modem is a device that  digital signals to analog signals and analog signals todigital signals. The word modem stands for  and . The processof converting digital signals to analog signals is called . The process ofconverting analog signals to digital signals is called . Modems are usedwith computers to transfer data from one computer to another computer throughtelephone lines.

    Types of Modem Connections

    Modems have two types of connections and they are.  Analog connection

      Digital connection

     Analog Connection

     The connection between the modem and the telephone line is called a . It converts digital signals from a computer to analogue signals thatare then sent down the telephone line. A modem on the other end converts theanalogue signal back to a digital signal the computer can understand. A workstation isconnected to an analogue modem. The analogue modem is then connected to the

    telephone exchange analogue modem, which is then connected to the internet.

    Digital Connection

     The connection of modem to computer is called digital connection

    Types of Modems

     There are two types of modems:

      Internal modems

      External modems

    AnalogModem

    DigitalModem

  • 8/20/2019 Sample Elements of Computer Networking

    8/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 84

    Internal Modems

    It fits into expansion slots inside the computer. It is directly linked to the telephonelines through the telephone jack. It is normally less inexpensive than external modem.Its transmission speed is also less external modem.

    External Modems

    It is the external unit of computer and is connected to the computer through serialport. It is also linked to the telephone line through a telephone jack. External modemsare expensive and have more operation features and high transmission speed.

     Advantages of Modems

      Inexpensive hardware and telephone lines

      Easy to setup and maintain

    Disadvantage of Modems  Very slow performance

    4.4 Internetworking Devices

    4.4.1 Bridges

    Bridge is a device which operates in both the physical and the data link layer of theOSI reference model. As a physical layer device, it  the signal it receives. Asa data link layer device, the bridge can check the physical (MAC) addresses (  and ) contained in the frame.

    Bridges can be used to divide a large network into . Bridges contain logic thatallows them to keep the traffic for each  . When a new frame enters toa bridge, the bridge not only regenerate the frame but it also checks the address of thedestination and forwards the new copy only to the segment to which the destinationaddress belongs.

    A bridge device  data traffic at a network boundary. Bridges reduce the amountof   on a LAN by dividing it into segments. Key features of a bridge arementioned below:

    Hub

    Ethernet LAN

    Apple LocalTalk LAN

    Bridge

  • 8/20/2019 Sample Elements of Computer Networking

    9/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 85

      A bridge operates both in physical and data-link layer

      A bridge uses a table for  / 

      A bridge does not ℎ the physical (MAC) addresses in a   

    4.4.1.1 Why Use Bridges?As an example, imagine for a moment that computers are people in a room. Everyoneis glued to 1 spot and can't move around. If  wants to talk to , he shouts out" " and  responds; and a conversation occur as a result.

    On a small scale this works quite well. The Internet (as we know it today) is not just 2or a few people talking directly to each other. The internet is literally billions ofdevices. If they were all placed into the same room (network-segment); imagine whatwould happen if  wanted to talk to .  would yell " !" and Ram'svoice would be lost in the crowd. Building a room to fit billions of people is equallyridiculous.

    For this reason, networks are separated into smaller segments (smaller rooms) whichallow devices who are in the same segment (room) to talk directly to each other’s. But,for the devices outside the segment we need some sort of device (router) to passmessages from one room to the next room. But the vast number of segments (rooms)means we need some sort of addressing scheme so the various routers in the middleknow how to get a message from  to .

     a large network with an interconnect device () has many .Among these are  collisions (in an Ethernet network), contained ℎ utilization, and the ability to filter out unwanted packets. Bridges were created toallow network administrators to segment their networks transparently. What thismeans is that individual stations need not know whether there is a bridge separatingthem or not. It is up to the bridge to make sure that packets get properly forwarded totheir destinations. This is the fundamental principle underlying all of the bridgingbehaviours we will discuss.

    4.4.1.2 Types of Bridges

    Several different types of bridges are available for internetworking LANs.

    1.     [  ]: Places incomingframe onto all outgoing ports  original incoming port.

    2.    : Stores the origin of a frame (from which port) andlater uses this information to place frames to that port.

    3.    : Uses a subset of the LAN topology for a loop-freeoperation. 

    4.    : Depends on routing information in frame to place theframe to an outgoing port.

    4.4.1.2.1 Transparent Basic Bridges [Transparent Forwarding Bridge]

     The simplest type of bridge is called the     . It is called because the nodes using a bridge are unaware of its presence. This bridgereceives traffic coming in on each port and stores the traffic until it can be transmittedon the outgoing ports. It will not forward the traffic from the port from which it wasreceived.

     The bridge does not make any conversion of the traffic. The bridge forwards ( and  ) frames from one LAN to another. Obviously, the bridgeforwards all frames like a .

  • 8/20/2019 Sample Elements of Computer Networking

    10/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 86

    Transparent Bridge Forwarding

    If the destination address is present in the forwarding database (table) already created,the packet is forwarded to the port number to which the destination host is attached.If it is not present, forwarding is done on all parts ( ). This process is called

      .

    Bridge forwarding operation is explained with the help of flowchart.

    In the figure above, consider three nodes A, B, and C. Assume each node sends framesto all other nodes. The source addresses A, B are observed to be on network LAN-1,while the address of node C will be observed to be on network LAN-2.

    Basic functions of the bridge forwarding are mentioned below.

    1.  If the source address is  present in the forwarding table, the bridge  

    the source address and corresponding interface to the table. It then checks

    the destination address to determine if it is in the table.

    2.  If the destination address is listed in the table, it determines if the destination

    address is on the same LAN as the source address. If it is, then the bridge

     the frame since all the nodes have already received the frame.

    3.  If the destination address is listed in the table but is on a different LAN than

    the source address, then the frame is forwarded to that LAN.

    4.  If the destination address is not listed in the table, then the bridge forwards

    the frame to all the LANs except the one that which originally received the

    frame. This process is called  .

    In some bridges, if the bridge has not accessed an address in the forwarding table overa period of time, the address is removed to free up memory space on the bridge. Thisprocess is referred to as .

    Packets with a source A and destination B are received and discarded, since the nodeB is directly connected to the LAN-1, whereas packets from A with a destination C areforwarded to network LAN-2 by the bridge.

    Forward frame to allLANs except X

    No

    Yes

    Yes No

    Frame Received without

    error on port X

    Destinationfound in

    table?

    Forward frame to

    correct LAN

    Direction= port X?

    Count discardedframes

    Node-B Node-CNode-A

    LAN-1 Bridge LAN-2

  • 8/20/2019 Sample Elements of Computer Networking

    11/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 87

    4.4.1.2.2 Transparent Bridge Learning

     To learn which addresses are in use, and which ports (interfaces on the bridge) areclosest to, the bridge observes the headers of received frames. By examining the MACsource address of each received frame, and recording the port on which it was

    received, the bridge may learn which addresses belong to the computers connected viaeach port. This is called .

     The learned addresses are stored in the    () associatedwith ℎ port (). Once this table has been setup, the bridge examines thedestination address of all received frames; it then scans the interface tables to see if aframe has been received from the same address (i.e. a packet with a source addressmatching the current destination address).

    At the time of installation of a transparent bridge, the table is empty. When a packet isencountered, the bridge checks its source address and build up a table by associatinga source address with a port address to which it is connected. The flowchart explains

    the learning process.

    Table Building

     The table building up operation is illustrated in figure. Initially the table is empty.

    Address Port

    1.  When node A sends a frame to node D, the bridge does not have any entry foreither D or A. The frame goes out from all three ports. The frame floods the

    YesAdd source to tablewith direction and

    timer

    NoSourcefound in

    table?

    Update directionand timer

    Port-1

    Port-2

    LAN-3

    Node-F

    Node-E

    Node-A

    Node-C

    Node-B

    LAN-1

    LAN-2

    Node-D

    BridgePort-3

  • 8/20/2019 Sample Elements of Computer Networking

    12/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 88

    network. However, by looking at the source address, the bridge learns thatnode A must be located on the LAN connected to port 1.

     This means that frame destined for A (in future), must be sent out throughport 1. The bridge adds this entry to its table. The table has its first entry now.

    Address PortA 1

    2.  When node E sends a frame to node A, the bridge has an entry for A, so itforwards the frame only to port 1. There is no flooding. Also, it uses the sourceaddress of the frame (E in this case), to add a second entry to the table.

    Address Port

    A 1

    E 3

    3.  When node B sends a frame to C, the bridge has no entry for C, so once againit floods the network and adds one more entry to the table.

    Address Port

    A 1

    E 3

    B 1

    4.   The process of learning continues as the bridge forwards frames.

    Loop Problem

    Forwarding and learning processes work without any problem as long as there is noredundant bridge in the system. On the other hand, redundancy is desirable from the

    viewpoint of reliability, so that the function of a failed bridge is taken over by aredundant bridge.

     The existence of redundant bridges creates the so-called loop problem as shownfigure. Assuming that after initialization tables in both the bridges are empty let usconsider the following steps:

      1: Node A sends a frame to node B. Both the bridges forward the frame toLAN 1 and update the table with the source address of A.

      2: Now there are two copies of the frame on LAN-1. The copy sent byBridge-A is received by Bridge-B and vice versa. As both the bridges have no

    information about node B, both will forward the frames to LAN-2.  3: Again both the bridges will forward the frames to LAN-1 because of the

    lack of information of the node B in their database and again Step-2 will berepeated, and so on.

    Node-B

    LAN-1

    LAN-2

    Node-A

    Bridge-A Bridge-B

  • 8/20/2019 Sample Elements of Computer Networking

    13/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 89

    So, the frame will continue to  around the two LANs indefinitely.

    4.4.1.2.3 Transparent Spanning Bridges

    As seen in previous section, redundancy creates loop problem in the system and it is

    undesirable. To prevent loop problem, the IEEE (Institute of Electrical and ElectronicsEngineers) specification requires that the bridges use a special topology. Such atopology is known as   (a graph where there is no loop) topology.

     The methodology for setting up a spanning tree is known as   ℎ.  ℎ creates a tree out of a graph. Without changing the physicaltopology, a logical topology is created that overlay on the physical by using thefollowing steps:

    1.  Select a bridge as -, which has the smallest ID.2.  Select root ports for all the bridges, except for the root bridge, which has least-

    cost path (say, minimum number of hops) to the root bridge.

    3.  Choose a  bridge, which has least-cost path to the -, ineach LAN.

    4.  Select a port as   that gives least-cost path from the   to the  bridge.

    5.  Mark the designated port and the root ports as   ports and theremaining ones as  ports.

     An Example

    Let us walk through the below example for running the spanning tree algorithm on.Note that some of the LAN segments have a cost 3 times that of others. The followingconvention is used for the remaining discussion:

      DC means designated cost for a LAN segment

      Bridge-# means bridge number

      A number around a bridge is a port number

    3

    Root Bridge

    1

    LAN-3 DC = 1

    LAN-2DC = 3

    LAN-6DC = 1

    LAN-1 DC = 3

    Bridge-2

    1

    2

    Bridge-1

    1

    2

    Bridge-6

    2

    LAN-4 DC = 3

    LAN-5 DC = 3

    Bridge-5

    1

    2

    Bridge-3

    1

    2

    Bridge-4

    1

    2

    3

  • 8/20/2019 Sample Elements of Computer Networking

    14/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 90

    Step 1 of the algorithm is already shown in the first picture: Bridge 1 is chosen as the  since all the bridges are assumed to have the same priority. The tie isbroken by choosing the bridge with the smallest ID number.

    Next, we determine the root path cost (RPC) for each port on each bridge ℎ ℎ the

     bridge. Then each bridge other than the root chooses its port with the lowest RPCas the root port (RP). Ties are broken by choosing the - port. The rootport is used for all control messages from the root bridge to this particular bridge.

      : Consider port 1 of Bridge-5. Between it and root bridge wehave to traverse at least LAN-3 and LAN-4, with costs 1 and 3 respectively. Total costis 4. Thus RPC = 4 for port 1 of Bridge-5.

    Next, step 3 of the algorithm is to select a designated bridge and a designated port onthis bridge for each LAN segment. This is the bridge that gives the least cost (DPC,designated port cost) for getting between this LAN segment and the root bridge. Theport on this bridge by which we attach this LAN segment is called the   (DP). If there is a tie for the lowest DPC, the bridge with the smallest ID number is

    chosen.

     The root bridge is always the designated bridge for the LAN segments directly attachedto it. The ports by which the root bridge attaches to the LAN segments are thusdesignated ports. We assume that no LAN segment attaches to the root bridge by morethan 1 port. Since a root port cannot be chosen as a designated port, do not wastetime even considering root ports as possible designated ports.

    In the drawing on the next page, we see that LAN-1, LAN-2, and LAN-3 are directlyattached to the root bridge via ports 1, 2, and 3 respectively on the root bridge. Thuswe only need to consider LAN-4, LAN-5, and LAN-6. LAN-4 could use either port 2 onBridge-3 or port 3 on Bridge-4 as its designated port. The DPC for each is 1 since

    anything sent from LAN-4 through such a port goes across LAN-3 to the root bridgeand the cost of LAN-3 is just 1.

    RPC = 7

    3

    Root Bridge

    1

    LAN-3 DC = 1LAN-2DC = 3

    LAN-6DC = 1

    LAN-1 DC = 3

    Bridge-2

    1

    2

    Bridge-1

    1

    2

    Bridge-6

    2

    LAN-4 DC = 3

    LAN-5 DC = 3

    Bridge-5

    1

    2

    Bridge-3

    1

    2

    Bridge-4

    1

    23

    RPC = 3

    RPC = 1

    RPC = 1 RPC = 1

    RPC = 4 RPC = 4

    RPC = 4

    RPC = 3

    RPC = 2

    RP

    RP

    RP

    RP

    RP

  • 8/20/2019 Sample Elements of Computer Networking

    15/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 91

    Since we have a tie for the DP we choose the one on the lowest number bridge. Thatmeans that Bridge-3 is the designated bridge and its port 2 is the designated port forLAN-3. For LAN-5 there is only one port that could be chosen, so the designated portfor LAN-5 is port 2 on Bridge-5 and the designated bridge is Bridge-5. There is nochoice for LAN-6 either as one port is a root port. Thus the designated port for S6 is

    the other one: port 2 on Bridge-4.

    Finally, in step 4 each port that is not a root port or designated port is set to be in ablocking state so that no traffic can flow through it. The blocked ports are X-ed out

    RP 3

    Root Bridge

    1

    LAN-3 DC = 1LAN-2DC = 3

    LAN-6DC = 1

    LAN-1 DC = 3

    Bridge-2

    1

    2

    Bridge-1

    1

    2

    Bridge-6

    2

    LAN-4

    DC = 3

    LAN-5 DC = 3

    Bridge-5

    1

    2

    Bridge-3

    1

    2

    Bridge-4

    1

    23

    DPC = 1

    DPC = 1 DPC = 1

    DPC = 4

    DP

    RP

    RP

    RP

    RP

    DP

    DP

    DP

    DP

    DP DPC = 1

    3

    Root Bridge

    1

    LAN-3 DC = 1LAN-2DC = 3

    LAN-6DC = 1

    LAN-1 DC = 3

    Bridge-2

    1

    2

    Bridge-1

    1

    2

    Bridge-6

    2

    LAN-4

    DC = 3

    LAN-5 DC = 3

    Bridge-5

    1

    2

    Bridge-3

    1

    2

    Bridge-4

    1

    2

    3

    Block

    Block

    DP

    RP

    RP

    RP

    RP

    DP

    DP

    DP

    DP

    DP

    RP

    Block

  • 8/20/2019 Sample Elements of Computer Networking

    16/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 92

    above. This, then, produces our spanning tree (no loops). To better see the spanningtree, the picture can be redrawn as shown on the next page, with the root bridge asthe root of the tree.

    4.4.1.2.4 Translational Bridges

     Translational bridges are a type of transparent bridge that connects LANs that usedifferent protocols at the data link and physical layers, for example, FDDI (Fiber

    Distributed Data Interface) and Ethernet.

    4.4.1.2.5 Source Routing Bridges

    In source routing bridges, the routing operation is determined by the source host andthe frame specifies which route the   to follow. A host can discover a route bysending a   frame, which spreads through the entire network using allpossible paths to the destination.

    Each frame gradually gathers addresses as it goes. The destination responds to eachframe and the source host chooses an appropriate route from these responses. Forexample, a route with minimum ℎ-  can be chosen. Whereas transparent

    bridges do not modify a frame, a source routing bridge adds a routing information fieldto the frame. Source routing approach provides a shortest path at the cost of extraburden on the network.

    Source route bridging is used in token ring networks. A source route bridge links twoor more rings together. There are fundamental characteristics in how a source routebridge transmits a frame between rings. A source route bridge does not create and

    Bridge

    Ethernet LAN

    FDDIRin LAN

    Bridge Token

    Ring LAN

     TokenRing LAN

     TokenRing LAN

    Bridge

  • 8/20/2019 Sample Elements of Computer Networking

    17/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 93

    maintain forwarding tables. The decision to forward or drop a frame is based oninformation provided in the frame.

     The destination station is responsible for maintaining routing tables that define aroute to all workstations on the network. The source workstation is responsible fordetermining the path of a frame to its destination. If no route information is available,then the source station has the ability to perform route discovery to learn the potentialpaths that can be taken.

    4.4.2 Switches

    ℎ is a device that filters and forwards packets between LAN segments. Switchworks at the layer 2 of the OSI model. The main purpose of the switch is toconcentrate connectivity while making data transmission more efficient. Think of theswitch as something that combines the connectivity of a hub with the traffic regulationof a bridge on each port. Switches makes decisions based on MAC addresses.

    A switch is a device that performs switching. Specifically, it forwards and filters OSIlayer 2 datagrams (chunk of data communication) between ports (connected cables)

    based on the MAC addresses in the packets.

    As discussed earlier, a hub forwards data to all ports, regardless of whether the datais intended for the system connected to the port. This mechanism is inefficient; andswitches tries to address this issue to some extent. This is different from a hub in thatit only forwards the datagrams to the ports involved in the communications ratherthan all ports connected. Strictly speaking, a switch is not capable of routing trafficbased on IP address (layer 3) which is necessary for communicating between networksegments or within a large or complex LAN.

    4.4.2.1 How a Switch works?

    Rather than forwarding data to all the connected ports, a switch forwards data only tothe port on which the destination system is connected. It looks at the Media AccessControl (MAC) addresses of the devices connected to it to determine the correct port.

    Switch 

    Sending Node  Receiving Node 

         D    a     t    a

         D    a     t    a

  • 8/20/2019 Sample Elements of Computer Networking

    18/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 94

    A MAC address is a unique number that is stamped into every NIC. By forwardingdata only to the system to which the data is addressed, the switch decreases theamount of traffic on each network link dramatically.

    4.4.2.2 Switching MethodsWe can specify one of   possible forwarding methods for each port in a switch:

    1.  Cut-through2.  Fragment-free3.  Store-and-forward4.  Adaptive

    4.4.2.2.1 Store and Forward Switching

    In  and   switching, Switch copies each of the complete Ethernet frameinto the switch memory and computes a Cyclic Redundancy Check (CRC) for errors. If

    a Cyclic Redundancy Check (CRC) error is found, the Ethernet frame is dropped and ifthere is no Cyclic Redundancy Check (CRC) error, the switch forwards the Ethernetframe to the destination device. Store and Forward switching can cause delay inswitching since Cyclic Redundancy Check (CRC) is calculated for each Ethernet frame.

    4.4.2.2.2 Cut-through Switching

    In -ℎℎ switching, the switch copies into its memory only the destination MACaddress (first 6 bytes of the frame) of the frame before making a switching decision. Aswitch operating in cut-through switching mode reduces delay because the switchstarts to forward the Ethernet frame as soon as it reads the destination MAC addressand determines the outgoing switch port. Problem related with cut-through switchingis that the switch may forward bad frames.

    4.4.2.2.3 Fragment-Free Switching

    -  switching is an advanced form of cut-through switching. The switchesoperating in cut-through switching read only up to the destination MAC address fieldin the Ethernet frame before making a switching decision. The switches operating infragment-free switching read at least 64 bytes of the Ethernet frame before switching itto avoid forwarding Ethernet runt frames (Ethernet frames smaller than 64 bytes).

    4.4.2.2.4 Adaptive switching

      ℎ mode is a user-defined facility to maximize the efficiency of theswitch. Adaptive switching starts in the default switch forwarding mode we haveselected. Depending on the number of errors (say, CRC errors) at that port, the modechanges to the  of the other two switching modes.

    4.4.3 Routers

    4.4.3.1 What is Router?

     are ℎ devices that join multiple  together. Technically, a routeris a Layer 3 device, meaning that it connects two or more networks and that the router

    operates at the network layer of the OSI model.

    Routers maintain a table (called   ) of the available routes and theirconditions and use this information along with distance and cost algorithms to

  • 8/20/2019 Sample Elements of Computer Networking

    19/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 95

    determine the best route for a given packet. Typically, a packet may travel through anumber of network points with routers before arriving at its destination.

     The purpose of the router is to examine incoming packets (layer 3), chose the bestpath for them through the network, and then switches them to the proper outgoingport. Routers are the most important traffic controlling devices on large networks.

    Routers are networking devices that forward data packets between networks usingheaders and    to determine the best path to forward the packets.Routers also provide interconnectivity between  and  media (networks whichuse different protocols).

    4.4.3.2 Understanding Concepts of Routers

    As an example, assume that we want to send a postcard just based on person names(with minimum information). For example,  s [USA], ℎ  [India] or

       [USA] it would be routed to them due to their fame; no listing of thestreet address or the city name would be necessary. The postal system can do suchrouting to famous personalities, depending on the name alone.

    In an Internet, a similar discussion is possible: ℎ any  anywhere in theworld without knowing where the site is currently located. Not only that, it is possibleto do so very efficiently, within a matter of a few seconds.

    4.4.3.2.1 What is Network Routing?

    How is this possible in a communication network, and how can it be done so quickly? The answer to this question is  .   is the ability to send aunit of information from source to destination by finding a path through the network,and by doing efficiently and quickly.

    4.4.3.2.2 What is Addressing?

    First, we start with a key and necessary factor, called . In many ways,addressing in a network has similarities to postal addressing in the postal system. So,we will start with a brief discussion of the postal addressing system to relate them.

    A typical postal address that we write on a postcard has several components — thename of the person, followed by the street address with the house number (ℎ ), followed by the city, the state name, and the postal code. If we take the

  • 8/20/2019 Sample Elements of Computer Networking

    20/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 96

    processing view to route the postcard to the right person, we essentially need toconsider this address in the reverse order of listing, i.e., start with the postal code,then the city or the state name, then the house address, and finally the name of theperson.

    You may notice that we can reduce this information somewhat; that is, you can justuse the postal code and leave out the name of the city or the name of the state, sincethis is redundant information. This means that the information needed in a postaladdress consists of three main parts: the postal code, the street address (with thehouse number), and the name.

    A basic routing problem in the postal network is as follows:

    1.   The postcard is first routed to the city or the geographical region where thepostal code is located.

    2.  Once the card reaches the postal code, the appropriate delivery post office forthe address specified is identified and delivered to.

    3.  Next, the postman or postwoman delivers the postcard at the address, without

    giving much consideration to the name listed on the card.4.  Rather, once the card arrives at the destination address, the residents at this

    address take the responsibility of handing it to the person addressed.

     The routing process in the postal system is broken down to three components:

      How to get the card to the specific postal code (and subsequently the postoffice),

      How the card is delivered to the destination address, and

      Finally, how it is delivered to the actual person at the address.

    If we look at it in another way, the place where the postcard originated in fact does notneed to know the detailed information of the street or the name to start with; thepostal code is sufficient to determine to which geographical area or city to send thecard. So, we can see that postal routing uses address hierarchy for routing decisions.

    An advantage of this approach is the decoupling of the routing decision to multiplelevels such as the postal code at the top, then the street address, and so on. Animportant requirement of this hierarchical view is that there must be a way to dividethe complete address into multiple distinguishable parts to help with the routingdecision.

    Now, consider an electronic communication network; for example, a criticalcommunication network of the modern age is the Internet. Naturally, the first questionthat arises is: how does addressing work for routing a unit of information from one

    point to another, and is there any relation to the postal addressing hierarchy that wehave just discussed? Second, how is service delivery provided? In the next section, weaddress these questions.

    4.4.3.2.3 Addressing and Internet Service: An Overview

    In many ways, Internet addressing has similarities to the postal addressing system. The addressing in the Internet is referred to as   (IP) . An IPaddress defines  parts: one part that is similar to the postal code and the otherpart that is similar to the house address; in Internet terminology, they are known asthe  and the ℎ, to identify a network and a host address, respectively.

    A host is the end point of communication in the Internet and where a communicationstarts. A host is a generic term used for indicating many different entities; the mostcommon ones are a web-server, an email server, desktop, laptop, or any computer weuse for accessing the Internet. A  identifies a contiguous block of addresses.

  • 8/20/2019 Sample Elements of Computer Networking

    21/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 97

    4.4.3.2.4 Network Routing: An Overview

    In the previous section, we provided a broad overview of addressing and transfermechanisms for data in Internet communication services. Briefly, we can see thateventually packets are to be routed from a source to a destination. Such packets may

    need to traverse many cross-points, similar to traffic intersections in a roadtransportation network. Cross-points in the Internet are known as .

    A router’s functions are to read the destination address marked in an incoming IPpacket, to consult its internal information to identify an outgoing link to which thepacket is to be forwarded, and then to forward the packet. Similar to the number oflanes and the speed limit on a road, a network link that connects two routers islimited by how much data it can transfer per unit of time, commonly referred to as theband-width or capacity of a link; it is generally represented by a data rate, such as1.54 megabits per second (Mbps). A network then carries traffic on its links andthrough its routers to the eventual destination; traffic in a network refers to packetsgenerated by different applications, such as web or email.

    Note: For more about IP Addressing and routing, refer    and   chapters.

    4.4.3.3 Types of Routers

    Depending on the role that routers perform, routers can be classified in many differentways.

    4.4.3.3.1 Interior Routers

      routers work within networks. These routers handle packets travellingbetween nodes on the same Intra-network. An interior router is used to divide a largenetwork into more easily manageable subnetworks. It can keep one part of a networksecure from another and it can allow different technologies, for example, Ethernet andtoken ring, to be used in the same network.

    4.4.3.3.2 Border Routers

     routers exist on one network and their function is to connect that network with

    outside networks, including the Internet. They discover routes between the interiornetwork and others and they handle incoming and outgoing traffic.

    Internet

    Exterior Routers Border Routers Interior Routers

  • 8/20/2019 Sample Elements of Computer Networking

    22/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 98

    4.4.3.3.3 Exterior Routers

     routers are most common on the Internet. They do not exist on a particularnetwork but rather in the space between networks where data passes through on itsway to its destination. Exterior routers do not store routes to particular hosts; but

    they store routes to other . Their primary role is to receive packets and thenforward them in the direction of their destination.

    4.4.4 Gateways

     The term   is used in networking to describe the   to the Internet. The  controls traffic that travels from the inside network to the Internet andprovides security from traffic that wants to enter the inside network from the Internet.

    A network gateway is an internetworking system which joins two networks that usedifferent base protocols. A network gateway can be implemented completely insoftware, completely in hardware, or as a combination of both. Depending on the types

    of protocols they support, network gateways can operate at any level of the OSI model.

    Since a gateway (by definition) appears at the edge of a network, related capabilitieslike firewalls tend to be integrated with it. On home networks, a router typically servesas the network gateway although ordinary computers can also be configured toperform equivalent functions.

    As mentioned earlier, the Internet is not a single network but a collection of networksthat communicate with each other through gateways. A gateway is defined as a systemthat performs relay functions between networks, as shown in figure above. Thedifferent networks connected to each other through gateways are often called, because they are a smaller part of the larger overall network.

    With TCP/IP, all interconnections between physical networks are through gateways.An important point to remember for use later is that gateways route informationpackets based on their destination network name, not the destination machine.Gateways are completely transparent to the user.

    4.4.1 Default Gateway

     The default gateway is needed only for systems that are part of an internetwork (in theabove figure, note that two subnetworks connected to same gateway). Data packetswith a destination IP address not on the local subnet are forwarded to the defaultgateway. The default gateway is normally a computer system or router connected tothe local subnet and other networks in the internetwork.

    If the default gateway becomes unavailable, the system cannot communicate outsideits own subnet, except for with systems that it had established connections with priorto the failure.

    Sub-Network Sub-Network

    Sub-Network

    Sub-Network

    Sub-Network

    Gateway

    Gateway

    Gateway

  • 8/20/2019 Sample Elements of Computer Networking

    23/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 99

    4.4.2 Multiple Gateways

    If the default gateway becomes unavailable, data packets cannot reach theirdestination.   can be used to solve this problem.

    4.4.3 Difference between Gateway and Router

    4.4.3.1 Gateway

     The   between gateway and router is, gateway it is defined as a networknode that allows a network to interface with another network with different protocols.A router is a device that is capable of sending and receiving data packets betweencomputer networks, also creating an overlay network.

    Gateways and routers are two words are often confused due to their similarities. Bothgateways and routers are used to regulate traffic into more separate networks.However, these are two different technologies and are used for different purposes.

     The term gateway can be used to define two different technologies: gateway anddefault gateway. These two terms should not be confused. In terms of communicationsnetwork, gateway it is defined as a network node that allows a network to interfacewith another network with different protocols. In simple terms, gateway allows twodifferent networks to communicate with each other. It contains devices such asimpedance protocol translators, rate converters, or signal translators to allow systeminteroperability.

    A protocol translation/mapping gateway interconnects networks that have differentnetwork protocol technologies. Gateways acts as a network point that acts as anentrance to another network. The gateway can also allow the network to connect thecomputer to the internet. Many routers are available with the gateway technology,

    which knows where to direct the packet of data when it arrives at the gateway.Gateways are often associated with both routers and switches.

    Default gateway is a computer or a computer program that is configured to performthe tasks of a traditional gateway. These are often used by ISP or computer serversthat act as gateway between different systems. When getting an internet connection,an ISP usually provides a device that allows the user to connect to the Internet; thesedevices are called . In organizational systems a computer is used as a node toconnect the internal networks to the external networks, such as the Internet.

    4.4.3.2 Router

    A router is a device that is capable of sending and receiving data packets betweencomputer networks, also creating an overlay network. The router connects two or moredata line, so when a packet comes in through one line, the router reads the addressinformation on the packet and determines the right destination, it then uses theinformation in its routing table or routing policy to direct the packet to the nextnetwork. On the internet, routers perform   functions. Routers can alsobe wireless as well as wired.

     The most common type of routers is small office or home routers. These are used forpassing data from the computer to the owner's cable or DSL modem, which isconnected to the internet. Other routers are huge enterprise types that connect largebusinesses to powerful routers that forward data to the Internet.

    When connected in interconnected networks, the routers exchange data such asdestination addresses by using a dynamic routing protocol. Each router is responsiblefor building up a table that lists the preferred routes between any two systems on the

  • 8/20/2019 Sample Elements of Computer Networking

    24/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 100

    interconnected networks. Routers can also be used to connect two or more logicalgroups of computer devices known as subnets. Routers can offer multiple featuressuch as a DHCP server, NAT, Static Routing, and Wireless Networking.

     These days’ routers are mostly available with built-in gateway systems make it easierfor users with them not having to buy separate systems.

    4.4.5 Firewalls

     The term firewall was derived from   and intended to  the of fire from one  to another. From the computer security perspective, the Internetis an unsafe environment; therefore   is an excellent metaphor for networksecurity.

    A firewall is a system designed to prevent unauthorized access to or from a privatenetwork. Firewalls can be implemented in either hardware or software form, or acombination of both. Firewalls prevent unauthorized users from accessing privatenetworks. A firewall sits between the two networks, usually a private network and apublic network such as the Internet.

    Connecting a computer or a network of computers may become targets for malicious

    software and hackers. A firewall can offer the security that makes a computer or anetwork less vulnerable.

    Note: For more details, refer  section in   chapter.

    4.4.6 Differences between Hubs, Switches, and Routers

     Today most routers have something combining the features and functionality of arouter and switch/hub into a single unit. So conversations regarding these devicescan be a bit misleading —  especially to someone new to computer networking.

     The functions of a router, hub and a switch are all quite different from one another,even if at times they are all integrated into a single device. Let's start with the hub and

    Internal NetworkInternet

    (Unsecure)

    FIREWALL

  • 8/20/2019 Sample Elements of Computer Networking

    25/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 101

    the switch since these two devices have similar roles on the network. Each serves as acentral connection for all of your network equipment and handles a data type knownas frames. Frames carry the data. When a frame is received, it is amplified and thentransmitted on to the port of the destination PC. The big difference between these twodevices is in the method in which frames are being delivered.

    In a hub, a frame  to every one of its ports. It doesn't matter that the frameis only destined for one port. The hub cannot distinguish which port a frame shouldbe sent to. Broadcasting it on every port ensures that it will reach its intendeddestination. This places a lot of traffic on the network and can lead to poor networkresponse times.

    Additionally, a 10/100Mbps hub must share its bandwidth with each and every one ofits ports. So, when only one PC is broadcasting, it will have access to the maximumavailable bandwidth. If, however, multiple PCs are broadcasting, then that bandwidthwill need to be divided among all of those systems, which will degrade performance.

    A switch, however, keeps a record of the  addresses of all the devices connected toit. With this information, a switch can identify which system is sitting on which port.So, when a frame is received, it knows exactly which port to send it to, withoutsignificantly increasing network response times. And, unlike a hub, a 10/100Mbpsswitch will allocate a full 10/100Mbps to each of its ports. So regardless of thenumber of PCs transmitting, users will always have access to the maximum amount ofbandwidth. It's for these reasons why a switch is considered to be a much betterchoice than a hub.

     are completely different devices. Where a hub or switch is concerned withtransmitting frames, a router's job, as its name implies, is to route packets to othernetworks until that packet ultimately reaches its destination. One of the key features

    of a packet is that it not only contains data, but the destination address of where it'sgoing.

    A router is typically connected to at least two networks, commonly two Local AreaNetworks (LANs) or Wide Area Networks (WAN) or a LAN and its ISP's network, forexample, your PC or workgroup and EarthLink. Routers are located at gateways, theplaces where two or more networks connect. Using headers and forwarding tables,routers determine the best path for forwarding the packets. Router use protocols suchas ICMP to communicate with each other and configure the best route between anytwo hosts.

    Question 1:  In modern packet-switched networks, the source host segments long,application-layer messages (for example, an image or a music file) into smallerpackets and sends the packets into the network. The receiver then reassemblesthe packets back into the original message. We refer to this process as  . Figure shows the end-to-end transport of a message with andwithout message segmentation. Consider a message that is 9.0106 bits long thatis to be sent from source to destination in figure. Suppose each link in the figureis 1.5 Mbps. Ignore propagation, queuing, and processing delays.

    Problems and uestions with Answers

    Source

    Packet

    Switch

    Destination

    Packet

    Switch

    No Segmentation

    Full Message

  • 8/20/2019 Sample Elements of Computer Networking

    26/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 102

    A) Consider sending the message from source to destination without messagesegmentation. How long does it take to move the message from the source host tothe first packet switch? Keeping in mind that each switch uses store-and-forwardpacket switching, what is the total time to move the message from source host todestination host?B) Now suppose that the message is segmented into 5,000 packets, with eachpacket being 1,500 bits long. How long does it take to move the first packet fromsource host to the first switch? When the first packet is being sent from the firstswitch to the second switch, the second packet is being sent from the source host

    to the first switch. At what time will the second packet be fully received at the firstswitch?C) How long does it take to move the file from source host to destination hostwhen message segmentation is used? Compare this result with your answer inpart (A) and comment.

     :

    A) Time to send message from source host to first packet switch =  9×

    .×sec = 6 sec.

    With store-and-forward switching, the total time to move message from source host todestination host = 6 sec × 3 hops = 18 sec.

    B) Time to send 1st packet from source host to first packet switch =.×

    .× sec = 1

    msec.

     Time at which second packet is received at the first switch = 1.5 × 106 time at whichfirst packet is received at the second switch = 2 × 1 msec = 2 msec.

    C) Time at which 1st packet is received at the destination host = 1 msec × 3 hops = 3msec . After this, every 1msec one packet will be received; thus time at which last

    (5000) packet is received = 3 msec + 4999 × 1 msec = 5.002 sec.

    It can be seen that delay in using message segmentation is significantly less (more

    than

     rd).

    Question 2: 

    For the following statement, indicate whether the statement is True orFalse.

    Switches exhibit lower latency than routers.

     : True. No routing table look-up, no delays associated with storing data, bits flow through the switch essentially as soon as they arrive.

    Question 3:  Packet switches have queues while circuit switches do not. Is it true orfalse?

     : False. Routers have queues; switches do not, even though the packet switchmust have more memory than a circuit switch to receive a full packet before it canforward it on.

    Question 4:  Consider the arrangement of learning bridges shown in the followingfigure. Assuming all are initially empty, give the forwarding tables for each of thebridges B1-B4 after the following transmissions:

    Segment

    Source

    Packet

    Switch

    Destination

    Packet

    Switch

    With Segmentation

  • 8/20/2019 Sample Elements of Computer Networking

    27/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 103

    D sends to C; A sends to D; C sends to A

     : When D sends to C, all bridges see the packet and learn where D is. However,when A sends to D, the packet is routed directly to D and B3 does not learn where Ais. Similarly, when C sends to A, the packet is routed by B2 towards B1 only, and B4does not learn where C is.

     The forwarding table for Bridge B1:

    Destination Next HopA A-Interface

    C B2-Interface

    D B2-Interface

     The forwarding table for Bridge B2:

    Destination Next Hop

    A B1-Interface

    C B3-Interface

    D B4-Interface

     The forwarding table for Bridge B3:

    Destination Next Hop

    C C-Interface

    D B2-Interface

     The forwarding table for Bridge B4:

    Destination Next Hop

    A B2-Interface

    D D-Interface

    Question 5:  Which type of bridge observes network traffic flow and uses thisinformation to make future decisions regarding frame forwarding?

    A) Remote B) Source routing C) Transparent D) Spanning tree

     : C

    Question 6:  Learning network addresses and converting frame formats are thefunction of which device?A) Switch B) Hub C) MAU D) Bridge

     : D

    Question 7:   The device that can operate in place of a hub is a:A) Switch B) Bridge C) Router D) Gateway

     : A

    Question 8:  Which of the following is NOT true with respective to a transparent bridgeand a router?A) Both bridge and router selectively forward data packets

    B2 

    B4 

    B1 

    B3 

     A 

  • 8/20/2019 Sample Elements of Computer Networking

    28/34

    Elements of Computer Networking Networking Devices

    4.4 Internetworking Devices 104

    B) A bridge uses IP addresses while a router uses MAC addressesC) A bridge builds up its routing table by inspecting incoming packetsD) A router can connect between a LAN and a WAN.

     : B. Bridge is the device which work at data link layer whereas router works at

    network layer. Both selectively forward packets, build routing table and connectbetween LAN and WAN but since bridge works at data link it uses MAC addresses toroute whereas router uses IP addresses.

  • 8/20/2019 Sample Elements of Computer Networking

    29/34

    Elements of Computer Networking LAN Technologies

    5.1 Introduction 105

    LAN Technologies

    Chapter 

    5

    5.1 Introduction The bottom two layers of the Open Systems Interconnection (OSI) model deal with thephysical structure of the network and the means by which network devices can sendinformation from one device on a network to another.

     The data link layer controls how data packets are sent from one node to another.

    Application Layer

    Presentation Layer

    Session Layer

     Transport Layer

    Network Layer

    Data Link Layer

    Physical Layer

    Application Layer

    Presentation Layer

    Session Layer

     Transport Layer

    Network Layer

    Data Link Layer

    Physical Layer

    Data DataReceiverSender

    Ph sical Link

  • 8/20/2019 Sample Elements of Computer Networking

    30/34

    Elements of Computer Networking LAN Technologies

    5.2 Types of Network Links 106

    5.2 Types of Network Links There are two types of network links: -- links, and  links.

    5.2.1 Broadcasting Network LinksBroadcast is a method of sending a signal where multiple nodes may hear a singlesender node. As an example, consider a conference room with full of people. In thisconference room, a single person starts saying some information loudly.

    During that time, some people may be sleeping, and may not hear what person issaying. Some people may not be sleeping, but not paying attention (they are able tohear the person, but choose to ignore). Another group of people may not only beawake, but be interested in what is being said. This last group is not only able to hearthe person speaking, but is also listening to what is being said.

    In this example, we can see that a single person is broadcasting a message to all

    others that may or may not be able to hear it, and if they are able to hear it, maychoose to listen or not.

    5.2.1.1 Simplex Broadcasting Network

    Radio and TV stations are a good examples of everyday life  . In thiscase the radio/TV stations are a type of communications called . In a simplextype of communication, data is only expected to flow in one direction.

    5.2.1.2 Half-Duplex Broadcasting Network

    Conference-room meetings are another everyday example of a broadcast network. In

    this example, everyone may speak to everyone else, but when more than one personspeaks, interference (collision) from multiple conversations may make it impossible tolisten to more than one conversation even though we can hear both conversations. Inthis conference-room example, we can see parties are able to share access to acommon media (human voice as sound through the air.) They compete for access tospeak, but for the most part, only one person speaks at a time for everyone to hear. This is an example of a type of communications called ℎ-.

    5.2.1.3 Full-Duplex Broadcasting Network

    Let us consider the singing competition where we can see a group of singersattempting to sing in Harmony. They can each speak separately on their own, but if

    they speak on different topics, the conveyed information for any of them may be lostby each other. This is an example of another type of communication called -.

     This means that they are not only able to speak, but listen at the same time they arespeaking. All of them will speak and listen at the same time. How is this possible? Inorder to sing in harmony, each singer must be able to hear the frequencies being usedby the other singers, and strive to create a frequency with their voice that matches thedesired frequency to create that harmony.

     This feed-back of each singer to listen to the collective, and possibly key into a specificsinger's voice is used by them as they sing to create the exact frequency needed, andensure their timing is the same as the rest of the singers. All members are able to hear

    all other members, and speak at the same time. They are all acting as a  - communications in a broadcast network.

  • 8/20/2019 Sample Elements of Computer Networking

    31/34

    Elements of Computer Networking LAN Technologies

    5.3 Medium Access Control Techniques 107

    5.2.2 Point-to-Point Network Links

    -- is a method of communication where one node speaks to another node.A woman in a restaurant whispers to her husband a message. Nobody else in therestaurant knows what was said. The conversation was only between them.

    5.2.2.1 Simplex Point-to-Point Network

    An example of a very simple  point-to-point network could be a doorbell (thecircuit.) When the doorbell button is depressed at the front door, a signal is passed tobell which performs its functions to announce the button has been depressed. The belldoes not send a message to button. The message travels only in one direction andtakes place between the button and the bell.

    5.2.2.2 Half-Duplex Point-to-Point Network

    As an example, let us assume that we have a couple who are openly affectionate, sat

    on a bench in a park, and holding hands under a blanket.

    Also, assume that this couple has their own code in holding hands for speaking toeach other. For example, 3 squeezes maps to  and 4 squeezes of the handmaps to    . The wife squeezes her husband's hand 3 times. He gets thismessage, and smiles (acknowledging the receipt of the message) and then returns anew message of 4 squeezes. She smiles (acknowledging her receipt of the message shefelt.) If both parties attempted to squeeze each other's hands at the same time, thenthe number of squeezes may be confused. So we can see each party may speakthrough squeezing each other’s hands, but only one may speak at a time.

     This conversation takes place only between these two people. Here we see point-to-

    point and ℎ-. 

    5.2.2.3 Full-Duplex Point-to-Point Network

    Data can travel in both directions simultaneously. There is no need to switch fromtransmit to receive mode like in half duplex. Full-duplex network operates like a two-way, two-lane street. Traffic can travel in both directions at the same time.

    5.3 Medium Access Control TechniquesAs we have seen, networks can be divided into two types:

    1) 

    Sℎ

     communication network (also called

    -

    -

    ,

    -

    -,

     andℎ): --  communication is performed with the help oftransmission lines such as multiplexers and switches.

    2)   communication network: In this we have a medium which is sharedby a number of nodes.   is a method of sending a signal wheremultiple nodes may hear a single sender node.

    A point-to-point link consists of a single sender on one end of the link, and a singlereceiver at the other end of the link. Many link-layer protocols have been designed for

    Networks

    Switched Networks Broadcast Networks

  • 8/20/2019 Sample Elements of Computer Networking

    32/34

    Elements of Computer Networking LAN Technologies

    5.3 Medium Access Control Techniques 108

    point-to-point links; PPP (point-to-point protocol) and HDLC (High-level Data LinkControl) are two such protocols.

    Now, let us consider a different kind of scenario in which we have a medium which isshared by a number of users.

    Any user can broadcast the data into the network. Now whenever it is broadcastedobviously there is a possibility that several users will try to broadcast simultaneously. This problem can be addressed with medium access control techniques.

    Now question arises how different users will send through the shared media. It isnecessary to have a protocol or technique to regulate the transmission from the users. That means, at a time only one user can send through the media and that has to bedecided with the help of Medium Access Control (MAC) techniques. Medium accesscontrol techniques determines the next user to talk (i.e., transmit into the channel).

    A good example is something we are familiar with - a classroom - where teacher(s) andstudent(s) share the same, single, broadcast medium. As humans, we have evolved aset of protocols for sharing the broadcast channel ("Give everyone a chance to speak.""Don't speak until you are spoken to." "Don't monopolize the conversation." "Raise your hand if you have question." "Don't interrupt when someone is speaking." "Don'tfall asleep when someone else is talking.").

    Similarly, computer networks have protocols called   protocols. Theseprotocols control the nodes data transmission onto the shared broadcast channel.

     There are various ways to classify multiple access protocols. Multiple access protocolscan be broadly divided into four types; random, round-robin, reservation andchannelization. These four categories are needed in different situations. Among thesefour types, channelization technique is static in nature. We shall discuss each of themone by one.

    Shared Medium

     Token Passing

    Broadcast Multiple Access Techniques

    Static Channelization Techniques Dynamic Medium Access Techniques

     TDMA

    FDMA

    CDMA

    Random Access Techniques

    ALOHA

    CSMA

    CSMA/CD

    CSMA/CA

    Round-Robin

    Polling

    Reservation

    R-ALOHA

  • 8/20/2019 Sample Elements of Computer Networking

    33/34

    Elements of Computer Networking LAN Technologies

    5.4 Random Access Techniques 109

    5.4 Random Access TechniquesRandom access method is also called - access. In this method, nostation is assigned to control another. Random MAC techniques can be further dividedinto four different types; ALOHA, CSMA, CSMA/CD and CSMA/CA.

    When each node has a fixed flow of information to transmit (for example, a data filetransfer), reservation based access methods are useful as they make an efficient use ofcommunication resources. If the information to be transmitted is bursty in nature, thereservation-based access methods are not useful as they waste communicationresources.

    Random-access methods are useful for transmitting short messages. The randomaccess methods give freedom for each  to get access to the network whenever theuser has information to send.

    5.4.1 ALOHA

    Aloha protocol was developed by   at   . In the  language, Aloha means , , and . University of Hawaii consistsof a number of islands and obviously they cannot setup wired network in theseislands. In the University of Hawaii, there was a centralized computer and there wereterminals distributed to different islands. It was necessary for the central computer tocommunicate with the terminals and for that purpose   developed a protocolcalled  ℎ.

    Central node and terminals (stations) communicate by using a wireless techniquecalled  . Each of these stations can transmit by using  frequencywhich is  access shared by all the terminals. After receiving the data, the

    central node retransmits by using a  frequency and that will be received by allterminals.

     There are two different types of ALOHA:

    1.  Pure ALOHA2.  Slotted ALOHA

    5.4.1.1 Pure Aloha

     The first version of protocol given by   works like this:

    1.  If a node has data to send, send the data

    2.  If the message collides with another transmission, try resending later3.  In case of collision, sender waits random time before retrying

    …  Terminal-1

     Terminal-2  Terminal-3

     Terminal-4

    Central Node

    Random Access

    Broadcast

  • 8/20/2019 Sample Elements of Computer Networking

    34/34

    Elements of Computer Networking LAN Technologies

     This simple version is also called   . Note that, in Pure ALOHA, sender doesnot check whether the channel is busy before transmitting.

    5.4.1.1.1 Frames in Pure ALOHA

    Pure ALOHA assumes all frames have the same length. A shared communicationsystem like ALOHA requires a method for handling collisions. Collisions will occurwhen two or more systems try to send data at the same time. In the ALOHA system, anode transmits whenever data is available to send. If another node transmits at thesame time, a collision occurs, and the frames that were transmitted are lost. However,a node can listen to broadcasts on the medium, even its own, and determine whetherthe frames were transmitted.

    As shown in diagram, whenever two frames try to occupy the channel at the sametime, there will be a collision and both will be damaged. If first bit of a new frameoverlaps with just the last bit of a frame almost finished, both frames will be totallydestroyed and both will have to be retransmitted.

    5.4.1.1.2 Pure ALOHA Protocol

    Pure ALOHA uses two different frequencies for data transfers. The central nodebroadcasts packets to everyone on the outbound (also called ) channel, andthe terminals sends data packets to the central node on the inbound (also called) channel.

    If data was received correctly at the central node, a short acknowledgment packet wassent to the terminal; if an acknowledgment was not received by a terminal after ashort wait time, it would automatically retransmit the data packet after waiting arandomly selected time interval. This acknowledgment mechanism was used to detectand correct for collisions created when two terminals both attempted to send a packetat the same time.

      In pure ALOHA, the stations transmit frames whenever they have data tosend.

      When two or more stations transmit at the same time, there will be a collisionand the frames will get destroyed.

      In pure ALOHA, whenever any station transmits a frame, it expects theacknowledgement from the receiver.

    If acknowledgement is not received within specified time the station assumes

    B

    C

    D

    A Frame-A.1

    Frame-B.1

    Frame-C.1

    Frame-D.1

    Frame-A.2

    Frame-B.2

    Frame-D.2

    Frame-C.2

    Collision Durations Time