Presentation is loading. Please wait.

Presentation is loading. Please wait.

Lecture Focus: Data Communications and Networking  Network Models  Data Link Layer  Network Layer  ……… Lecture 10 CSCS 311.

Similar presentations


Presentation on theme: "Lecture Focus: Data Communications and Networking  Network Models  Data Link Layer  Network Layer  ……… Lecture 10 CSCS 311."— Presentation transcript:

1 Lecture Focus: Data Communications and Networking  Network Models  Data Link Layer  Network Layer  ……… Lecture 10 CSCS 311

2 Data Communications and Networking OSI Model 7

3 OSI Model :

4 OSI Model : LAYERS Data Link Layer Data Link layer is responsible for transmitting frames from one node to the next.  It sends data from network layer to physical layer.  It is responsible for providing node-to node communication on a single, local network.  It makes the physical layer appear error-free to the upper layer (network layer).

5 OSI Model : LAYERS Relationship of the data link, the network and the physical layers Data Link Layer

6  Framing  Physical Addressing  Flow Control  Error Control  Access Control Responsibilities of the data link layer Data Link Layer

7  Framing:  DL layer translates messages from upper layer into bits that the physical layer can transmit.  It formats data into bits for sending over the Physical layer  The data link layer divides the stream of bits received from the network layer into manageable data units called frames.  Data units at the Data Link layer are called frames. Responsibilities of the data link layer Network layer Data Link layer Frame Data Link Layer

8 OSI Model : LAYERS Data Link Layer Responsibilities of the data link layer  Physical addressing:  It must provide an address mechanism that enables messages to be delivered to the correct nodes:  If frames are to be distributed to different systems on the network, the data link layer adds a header to the frame to define the sender and/or receiver of the frame.  If the frame is intended for a system outside the sender's network, the receiver address is the address of the device that connects the network to the next one.  Flow control: ( Speed variation control )  If the rate at which the data are absorbed by the receiver is less than the rate at which data are produced in the sender, the data link layer imposes a flow control mechanism to avoid overwhelming the receiver.

9 OSI Model : LAYERS Data Link Layer Responsibilities of the data link layer  Error control:  This layer ensures the integrity of the data before and after transmission of data.  This duty is often handled by the Transport layer  The data link layer adds reliability to the physical layer by adding mechanisms to detect and retransmit damaged or lost frames.  It also uses a mechanism to recognize duplicate frames.  Error control is normally achieved through a trailer added to the end of the frame.  Access control:  When two or more devices are connected to the same link, data link layer protocols are necessary to determine which device has control over the link to transmit data at any given time.

10 Data Link Layer Node-to-node delivery

11 Data Link Layer Node-to-node delivery  As the figure shows, communication at the data link layer occurs between two adjacent nodes.  To send data from A to F, three partial deliveries are made.  First, the DL layer at A sends a frame to the DL layer at B (a router).  Second, the DL layer at B sends a new frame to the DL layer at E.  Finally, the DL layer at E sends a new frame to the DL layer at F.  Note that the frames that are exchanged between the three nodes have different values in the headers.  The frame from A to B has B as the destination address and A as the source address.  The frame from B to E has E as the destination address and B as the source address.  The frame from E to F has F as the destination address and E as the source address.  The values of the trailers can also be different if error checking includes the header of the frame.

12 Data Link Layer Node-to-node delivery  In figure below, 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 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.

13 Data Link Layer Node-to-node delivery In most data link protocols, the destination address comes before the source address. Header

14 Data Link Layer Node-to-node delivery  Here, we have a bus topology for an isolated LAN.  In a bus topology, the frame is propagated in both directions.  The frame propagated to the left dies when it reaches the end of the cable if the cable end is terminated appropriately.  The frame propagated to the right is sent to every station on the network.  Each station with a physical addresses other than 87 drops the frame because the destination address in the frame does not match its own physical address.  The intended destination computer, however, finds a match between the destination address in the frame and its own physical address.  The frame is checked, the header and trailer are dropped, and the data part is de-capsulated and delivered to the upper layer.

15 Data Link Layer Node-to-node delivery

16 Extra Material Devices and layers

