cct swt and pkt swt

Upload: ysupasani

Post on 05-Apr-2018

233 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/2/2019 CCT Swt and PKT Swt

    1/45

    DATA SWITCHING TECHNIQUES

    AND

    PACKET SWITCHED DATA

    NETWORKS

  • 8/2/2019 CCT Swt and PKT Swt

    2/45

    OBJECTIVES :

    Data switching techniques

    Circuit switched sub network

    Store and forward switched sub network

    Packet switching

    Virtual circuit routing

    Packet switching services

  • 8/2/2019 CCT Swt and PKT Swt

    3/45

    Sub network Topology

    Switching is selection and establishment of a path froma source to a specific destination through the sub-

    network. Switching is carried out on specific demandfrom the source. The motivation for resorting toswitched networks arises out of the following two majorrequirements :

    * Flexible Topology

    Switching provides capability to deliver informationpresented at one access point of the sub-network to avariety of destinations, which can be selected by theusers. Thus, switching provides a flexibleinterconnection topology.

    * Resource Sharing

    The sub-network resources are available to all theusers of the sub-network. Thus, the interconnectionresources are shared by many users.

  • 8/2/2019 CCT Swt and PKT Swt

    4/45

    Switching Techniques

    At each node, there is need to decide theroute through trunk circuits which finallylead to the exit node. This switchingfunction and other related functions are

    carried out at the nodes. There are twobasic techniques employed in the nodesfor switching data to appropriate route :

    Circuit switching Store-and-forward switching

  • 8/2/2019 CCT Swt and PKT Swt

    5/45

    In circuit switched sub-networks, a connectionbetween the two communicating end systems isestablished and then transmission of data takesplace over this connection. The sub-networkconsists of circuit switching nodes which areinterconnected by trunk circuits. A nodeconnects an incoming circuits to an outgoing

    trunk circuit. The most common example ofcircuit sub-network is the telephone network.Trunks may be real (metallic pairs, FDMchannels, PCM channels) or "virtual". If they are

    virtual, they must be immediately available totheir user whenever information is to betransmitted.

  • 8/2/2019 CCT Swt and PKT Swt

    6/45

    A connection is built up by connecting the trunk circuitsin tandem up to the exit node. To establish thisconnection, the originating station sends a

    CONNECTION ESTABLISHMENT REQUEST withaddress of the destination to the entry node. The entrynode builds up a path by connecting one of the trunkcircuits going in the desired direction to the end system.The address information is transferred to next node

    where again cross connections are made. This processis repeated at each intermediate node and finally at theexit node which connects to the destination. The exitnode signals INCOMING CALL INDICATION to it. If thedestination returns CALL ACCEPTANCE signal, the sub-network sends CONNECTION CONFIRMATION to the

    call originator. Thus, an end to end connection isestablished. After the confirmation is received, datatransfer can begin on the established connection. Theconnection is bi-directional, i.e. transmission can beeither direction.

  • 8/2/2019 CCT Swt and PKT Swt

    7/45

    The users have full time ownership ofthe connection till it is released by

    them. Note that address of thedestination is specified only onceduring call set up. All subsequent data

    blocks are transmitted on the pathalready established

  • 8/2/2019 CCT Swt and PKT Swt

    8/45

    The sub-network usually does not retainthe information on the end-points of a

    connection after it is established.Therefore, if the connection gets broken,the sub-network does not have any

    capability to restore the connection. The circuit switched sub-network provides

    end-to-end connection for transmission of

    data and it does not have any error controlor flow control capabilities

  • 8/2/2019 CCT Swt and PKT Swt

    9/45

    Note that the connection does not involvelayers-2 (LLC) and two of the sub-networknodes for transfer of user data. Relayingfunction of layer-1 must be utilized fortransmission of the electrical signals. In

    other words, the sub-network does notincorporate error and flow control functionsfor the user data. These layer-2 functionsare carried out end-to-end. The signaling

    information exchanged during callestablishment and release phases, on theother hand, involves layer-2 and Layer-3.

  • 8/2/2019 CCT Swt and PKT Swt

    10/45

    Delays in Circuit Switched Sub-network

    Connection establishment in circuit

    switched sub-networks involves certain setup. It includes cross connectionestablishment delays at each node andconnection request propagation delays.Once the connection is set up, user datatransfer involves only propagation delayand it is constant. There is almost no delay

    at the nodes during data transfer phase.Data is transmitted immediately andincrementally as soon as it is presented tothe sub-network.

  • 8/2/2019 CCT Swt and PKT Swt

    11/45

    During peak hours of traffic, once

    a connection is established, thereis no increase in transmissiondelay through the sub-network as

    a dedicated transmission pathalways exists. There may be

    increased delay in establishmentof the connection as networkresources may not be free.

  • 8/2/2019 CCT Swt and PKT Swt

    12/45

    Store And Forward Switched Sub-

    Networks

    Message switching sub-networks.

    Packet switching sub-networks.

  • 8/2/2019 CCT Swt and PKT Swt

    13/45

    In message switching sub-networks,

    the complete message is switchedat the sub-network nodes. In packetswitching sub-networks, the

    message is first divided into smallerpackets of data and then thesepackets are switched through the

    sub-network. The switching modeadopted in both these sub-networktypes.

  • 8/2/2019 CCT Swt and PKT Swt

    14/45

    Store-and-forward mechanism :

    Store-and-forward sub-network consists of

    store-and-forward nodes interconnected bytrunks. One channel is usually sufficientbetween a pair of nodes. Multiple channels canbe provided to increase reliability. Each nodeis equipped with a storage device wherein allincoming messages are temporarily stored foronward transmission. The basic operation of

    store-and-forward service is similar to thetelegram service. A message along withaddress is sent from node to node till itreaches destination.

  • 8/2/2019 CCT Swt and PKT Swt

    15/45

    The store-and-forward service isunidirectional. After delivery of themessage, the sub-network does not sendback any confirmation to the source. Ifend-system B is required to send anacknowledgement to the message

    received from A, the acknowledgement willbe treated as like any other message bythe sub-network and will carry address ofA in its header. It is not so in circuit

    switching service which provides an end-to-end connection between twocommunicating devices for communication

    in both the directions.

  • 8/2/2019 CCT Swt and PKT Swt

    16/45

    For node-to-node transfer of the message,the sub-network may employ some error

    control mechanism. The message may beappended with error checking bits and if anyerror is detected by the receiving node, it may

    request the sending node for re-transmissionof the message. Therefore, the sending nodeis required to keep a copy of the message till

    an acknowledgement is received. Once anode has correctly sent a message, itdiscards the copy and thereafter it hasnothing to do with the message.

  • 8/2/2019 CCT Swt and PKT Swt

    17/45

    Since at each stage of transmission, amessage is stored in a buffer at the

    node, each node-to-node transfer isan independent operation. The trunkscan operate at different data rates.

    Even the source and sinks of themessages can operate at differentspeeds. It is not so in circuit switching

    where the users have to operate atthe same speed.

  • 8/2/2019 CCT Swt and PKT Swt

    18/45

    Note that in store-and-forward

    switching, there is no call establishment

    phase. Each block of information istreated as independent entity by the

    sub-network and, therefore, each block

    of information carries the destinationaddress. Thus, unlike circuit switching

    where address was sent only once

    during call establishment phase, instore-and-forward switching, address isrepeated on each block of information.

  • 8/2/2019 CCT Swt and PKT Swt

    19/45

    Delay in Message Delivery

    Message delivery time is sum of the following

    components : Time required to send the message to the entrynode. It is determined by the transmission datarate and message size. Propagation time to the

    entry node is usually negligible. Node delay which includes :

    Message processing at each node (timerequired for error checking, routing, etc.).Waiting

    time in the queues at each node. Transmission time at each node (determined by

    the transmission data rate) and propagation timefor transmission across the trunk.

  • 8/2/2019 CCT Swt and PKT Swt

    20/45

    Delay in Message Delivery

    Total time required to deliver the message is

    linear sum of all these components of time asthey occur in a sequential manner. Deliverytime varies from message to messagebecause of random waiting times in queues

    and alternate routes between same pair ofentry and exist nodes. Therefore, timerelationship of the messages and theirsequence are not guaranteed in a store-and-

    forward sub-network. As traffic increasesthere is increase in message delivery timebecause the queues get longer and theremay be congestion on the route.

  • 8/2/2019 CCT Swt and PKT Swt

    21/45

    Feature Circuit Switching Store-&-Forward Switching

    Connection set-upConnection set-up phaserequiredFinite connections set-up delay

    Connection not required to be set-up

    Disconnection phase Required Not required

    Destination address Specified once Specified on each message

    Delivery delay Constant delivery delayDelivery delay is significant andrandom.

    Temporal order Temporal order is maintained Temporal order is not maintained.

    Time relationshipMessage-to-message timerelationship is maintained.

    Time relationship between twomessages is not retained.

    Error checking No error checkingSome transit error control ispossible.

    Uni/Bi-directional Bi-directional Unidirectional

    Message delivery Very high probability of delivery Delivery is not guaranteed.

    Busy hourIncreased connection set-updelay.

    Increased delivery delay.

    Data rate conversionUsually changing data rate isnot feasible.

    Data rates at user ends can bedifferent.

  • 8/2/2019 CCT Swt and PKT Swt

    22/45

    Packet Switching : In message switching, a message is transmitted by

    a node to another node after it has been completelyreceived. This results in significant delivery delay.This delay can be reduced by dividing the messageinto smaller chunks of data called packets. Now,each packet can be transmitted by a node to thenext node immediately after it is received. Note thattotal delivery time is not linear sum of allcomponents of delay as there is some overlapping.The total delivery time thus gets reduced. There is

    some increase in the processing time at the entryand exit nodes because the message needs to bepartitioned into packets at the entry node andreassembled at the exit node.

  • 8/2/2019 CCT Swt and PKT Swt

    23/45

    Another feature of packet switchednetworks which results in reduced

    processing time at the nodes is that thepackets are stored in primary memory ofthe node. Messages on the other hand

    are required to be stored in secondarymemory because of their size. Accesstime of primary memory is much less

    than the secondary memory. In factdelivery time can be so much reducedthat users can have even interactive type

    of dialogue.

  • 8/2/2019 CCT Swt and PKT Swt

    24/45

    The basic packet switching operation of the sub-network is based on store and forward mechanism.

    The only motivation for packetisation is to reducethe delivery time. Most of the additional features ofpacket switching have been possible due toreduced delivery time.

    Datagrams And Virtual Circuits

    There are two approaches for routing the data

    packets through a sub-network : Datagram routing

    Virtual circuit routing

  • 8/2/2019 CCT Swt and PKT Swt

    25/45

    In its simplest form, a datagram is a packet ofdata with complete address of a destination.

    Datagrams are sent out onto the sub-networkone by one, and the sub-network interpretsthe destination address on each packet ateach stage of switching and tries to deliver it

    to the destination independent of otherdatagrams. It is similar to message switchingdescribed above except that size of message

    is limited. In virtual circuit approach, packets are

    delivered to the destination over a fixed routewhich is established before handover.

  • 8/2/2019 CCT Swt and PKT Swt

    26/45

    E

  • 8/2/2019 CCT Swt and PKT Swt

    27/45

    Datagram Routing

    Figure shows a sub-network consisting of

    five store-and-forward nodes 'A' to 'E'connected by point to point trunk circuits.To send a datagram across the sub-

    network, it is first sent down the link fromthe user to the access node. In each node,the controlling program examines thedesignation address on the datagram anduses some algorithm to choose the nextlink to send the datagram towards itsdestination.

  • 8/2/2019 CCT Swt and PKT Swt

    28/45

    Some of the possible alternatives for decidingthe route of the datagram across the sub-network are :

    Send the datagram to one of the trunk circuits atrandom. Though the datagram will eventuallyreach the destination but the method would be

    very inefficient. Another similar approach could be send it on the

    trunk which has the shortest queue irrespectiveof its destination.

    A brute force approach could be to send thedatagram on all the trunks. The datagram wouldreach the destination quickly but large redundant

    traffic would be generated in the sub-network.

  • 8/2/2019 CCT Swt and PKT Swt

    29/45

    A much better approach than thosementioned above is to set up a routing

    table at each node. Given an address, thenode can look up the routing table anddecide the next link, e.g. to send adatagram from sender 'S' to destination

    'R', the routing table at node 'A' wouldindicate the next link connecting to node'B'. Similarly at node 'B', the routing table

    would indicate that the datagram shouldbe sent to node 'D'. The datagram wouldbe next routed to node 'E' and hencefinally to the destination.

  • 8/2/2019 CCT Swt and PKT Swt

    30/45

    The approach seems to be feasible, butwe have not considered a very important

    aspect, updation of routing tables. If a newnode is added to the sub-network, all therouting tables at various nodes need to be

    updated.

  • 8/2/2019 CCT Swt and PKT Swt

    31/45

    Dynamic Routing Suppose nodes A, B, C and D are all connected and have

    up-to-date routing tables, i.e. they have entries for nodes A,

    B, C and D but there is no entry for node E. Now imaginenode E is added to the sub-network as shown in the figure.The algorithm used for updating the routing tables is thateach node will send the updation information to the othernodes it is connected to. When node E becomes active, itwill update routing table of node D, node D will in turn,

    update routing tables of nodes B and C, and node B willupdate routing table of node A. Another piece ofinformation required for the routing table is number of hops,e.g. distance from node B to node E is two hops via node Dand three hops via nodes C and D. so node D will tell B andC one hop distance to E. B and C will note it down as two

    hops distance to E via D, adding another hop. C will alsoinform B about E. It will indicate two hops distance to E.Therefore, B will have two alternative routes to E, one oftwo hops via D and the other of three hops via C. Thus, allthe nodes will have updated routing tables.

  • 8/2/2019 CCT Swt and PKT Swt

    32/45

    Virtual Circuit Routing :

    In the virtual circuit approach, a logicalconnection is established through the sub-network before sending any user data (as

    done in circuit switched sub-networks).Unlike datagram approach, the nodes donot make a routing decision for each

    packet. It is made once for eachconnection at the time of establishing theconnection. Let us understand how it isdone.

  • 8/2/2019 CCT Swt and PKT Swt

    33/45

    Fig. 4.12 shows a simple network withuser S attached to node A. User S is

    identified by its address A-S (usually partof address of a user identifies the node towhich it is attached). Another user R withaddress D-R is attached to node D.

  • 8/2/2019 CCT Swt and PKT Swt

    34/45

    Suppose S wishes to exchange data withR. To establish a connection to R, S sends

    a CONNECT REQUEST packet to node Aspecifying the destination address D-R. Italso specifies a label N1 to the node. All

    the future packets to be sent to R over theconnection, will bear the same label N1.The destination address is not specified

    again. In X-25, as we shall see later, N1 iscalled logical channel identifier. Thus,CONNECT REQUEST is "Connect A-S toD-R. Use label N1 for this link"

  • 8/2/2019 CCT Swt and PKT Swt

    35/45

    Note that S is also requesting the node to uselabel N1. On receipt of this CONNECT REQUEST,node A takes note of the label N1. Node A

    examines the destination address specified in theCONNECT REQUEST packet and works out thenext link in the chain leading to the destinationfrom its routing table. For this link to node B, nodeA selects another label N2 which is unique on thislink. Node A writes this label by the side ofprevious label N1. All the future packets of theconnection being established and going betweennode 'A' and node 'B' shall bear label N2. For now,

    node 'A' sends a modified CONNECT REQUESTpacket to node 'B.

    "Connect A-S to D-R. use label N2 for this link".

  • 8/2/2019 CCT Swt and PKT Swt

    36/45

    Note that the label has been changed. Onreceipt of this packet, node B works out theroute and forwards the packet to node 'D' using

    another label N3. Node 'B' also keeps a recordrelating labels N2 and N3. Node 'D' sends anINDICATION of incoming call to destination 'R'.It does so using still another label N4 which isunique on the link between node 'D' and 'R'. If 'R'is ready to accept the call, it sends itsACCEPTANCE to node 'D'. It uses label N4already being in use for this link of theconnection. Node 'D' sends this ACCEPTANCE

    to node 'B' using label N3. Node 'B' towards thisto node 'A' using label N2. Node 'A' finally sendsa CONFIRMATION to 'S' of having established aconnection to the destination. This confirmationbears label N1.

  • 8/2/2019 CCT Swt and PKT Swt

    37/45

    Thus, in the connection establishmentphase, a route to the destination is

    finalized and a confirmation is receivedfrom the destination. The connection is inthe form of tables relating the labels of

    data packets. These tables are maintainedat each node (Fig. 4.13). Whenever apacket is received by a node, it looks up in

    therein. It also gives to the packet a newlabel which is also indicated in the table.This connection is called virtual because itdoes not physically exist.

  • 8/2/2019 CCT Swt and PKT Swt

    38/45

    'S' can send data packets now. It will uselabel N1 and 'R' will use label N4 on their

    packets. Addresses of the destinations arenot needed in the data packets.

    The motivation behind attaching labels isthat on each link, between the nodes orbetween end system and a node, several

    connections can be maintainedsimultaneously. This is illustrated in Fig.4.14.

  • 8/2/2019 CCT Swt and PKT Swt

    39/45

    Node P is operating two connections, onethrough nodes Q, R and S and other through

    nodes Q, R and T. For the first connection, thepackets are labeled "1" on link P-Q, "5" on linkQ-R and "7" on link R-S. For the secondconnection, packets are labeled "2" on link P-Q,

    "4" on link Q-R and "3" on link T-R. Node O isalso maintaining two connections, one throughQ, R and S and the other through Q, R and T.Note that four connections are simultaneously

    working through link Q-R. Packets are identifiedas belonging to a particular connection by theirlabels on each interconnecting link

  • 8/2/2019 CCT Swt and PKT Swt

    40/45

    Another very important point to be noted is thatin a particular connection all packets always take

    the same route which is decided at the time ofestablishing the connection. Therefore, deliverydelay is more or less constant in virtual circuitsapproach. Minor variations could be due to re-

    transmission of packets between two nodes ifthere is an error.

    As the packets follow the same route, theirsequence is retained across the sub-network.Datagram routing on the other hand usuallydoes not deliver the packets in the sequencethey were transmitted

  • 8/2/2019 CCT Swt and PKT Swt

    41/45

    At the time of connection set-up, the

    nodes allocate some buffer resources fortemporary storage of the packets. Thebuffer size is determined by the maximum"window size" to be used across the sub-network. Window size specifies themaximum number of packets which can besent to a node without seeking its

    permission. By pre-allocating buffers likethis, it is possible to avoid deadlocks

  • 8/2/2019 CCT Swt and PKT Swt

    42/45

    PACKET SWITCHING SERVICES Packet switching services need to be

    distinguished from packet switched

    routing discussed above. The serviceprovided to the user can be :

    Datagram service

    Virtual circuit service

  • 8/2/2019 CCT Swt and PKT Swt

    43/45

    Datagram service is connectionlessservice having the features as described in

    the section on datagram routing. Anadditional feature could be sequencing ofdatagrams by the exit nodes. Virtual circuit

    service, on the other hand, is a connectionoriented service which can be providedusing either virtual connection routing

    approach or datagram routing approach(Fig. 4.15).

  • 8/2/2019 CCT Swt and PKT Swt

    44/45

    If datagram routing is employed, theinterface that the service provided to theuser is virtual circuit service. CCITT

    Recommendation X.25, Frame Relay arefor the interface between DTE and theaccess node for virtual circuit service.

  • 8/2/2019 CCT Swt and PKT Swt

    45/45

    Thank you, Your patience is,

    Great !