Académique Documents
Professionnel Documents
Culture Documents
04 Data Communications
I. Introduction
1.1 Communication Networks
Definition: The set of devices, mechanisms and procedures by which end-user equipment attached to the network can exchange meaningful information.
1.1.1 Typical functions: A path by which electrical signals can be transmitted. A mechanism by which bits can be converted to and from electrical signals. The means to give meaning to groups of bits. Bits are typically grouped in units called frames, packets or messages. Methods to overcome deficiencies in the electric path that might cause electric signals (the bits they represent) to be misinterpreted. Techniques for selecting and maintaining a path through the network to perform the above functions.
1-1
Communication subnet (network node, a subnet, or a transport system). In general, consists of transmission links and switching systems.
Transmission links carry the bits from one computer to another through networks, connect various switching elements of subnets and define
the
topology (physical connection) of the subnet. The subnet defines the three lower layers of OSI-RM.
1-2
A communication system supporting point-to-point communication is defined as point-to-point, store-and-forward or packet-switched subnet.
There exists only one channel or circuit which can be shared by all connected users (of the selected group) hosts/nodes.
This type of communication suffers from the problem of contention. To solve this problem, it requires a complex protocol at each node.
1-4
1-5
Message Switching
Packet Switching - Shared resources - Virtual circuits - Datagrams
Figure 1.1.1 Comparison of Circuit Switching, Message Switching, and Packet Switching
1-6
The rate allocated to the session must be large enough to meet the delay requirement. This allocated capacity is idle when the session has nothing to send. If communication is expensive, then circuit switching is uneconomic to meet the delay requirements of bursty traffic. It requires a call set-up during which resources are not utilized. If messages are much shorter than the call setup time, then circuit switching is not economical (or even practical)
- More of a problem in high-speed networks.
L = message lengths (bits or bytes) = arrival rate of message (messages/sec) R = channel rate (bits/sec) X = message transmission delay =L/R - R must be large enough to keep X small - Bursty traffic => X << 1 => low utilization Example - L= 1,000 bytes (8,000 bits) - = 1 message per second - X < 0.1 seconds (delay requirement) - => R > 8,000/ 0.1 = 80,000 bps utilization = 8,000/ 80,000 = 10% With packet switching channel can be shared among many sessions to achieve higher utilization.
1-9
1.2.2 Message Switching An individual message is separately switched at each node along its route or path from source to destination. A circuit (or path) is not established exclusively for a message; instead, message are sent using the store-and-forward approach. Each message is divided into blocks of data by users based on the capacity of the networks, and these blocks are transmitted in a sequence. The receiver, after receiving these blocks, constructs the original message from the blocks (by putting them in the same sequence as when it was transmitted) and sends an acknowledgement to the source.
The first block of the message contains control information regarding routing, QoS (Quality of Service) parameters, etc.
If the destination node does not accept the message (due to incomplete message, errors, or some other failure), the source node will transmit the same message again on the same link.
1-10
1.2.2 Message Switching (cont.) The intermediate switching nodes will store the block of messages in the event of circuit failure, heavy traffic, broken links, loss of acknowledgement, etc.
The switching nodes store the blocks of message and look for the free link to another switching intermediate node.
If it finds any free node, it sends one block at a time to that node until all the stored blocks are sent. If it does not find any free node, it will store the blocks and keep on trying to find free links until it finds one and transmits the block to it. The intermediate nodes are predefined between source and destination on the basis of certain criteria (e.g., shortest route, fastest route, heavy traffic, shareable files and programs, real-time data, etc.). - If it does not find any intermediate node within the constraints, it will reroute
the blocks on a different alternative route.
Each block of messages is received as a complete frame and errors are checked in each block separately.
If an error is found in any block, then that block will be re-transmitted unidirectionally (simplex operation)
1-11
Problems with Message Switching Due to no limit on the size of the blocks of messages, the following problems may occur: 1. The switching node must have enough storage capacity for storing the blocks. 2. If a free link between source and destination is busy for a long time, then waiting and response time for the blocks to be transmitted may be significant.
Thus the technique seems to be useful for batched messages of longer duration but not suitable for interactive messages of shorter duration.
Advantages and Disadvantages of Message Switching The message switching technique is less expensive than circuit switching and is widely used as a technique for interconnection. This network allows the efficient utilization of a communication link. - Each of the nodes connected in the network share the load on equal probability and hence the channels are utilized to their maximum capacity. It does not support dynamic load balancing and, as such, heavy traffic on a particular node will be handled by itself.
1-12
In principle, packet switching is based on the concept of message switching with the following differences:
Packets are parts of messages and include control bits (for detecting transmission errors). Networks break the message into blocks (or packets), while in message switching, this is performed by users. Due to very small storage time of packets in the waiting queue at any node, users experience bi-directional transmission of the packets in real time.
The message is divided into blocks (or packets) of fixed size with its own control information regarding the routing, etc., across the network.
Route chosen on packet-by-packet basis. Different packets may follow different route, results in out-of-sequence arrival at destination. The receiver, after receiving the packets out of sequence, has to arrange the packets in the same order as they were transmitted from the source.
1-14
1.2.3 Packet Switching (cont.) If any node receives a garbled packet, it will request the sending node to transmit the same packet again.
- In this case, the acknowledgement will not be sent out after the receiving node receives the missing packets.
The packet switching technique allows the switching nodes to transmit the packets without waiting for a complete message and also allows them to adjust the traffic they have, thus minimizing the resource requirements of the nodes. - If any particular node is already heavily loaded, it will reject the packets until its load becomes moderate.
1-15
- The network manager performs the operations of segmenting, reassembling and maintaining the path/route until the packets are delivered to the destination, e.g., ATM (Asynchronous Transfer Mode).
1-16
1.2.3.2 Comparison of the Mode of Operation of Packet Switching For Datagram, addressing information must uniquely distinguish each network node and session - Need unique source and destination addresses.
For Virtual Circuits, only the virtual circuits on a link need to be distinguished by addressing - Global address needed to set-up virtual circuit. - Once established, local virtual circuit members can then be used to represent the virtual circuits on a given link: VC number changes from link to link.
Datagram approach
1.3 Advantages and Disadvantages Comparison of Switching Techniques 1. The link utilization of packet switching is improved over circuit switching. - Since the link can be shared by a number of different packets. Each node has its own queue storing those packets which are going to use the node.
After the communication link is established, the packets (of different or the same data messages) may be transmitted during the established connection.
2. In packet switching networks, stations with different data rates can communicate with each other, and the necessary conversion between different data rates is done by the network. While in circuit switching networks, both stations must have the same data rate. 3. In circuit switching, the packets may be lost (not transmitted) in the event of a busy network. In packet switching, packets will be accepted, but there may be some delay in their delivery.
1-19
1.3 Advantages and Disadvantages Comparison of Switching Techniques (Cont.) 4. The delay in the transmission of packets at any node may become a problem in the case of packet switching, while in the case of circuit switching, a dedicated circuit has been established and hence there is no delay in the transmission. 5. Priorities can be assigned to the switching nodes in the packet switching such that nodes with higher priorities will transmit the packets waiting in their respective queues before the lower priority nodes. In the case of circuit switching, there is no concept of priority. 6. Circuit switching generates the ordered delivery of the packets, while packet switching does not give any guarantee for the ordered delivery of the packets.
1-20
Key functions of protocols: Segmentation and Reassembly Encapsulation Connection Control Ordered Delivery Flow Control Error Control Multiplexing
1-22
1.5.1 Segmentation and Reassembly (a) Segmentation: Whether the application entity sends data in messages or in a continuous stream, lower level protocols may need to break up the data into blocks of some smaller bounded size.
(PDU: Protocol Data Unit, a block of data exchanged between two entities via a protocol.
3. More equitable access to shared transmission facilities, with shorter delay, can be provided. For example, without a maximum block size, one station could monopolize a shared medium. 4. A smaller PDU size may mean that receiving entities can allocate smaller buffers. 5. An entity may require that data transfer comes to some sort of closure from time to time, for checkpoint and restart/recovery operations.
1-23
Disadvantages of Segmentation 1. Each PDU contains a fixed minimum of control information. Hence the smaller the block, the greater the percentage of overhead. 2. PDU arrival may generate an interrupt that must be serviced. Smaller blocks result in more interrupts. 3. More time is spent processing smaller and more numerous PDUs.
(b) Reassembly:
The segmented data must be reassembled into the messages appropriate to the application level.
If PDUs arrival out of order, this task is complicated.
1-24
1.5.2 Encapsulation
Definition: The addition of control information to data. Data are accepted or generated by an entity and encapsulated into a PDU containing that data plus control information.
Each PDU contains not only data but control information. Indeed, some PDUs consist solely of control information and no data. The control information falls into three general categories: Address: The address of the sender and/or receiver may be indicated.
Error detection code: Some sort of code is often included for error detection.
Protocol control: Additional information is included to implement the protocol functions.
1-25
Layer N
Layer N
Layer N-1
Layer N-1
1-26
Protocol Entity
Connection Request
Protocol Entity
multiple exchange
Terminate-connection Acknowledge
1-27
Connection-oriented data transfer: Consists of three phases. Connection establishment During the connection establishment phase, two entities agree to exchange data. Typically, one station will issue a connection request to the other. Both entities must be using the same protocol. Data transfer After connection establishment, the data transfer phase is entered. During this phase, both data and control information (flow control, error control) is exchanged. Connection termination Finally, one side or the other wishes to terminate the connection and does so by sending a termination request.
1-28
The receiving entity typically allocates a data buffer with some maximum length.
When data are received, the receiver must do a certain amount of processing (i.e., examine the header and strip it from the PDU) before passing the data to a higher layer user. In the absence of flow control, the receivers buffer may fill up and overflow while it is processing old data.
1-29
Positive acknowledgement
It is the responsibility of the receiving protocol entity to acknowledge each PDU that it receives. -This is done by sending back the sequence number of the received PDU to the other side.
If a PDU is lost in transit, then the intended receiver will obviously not acknowledge it.
Error detection The PDU gets through but the bits have been altered by errors in transit. To account for this contingency, the error detections is needed. The sending entity performs a calculation on the bits of the PDU and adds the result to the PDU. The receiver performs the same calculation and compares the calculated result to the result stored in the coming PDU. If there is a discrepancy, the receiver assumes that an errors has occurred and discarded the PDU.
1-31
1.5.7 Multiplexing:
A function that may be exercised when more than one layer of a communications architecture employs a connection-oriented protocol.
Three particular types of construction of (N) connections on top of (N-1) connections are distinguished: One-to-one: Each (N) connection is built on one (N-1) connection. Upward multiplexing: Occurs when multiple (N) connections are multiplexed on, or share a single (N-1) connection to make efficient use of the lower-level service. If several transport connections are needed between a pair of hosts, these could all be multiplexed on a single network connection. Downward multiplexing (splitting): A single (N) connection is built on top of multiple (N-1) connection, the traffic on the (N) connection being divided between the various (N-1) connections to improve reliability, performance or efficiency.
1-32
Any layer is referred to as the (N) layer. An (N) entity implements functions of the (N) layer and also the protocol for communicating with (N) entities in other systems. There might be multiple identical (N) entities, or also be differing (N) entities, corresponding to different protocol standards at that level. Each entity communicates with entities in the layers above and below it across an interface.
A primitive specifies the function to be performed and is used to pass data and control information.
1-36
Request Indication
A Primitive issued by a service user to invoke some services and to pass the parameters needed to fully specify the requested service. A Primitive issued by a service provider either: (1) To indicate that a procedure has been invoked by the peer service user on the connection and to provide the associated parameters, or (2) To notify the service user of a provider-initiated action. A Primitive issued by a service user to acknowledge or complete some procedures previously invoked by an indication to that user.
Response
Confirm
A Primitive issued by a service provider to acknowledge or complete some procedures previously invoked by a request by the service user.
SERVICE PROVIDER
Response
1-37
Consider the transfer of data from an (N) entity to a peer (N) entity in another system.
The following steps could occur: 1. The source (N) entity invokes its (N-1) entity with Data.request primitive. Associated with the primitive are the parameters needed, such as the data to be transmitted and the destination address. 2. The source (N-1) entity prepares an (N-1) PDU to be sent to its peer (N-1) entity.
3. The destination (N-1) entity delivers the data to the appropriate destination (N) entity via Data.indication, which includes the data and a source address as parameters.
4. If an acknowledgement is called for, the destination (N) entity issues a Data.response primitive to its (N-1) entity. 5. The (N-1) conveys this acknowledgement in an (N-1) PDU. 6. The acknowledgement is delivered to the (N) entity via a Data.confirm.
1-38
(N)-PDU (N) Layer (N-1) PCI (N-1)-SDU PDU: Protocol Data Unit SDU: Service Data Unit PCI: Protocol Control Information
1-39
Data unit: The data that passes between entities in the form of a collection of bits. The PDU is passed as a unit between peer entities. An entity in the (N) layer cannot directly pass data to a peer entity at the (N) layer. - It must pass its (N) PDUs down to the (N-1) layer.
The (N-1) views data coming from the (N) layer as an (N-1) service data unit (SDU).
The (N-1) entity may map an SDU arriving from above into a single PDU.
Alternatively, the (N-1) entity may segment the (N-1) SDU into multiple PDUs.
In any case, the identity of the SDU as a unit is preserved from one end of the connection to the other; - if the SDU is segmented by the sending (N-1) entity, it must be reassembled by the receiving (N-1) entity before delivery to the receiving (N) entity.
1-40
1.6.3 Seven Layers OSI Reference Model (cont.) Layer 7: Application layer - Provides various network services required by user applications.
- Serves as a window between application processes which are using OSI-RM and defines its aspect for various application entities.
Example of Standards: CCITT X.400 message handling (MHS) (for PSDNs) CCITT FTAM (file transfer access and management ) (for PSDNs) CCITT X.420 interpersonal messaging (for PSDNs) CCITT X.500/520 directory services (for PSDNs) CCITT TTX telex service (for PSTNs) CCITT T100, T101 videotex (for PSTNs) Network file system (NFS), file transfer protocol (FTP), remote login (Rlogin), remote procedure call (RPC), simple mail transfer protocol (SMTP), simple network management protocol (SNMP), and others are provided by TCP/IP communication interface (UNIX).
1-43
1-44
- Standardization has not proceeded well here, since transport to application are all in the operating system and do not really need standard interfaces.
Example of Standards: ISO 8326 session service specification (for LANs) ISO 8327 session layer protocol (for LANs) CCITT X.215/X.225 (for PSDNs) CCITT T62 (for PSTNs) Remote procedure control (RPC) library (UNIX)
1-45
1.6.3 Seven Layers OSI Reference Model (cont.) Layer 4: Transport layer - The network layer provides a virtual end-to-end packet pipe to the transport layer. - The transport layer provides a virtual end-to-end message service to the high layers. The functions of the transport layer are: 1. Break messages into packets and reassemble packets size suitable to network layer. 2. Multiplex sessions with same source/destination nodes. 3. Re-sequence packets at destination. 4. Recover from residual errors and failures. 5. Provide end-to-end flow control. Example of Standards: ISO 8072 transport service specification (for LANs) ISO 8073 transport layer protocol (for LANs) CCITT X.214/X.224 (for PSDNs) CCITT T70 (for PSTNs) Transmission Control Protocol (TCP) (UNIX)
1-46
1.6.3 Seven Layers OSI Reference Model (cont.) Layer 3: Network layer - Accepts incoming packets from the transport layer and transit packets from the DLC layer. - Routes each packet to the proper outgoing DLC or (at the destination) to the transport layer. - Adds its own header to the packets received from the transport layer.
This header provides the information needed for routing (e.g., destination address).
Example of Standards: CCITTs X.25 includes lower three layers known as level 1,2,3. X.21 has been defined for level 1, high-level data link control (HDLC for level 2 and packet level standard for level 3. CCITT X.213 (circuit-switched network) (for PSDNs) CCITT X.25-3 (packet-switched network) CCITT T30 (for PSTNs) ISO connectionless mode network Internet Protocol (IP) (UNIX) Figure 1.6.7 Network layer CCITT I.450 and I.451 (for ISDNs)
1-47
1.6.3 Seven Layers OSI Reference Model (cont.) Layer 2: Data link layer -Responsible for reliable and error-free transmission of packets across a single link. Framing: Determine the start and end of the packets Error detection: Determine which packets contain transmission errors Error correction: Retransmission schemes (Automatic Repeat Request (ARQ)
1.6.3 Seven Layers OSI Reference Model (cont.) Layer 1: Physical layer - Responsible for transmission of bits over a link. - Connects the network to the transmission medium and also generates the electromagnetic signals. - Offers two types of transmission configurations: point-to-point and multipoint. - Supports different types of the line configurations: half-duplex and fullduplex in serial and parallel modes. Example of Standards: EIA-232-D; 25 pins, EIA RS-449 (RS-422-A and RS-423-A); 37 pins. EIA-530, EIA-366 CCITT X.21-1 (circuit-switched network); 9 pins CCITT X.21 bis (for the PSDNs) CCITT X.25-1 (packet-switched network) CCITT V.24 (list of definitions for the interchange of circuits between DTE and DCE for the PSTNs) 5.28 (electrical characteristics for unbalanced) 5.21(general-purpose interface between DTE and DCE) for Ethernet, token bus (UNIX) CCITT I.430 and I.431 (for ISDNs).
1-49
AH
data data
1-52
1-53
1-54
1-55
1-56
1-60
1.6.6 Addressing
Four levels of addresses are used in an internet employing the TCP/IP protocols: physical, logical, port, and specific.
1-62
Figure E.1 Data Link layer using Physical Address A node with physical address 10 sends a frame to a node with physical address 87. The two nodes are connected by a link.
At the data link level this frame contains physical link addresses in the header.
These are the only addresses needed. The rest of the header contains other information needed at this level. The trailer usually contains extra bits needed for error detection.
1-63
We want to send data from - a node with network address A and physical address 10 , located on one LAN, - to a node with a network address P and physical address 95, located on another LAN.
Because the two devices are located on different networks, we cannot use physical addresses only; the physical addresses have only local jurisdiction.
What we need here are universal addresses that can pass through the boundaries of LANs. The network (logical) addresses have this characteristics. The packet at the network layer contains the logical addresses, which remain the same from the original source to the final destination (A and P, respectively). They will not change when we go from network to network. However, the physical addresses will change when the packet moves from one network to another.
1-65
Data coming from the upper layers have - service-point (port) addresses j and k (j is the address of sending applications, and k is the address of the receiving application).
Since the data size is larger than the network layer can handle, the data are split into two packets, each packet retaining the service-point addresses (j and k).
Then in the network layer, network addresses (A and P) are added to each packet. The packets may travel on different paths and arrive at the destination either in order or out of order.
The two packets are delivered to the destination network layer, which is responsible for removing the network layer headers.
The two packets are now passed to the transport layer, where they are combined for delivery to the upper layer.
1-67
Internet Sub-layer
A sub-layer between the transport and network layers is required when various incompatible networks are joined together.
This sub-layer is used at gateways between the different networks.
protocol is needed.
1-69
Encapsulation in TCP/IP