17 Data Link Layer  Data Link layer is responsible for transferring information between network segments of a LAN.  The Data Link layer must defer to the Network layer to go beyond the LAN; when going out to the Internet, for example.  In the context of a LAN, the Data Link layer can handle all the communications that would be handled by the Network layer in the context of a WAN

18 Data Link Layer  Data Link layer is made up of two independent sub-layers:  LLC (Logical Link Control)  MAC (Media Access Control)  MAC sub-layer sits closest to the Physical layer.  LLC sub-layer sits on top of that, directly underneath the Network layer.  When the Data Link layer receives data for the Physical layer, it formats that data into bit form for transmission over the network:  As it sends the bits off over the Physical layer, it attaches instructions to the Data Link layer on the destination system so that the destination Data Link layer can properly reconstruct the data.

19 Data Link Layer

20 Logical Link Control (LLC) sub-layer  LLC sub-layer is not dependent on any one topology.  Services provided by the LLC sub-layer:  Transmitting data using both connectionless and connection-oriented services  Connectionless services allow faster networks because they don’t involve the extended error checking that connection-oriented services do.  Connectionless services are often used at the LLC sub-layer because the Transport layer does its own, better error checking anyway, and so any error checking at the LLC sub-layer is redundant, in any case.  Acknowledging, sequencing, and controlling data traffic.  Flow control of data between network devices running at different speeds  Establishing, maintaining, and terminating links to remote resources  Connecting Network layer protocols to MAC sub-layer protocols  Checking for corrupted data and forcing the data to be re-sent in case corruption is found

21 Data Link Layer Media Access Control (MAC) sub-layer  Each NIC is assigned a MAC (media access control) address, and the MAC sub-layer of the DL layer uses these addresses to route the data to its destination.  The MAC sub-layer sits just above the Physical layer and works directly with the NICs on the Physical layer.  Working of MAC sub-layer:  When receives the data from the LLC sub-layer, the MAC sub-layer determines the media, electronic signals, and MAC addresses that will be required to get the data to its destination.  The MAC sub-layer reformats the data based on what it found out in step 1.  The MAC sub-layer then listens in on the network to make sure that all’s quite, and when it is sure that the coast is clear, it sends the data over the network via the Physical layer.

22 Data Link Layer Media Access Control (MAC) sub-layer

23 Network Layer  The network layer is responsible for the source-to-destination delivery of a packet, possibly across multiple networks (links).  Whereas the data link layer oversees the delivery of the packet between two systems on the same network (links), the network layer ensures that each packet gets from its point of origin to its final destination.  If two systems are connected to the same link, there is usually no need for a network layer.  However, if the two systems are attached to different networks (links) with connecting devices between the networks (links), there is often a need for the network layer to accomplish source-to-destination delivery. The network layer is responsible for the delivery of packets from the original source to the final destination. The network layer gets each packet to the correct computer

24 Network Layer Relationship of the network, data link and transport layers

25 Network Layer Other Responsibilities of the network layer  Logical addressing:  The physical addressing implemented by the data link layer handles the addressing problem locally.  If a packet passes the network boundary, we need another addressing system to help distinguish the source and destination systems.  The network layer adds a header to the packet coming from the upper layer that, among other things, includes the logical addresses of the sender and receiver.  Routing:  Routing is the process of moving data from one network segment to another, and this is the main function of the Network layer.  When two or more independent networks or links are successfully connected to create intemetworks (network of networks) or a large network, the connecting devices (called routers or switches) route or switch the packets to their final destination.  One of the functions of the network layer is to provide this mechanism.

26 Network Layer Source-to-destination ( end-to-end ) delivery

27 Network Layer  In the above figure, we need a source-to-destination delivery.  The network layer at A sends the packet to the network layer at B.  When the packet arrives at router B, the router makes a decision based on the final destination (F) of the packet. Router B uses its routing table to find that the next hop is router E.  The network layer at B, therefore, sends the packet to the network layer at E.  The network layer at E, in turn, sends the packet to the network layer at F.

