1 of 39

Computer Networks�Lecture - 02

2 of 39

2

Protocol Hierarchy

  • Sender - Encoder
  • Message
  • Medium
  • Receiver – Decoder
  • Feedback

Components for Communication

3 of 39

3

Protocol Hierarchy

Type of connection:

  • Point-to-point
  • Multi-point

Physical Structure

4 of 39

4

Protocol Hierarchy

Data Flow of Messages

5 of 39

5

Protocol Hierarchy

  • The network topology defines the way in which computers, printers, and other devices are connected.
  • A network topology describes the layout of the wire and devices as well as the paths used by data transmissions.

Network Topology

6 of 39

6

Protocol Hierarchy

Advantages:

  • Simple to use and install.
  • If a node fails, it will not affect other nodes.
  • Less cabling is required.
  • Cost-efficient to implement.

Disadvantages:

  • Efficiency is less when nodes are more
  • If the bus fails, the network will fail.
  • A limited number of nodes can connect to the bus due to limited bus length.
  • Security issues and risks are more as messages are broadcasted to all nodes.

Bus Topology

7 of 39

7

Protocol Hierarchy

Advantages:

  • Easy Installation.
  • Less Cabling Required.
  • Reduces chances of data collision.
  • Easy to troubleshoot.
  • Each node gets the same access time.

Disadvantages:

  • If a node fails, the whole network will fail.
  • Slow data transmission speed(each message has to go through the ring path).
  • Difficult to reconfigure(we have to break the ring).

Ring Topology

8 of 39

8

Protocol Hierarchy

Advantages:

  • Centralized control.
  • Less Expensive.
  • Easy to troubleshoot.
  • Good fault tolerance due to centralized control on nodes.
  • If a node fails, it will not affect other nodes.
  • Easy to reconfigure and upgrade.

Disadvantages:

  • If the central device fails, the network will fail.
  • The number of devices in the network is limited(due to limited input-output port in a central device).

Star Topology

9 of 39

9

Protocol Hierarchy

Advantages:

  • Very fast communication.
  • Dedicated links facilitate direct communication.
  • No congestion or traffic problems on the channels.
  • Good Fault tolerance due to the dedicated path for each node.
  • Maintains privacy and security due to a separate channel for communication.
  • If a node fails, other alternatives are present in the network.

Disadvantages:

  • Very high cabling required.
  • Cost inefficient to implement.
  • Complex to implement and takes large space to

install the network.

  • Installation and maintenance are very difficult.

Mesh Topology

10 of 39

10

Protocol Hierarchy

Advantages:

  • Large distance network coverage.
  • Fault finding is easy by checking each hierarchy.
  • Least or no data loss.
  • A Large number of nodes can be connected directly or indirectly.
  • Other hierarchical networks are not affected if one of them fails.

Disadvantages:

  • Cabling and hardware cost is high.
  • Complex to implement.
  • Hub cabling is also required.
  • A large network using tree topology is hard to manage.
  • It requires very high maintenance.
  • If the main bus fails, the network will fail.

Tree Topology

11 of 39

11

Protocol Hierarchy

Advantages:

  • It can handle a large volume of nodes.
  • It provides flexibility to modify the network according to our needs.
  • Very Reliable(if one node fails it will not affect the whole network).

Disadvantages:

  • Complex design.
  • Expensive to implement.
  • Multi-Station Access Unit(MSAL) required.

Hybrid Topology

12 of 39

12

Protocol Hierarchy

  • To reduce their design complexity, most networks are organized as a stack of layers or levels, each one built upon the one below it.

  • The purpose of each layer is to offer certain services to the higher layers while shielding those layers from the details of how the offered services are actually implemented.

  • When layer n on one machine carries on a conversation with layer n on another machine, the rules and conventions used in this conversation are collectively known as the layer n protocol.

  • Basically, a protocol is an agreement between the communicating parties on how communication is to proceed.

Protocol Hierarchy

13 of 39

13

