/*Google Adsense */
Showing posts with label Networking Sofware. Show all posts
Showing posts with label Networking Sofware. Show all posts

Relationship of Services to Protocols

Service is a set of primitives (operations) that a layer provides to the layer prepared to perform on above it. The service defines what operations the layer is prepared behalf of its users, but it says nothing at all about how these operations are implemented. A service relates to an interface between two layers, with the lower layer being the service provider and the upper layer being the service user.

A protocol is a set of rules governing the format and meaning of frames, packets, or messages that are exchanged by the peer entities within a layer. Entities use protocols in order to implement their service definitions. They are free to change their protocols at will, provided they do not change the service visible to their users. In this way, the service and the protocol are completely decoupled.

Service Primitives

A service is formally specified by a set of primitives (operations) available to a user or other entity to access the service. These primitives tell the service to perform some action or report on an action taken by a peer entity. Service primitives are divided into four classes. They are:

OperationsMeaning
RequestAn entity wants the service to do some work
IndicationAn entity is to be informed about an event
ResponseAn entity wants to respond to an event
ConfirmThe response to an earlier request has come back

Connection-Oriented and Connectionless Services

Layers can offer different types of services to the layers above them:
  • Connection-oriented
  • Connectionless.

In the Connection-oriented service, the service user first establishes a connection, uses the connection and then releases the connection. The essential aspect of a connection is that it acts like a tube: the sender pushes objects (bits) in at one end, and the receiver takes them out in the same order at the other end.

In the Connectionless service, each message carries the full destination address and each one is routed through the system independent of all the others. Normally, when two messages are sent to the same destination, the first one sent will be the first one to arrive. However, it is possible that the first one sent. It can be delayed so that the second one arrives first. With a connection-oriented service this is impossible.

Interfaces and Services

The function of each layer is to provide services to the layer above it. The active elements in each layer are often called entities. An entity can be a software entity ( such as a process ) or a hardware entity ( such as an intelligent 1/0 chip ). Entities in the same layer on different machines are called peer entities. The entities in layer n implement a service used by layer n+1. In this case layer n is called the service provider and layer n+1 is called the service user. Layer n may use the services of layer n-1 in order to provide its service. It may offer several classes of service, for example, fast, expensive communication and slow, cheap communication.

Services are available at SAPs (Service Access Points), the layer n SAP is the places where layer n+1 can access the services offered. Each SAP has an address that uniquely identifies itself. To make this point clearer, the SAPs in the telephone system are the sockets into which modular telephones can be plugged and the SAP addresses are the telephone numbers of these sockets. To call someone, caller's SAP address should be known. Similarly, in the postal system, the SAP addresses are street addresses and post office box numbers. To send a letter, the addressee's SAP address should be known.

In order for two layers to exchange information, there has to be an agreed upon set of rules about the interface. At a typical interface, the layer n+1 entity passes an IDU (Interface Data Unit) to the layer n entity through the SAP. The IDU consists of an SDU (Service Data Unit) and some control information. The SDU is the information passed across the network to the peer entity and then up to layer n+1. The control information is needed to help the lower layer do its job (e.g. the number of bytes in the SDU) but is not part of the data itself.

In order to transfer the SDU, the layer n entity may have to fragment it into several pieces, each of which is given a header and sent as a separate PDU (Protocol Data Unit) such as a packet. The PDU headers are used by the peer entities to carry out their peer protocol. They identify which PDUs contain data and which contain control information, provide sequence numbers and counts, and so on.

Design - Issues for the Layers

Every layers needs a mechanism for identifying senders and receivers. Since a network normally has many computers, some of which have multiple processes, a means is needed for a process on one machine to specify with whom it wants to talk. As a consequence of having multiple destinations, some form of addressing is needed in order to specify a specific destination.

Another set of design decisions concerns the rules for data transfer. In some systems, data only travel in one direction (simplex communication). In others they can travel -in either direction, but not simultaneously (half-duplex communication). In still others, they travel in both directions at once (full-duplex communication). The protocol must also determine how many logical channels the connection corresponds to and what their priorities are. Many networks provide at least two logical channels per connection, one for normal data and one for urgent data.

Protocol Hierarchies

Networks are organized as a series of layers or levels, to reduce their design complexity. The number of layers, the name of each layer, the contents of each layer and the function of each layer differ from network to network.

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. The entities comprising the corresponding layers on different machines are called peers. In other words, it is the peers that communicate using the protocol.

In reality, no data 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. Between each pair of adjacent layers there is an interface. The interface defines which primitive operations and services the lower layer offers to he upper one.

A set of layers and protocols is called network architecture. The specification of architecture must contain enough information to allow an implementer to write the program or build the hardware for each layer so that it will correctly obey the appropriate protocol.

Networking Software

In the beginning computer networks were designed with the hardware as the main concern and the software as a secondary thing. This strategy no longer works. Network software is now highly structured. The following sections describe the software structuring technique.
  • Protocol Hierarchies
  • Design - Issues for the Layers
  • Interfaces and Services
  • Connection - Oriented and Connectionless Services
  • Service Primitives
  • Relationship of Services to Protocols