28 Network Layer  In below figure, 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 can’t use physical addresses only; the physical addresses only have local jurisdiction.  What we need here are universal addresses that can pass through the LAN boundaries.  The network (logical) addresses have this characteristic.

29 Network Layer

30  Figure below shows an example of an internetworks made up of two LANs connected by routers into a small internetwork. The most visible example of an internetwork is the Internet, which uses thousands upon thousands of routers and IP addresses to allow the internetworking of computers worldwide.

31 Network Layer  The network layer operates independently of the physical medium, which is a concern of the physical layer.  Routers are network layer devices, they can be used to forward packets between physically different networks.  It adds a header to the messages that includes the source and destination network address.  This combination of data plus the network layer is called a packet.  It translates logical addresses and names into physical addresses for Packets delivery.  The addressing which makes this delivery possible can be thought of as a universal address as compared to the local addressing of the MAC.  It determines routes for sending data.

32 Transport Layer  The transport layer is responsible for process-to-process delivery of the entire message.  A process is an application program running on a host.  Whereas the network layer oversees source-to-destination delivery of individual packets, it does not recognize any relationship between those packets. It treats each one independently, as though each piece belonged to a separate message, whether or not it does.  The transport layer, on the other hand, ensures that the whole message arrives intact and in order, overseeing both error control and flow control at the source-to-destination level.

33 Transport Layer Relationship of the transport, network, and session layers The transport layer is responsible for delivery of a message from one process to another. The transport layer gets the entire message to the correct process on that computer

34 Transport Layer Other Responsibilities of the network layer  Service-point addressing:  Computers often run several programs at the same time. For this reason, source-to-destination delivery means delivery not only from one computer to the next but also from a specific process (running program) on one computer to a specific process (running program) on the other.  The transport layer header must therefore include a type of address called a service-point address (or port address).  The network layer gets each packet to the correct computer.  The transport layer gets the entire message to the correct process on that computer.  Segmentation and reassembly:  A message is divided into transmittable segments, with each segment containing a sequence number. These numbers enable the transport layer to reassemble the message correctly upon arriving at the destination and to identify and replace packets that were lost in transmission.

35 Transport Layer Other Responsibilities of the network layer  Connection control:  The transport layer can be either connection-less or connection- oriented.  A connectionless transport layer treats each segment as an independent packet and delivers it to the transport layer at the destination machine.  A connection-oriented transport layer makes a connection with the transport layer at the destination machine first before delivering the packets. After all the data are transferred, the connection is terminated.  Flow control:  Like the data link layer, the transport layer is responsible for flow control. However, flow control at this layer is performed end to end rather than across a single link.

36 Transport Layer Other Responsibilities of the network layer  Error control:  Like the data link layer, the transport layer is responsible for error control. However, error control at this layer is performed process-to- process rather than across a single link.  The sending transport layer makes sure that the entire message arrives at the receiving transport layer without error (damage, loss, or duplication).  Error correction is usually achieved through retransmission.

37 Transport Layer Reliable process-to-process delivery of a message

38 Transport Layer Example  Figure below shows an example of transport layer communication.  Data coming from the upper layers have port addresses j and k:  j is the address of the sending process  k is the address of the receiving process  Since the data size is larger than the network layer can handle, the data are split into two packets, each packet retaining the port addresses (j and k).  Then in the network layer, network addresses (A and P) are added to each packet.

39 Transport Layer Example

40 Transport Layer  It translates system names into addresses.  It divides messages into fragments that fit within the size limitations established by the network.  It allows users to segment/reassemble several upper layer application on to the same transport data stream.  This layer is responsible for addressing, managing network traffic problems, data congestion, and reassembling data at the receiving end to recover the original message.  It ensures that the segments delivered will be acknowledged back to sender.  It provides retransmission of segments those are not acknowledged.  It puts segments back into their correct sequence at the destination.

41 Transport Layer  To enable packets reassembly in their original order, this layer includes a messages sequence number in its header.  Transport layer assigns a service access point (SAP ID) to each packet.  In TCP/IP terms that is called a port.  One more responsibility of the transport layer is detecting errors in transmitting data.