A five-layer network is illustrated in Fig. below. The entities comprising the corresponding layers on different machines are called peers. The peers may be software processes, hardware devices, or even human beings. In other words, it is the peers that communicate by using the protocol to talk to each other.

Protocol Hierarchy

14 of 39

14

Protocol Hierarchy

  • In reality, no data are directly transferred from layer n on one machine to layer n on another machine. Instead, each layer passes data and control information to the layer immediately below it, until the lowest layer is reached. Below layer 1 is the physical medium through which actual communication occurs.

  • Between each pair of adjacent layers is an interface. The interface defines which primitive operations and services the lower layer makes available to the upper one

15 of 39

15

Protocol Hierarchy

16 of 39

16

OSI and TCP/IP Reference Models

The OSI model is shown in Figure below. The model is called the ISO OSI (Open Systems Interconnection) Reference Model because it deals with connecting open systems—that is, systems that are open for communication with other systems. The OSI model has seven layers.

17 of 39

17

An exchange using OSI Model

An exchange using OSI Model

18 of 39

18

The Physical Layer

The Physical Layer

19 of 39

19

The Physical Layer

  • The physical layer is concerned with transmitting raw bits over a communication channel.
  • Deals with all aspects of physically moving data from one computer to the next
  • Converts data from the upper layers into 1s and 0s for transmission over media
  • Defines how data is encoded onto the media to transmit the data
  • Defined on this layer: Cable standards, wireless standards, and fiber optic
  • standards.
  • Copper wiring, fiber optic cable, radio frequencies, anything that can be used to
  • transmit data is defined on the Physical layer of the OSI Model
  • Device example: Hub
  • Used to transmit data

The Physical Layer

20 of 39

20

The Data Link Layer

The Data Link Layer

21 of 39

21

The Data Link Layer

Responsibilities of the data link layer include the following:

Framing. The data link layer divides the stream of bits received from the network layer into manageable data units called frames.

Physical addressing: 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: 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.

The Data Link Layer

22 of 39

22

Error control. 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 at any given time.

Encapsulation = frame

Requires MAC address or physical address

The Data Link Layer

The Data Link Layer

23 of 39

23

The Data Link Layer

24 of 39

24

The Network Layer

  • The network layer controls the operation of the subnet. A key design issue is determining how packets are routed from source to destination.

  • If too many packets are present in the subnet at the same time, they will get in one another’s way, forming bottlenecks. Handling congestion is also a responsibility of the network layer, in conjunction with higher layers that adapt the load they place on the network.

25 of 39

25

The Network Layer

26 of 39

26

The 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.

 

27 of 39

27

The Transport Layer

28 of 39

28

Reliable process-to-process delivery of a message

29 of 39

29

The Transport Layer

Other responsibilities of the transport layer include the following:

  • 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. 

30 of 39

30

The Transport Layer

  • Connection control. The transport layer can be either connectionless 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.
  • 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).

31 of 39

31

The Session Layer

The session layer allows users on different machines to establish sessions between them. Sessions offer various services, including dialog control (keeping track of whose turn it is to transmit) and synchronization (check pointing long transmissions to allow them to pick up from where they left off in the event of a crash and subsequent recovery).

32 of 39

32

  • Dialog control. 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 (one way at a time) or full-duplex (two ways at a time) 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 600. Pages previous to 501 need not be resent.

 

The Session Layer

33 of 39

33

The Presentation Layer

Unlike the lower layers, which are mostly concerned with moving bits around, the presentation layer is concerned with the syntax and semantics of the information transmitted.

Specific responsibilities of the presentation layer include the following:

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.

34 of 39

34

The Presentation Layer

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.

35 of 39

35

The Application Layer

The application layer enables the user, whether human or software, to access the network. 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.

36 of 39

36

The Layers

37 of 39

37

The Layers

38 of 39

38

The Layers

39 of 39

Thanks!

Any questions?

You can find me at:

minhazularefin21@gmail.com

39