42 Session Layer  The session layer is the network dialog controller.  It establishes, maintains, and synchronizes the interaction among communicating systems. The session layer is responsible for dialog control and synchronization. It provides mechanism for managing end-user, host, process operations, termination and restart procedures.  Sessions enable communication in organized manner in three phases as:  Connection establishment  Data transfer  Connection release

43 Session Layer Other Responsibilities of the session layer  Dialog control:  Dialog is a formal conversation in which two nodes agree to exchange data.  The session layer allows two systems to enter into a dialog. It allows the communication between two processes to take place in either half duplex or full-duplex mode.  Synchronization:  The session layer allows a process to add checkpoints, or synchronization points, to a stream of data.  For example, if a system is sending a file of 2000 pages, it is advisable to insert checkpoints after every 100 pages to ensure that each 100-page unit is received and acknowledged independently.  In this case, if a crash happens during the transmission of page 523, the only pages that need to be resent after system recovery are pages 501 to 523. Pages previous to 501 need not be resent.

44 Session Layer Relationship of the session, transport, and presentation layers

45 Presentation Layer  The presentation layer is concerned with the syntax and semantics of the information exchanged between two systems.  This layer provides data representation and code formatting.  It provides a way for a remote host to inform the local client how to present the data to the application or client.  It ensures that the data that arrives from the network can be used by the application, and information sent by the application can be transmitted on the network.

46 Presentation Layer Relationship of the presentation, session, and application layers

47 Presentation Layer  It directly translates data from one format to another.  It provides data encryption, decryption and compression, decompression.  It delivers format information for application layer processing.  It removes the syntactical differences in data representation within the end-user systems. The presentation layer is responsible for translation, compression, and encryption.

48 Presentation Layer  Translation: The processes (running programs) in two systems are usually exchanging information in the form of character strings, numbers, and so on. The information must be changed to bit streams before being transmitted. Because different computers use different encoding systems, the presentation layer is responsible for interoperability between these different encoding methods. The presentation layer at the sender changes the information from its sender-dependent format into a common format. The presentation layer at the receiving machine changes the common format into its receiver-dependent format.  Encryption: To carry sensitive information, a system must be able to ensure privacy. Encryption means that the sender transforms the original information to another form and sends the resulting message out over the network. Decryption reverses the original process to transform the message back to its original form.  Compression: Data compression reduces the number of bits contained in the information. Data compression becomes particularly important in the transmission of multimedia such as text, audio, and video. Responsibilities of the presentation layer

49 Application Layer  The application layer enables the user to access the network and provides different services to user applications.  It provides user interfaces and support for services such as electronic mail, remote file access and transfer, shared database management, and other types of distributed information services.  Of the many application services available, the figure shows only three:  X.400 (message-handling services),  X.500 (directory services), and  file transfer, access, and management (FTAM). Application layer is responsible for providing services to the user.

50 Application Layer Relationship of the presentation, session, and application layers

51 Application Layer Responsibilities/Services of the Application layer  Network virtual terminal:  A network virtual terminal is a software version of a physical terminal, and it allows a user to log on to a remote host. To do so, the application creates a software emulation of a terminal at the remote host. The user's computer talks to the software terminal which, in turn, talks to the host, and vice versa. The remote host believes it is communicating with one of its own terminals and allows the user to log on.  File transfer, access, and management:  This application allows a user to access files in a remote host (to make changes or read data), to retrieve files from a remote computer for use in the local computer, and to manage or control files in a remote computer locally.  Mail services:  This application provides the basis for e-mail forwarding and storage.  Directory services:  This application provides distributed database sources and access for global information about various objects and services.

52 Summery of layers

53

54

55 Mnemonics  The following mnemonics may help you remember the layers sequence and names: 1.“People Design Networks To Send Packets Accurately” 2.“Please Do Not Take Sales People's Advice” 3.“Always Put Some Thought Into Designing Programs” 4.“All People Seem To Need Data Permanently” 5.“Please Do Not Touch Screens Physically. Avoid.”


Download ppt "Lecture Focus: Data Communications and Networking  Network Models  Data Link Layer  Network Layer  ……… Lecture 10 CSCS 311."

Similar presentations


Ads by Google