Data Communication and Networking

Chapter 2
Network Architectures, Models and Protocols

Diploma in Computer Architecture and Networking
Data Communication and Networking   •   Diploma

Network Architectures, Models and Protocols

Introduction

Computer networks are complex systems in which many devices, transmission media, software components and administrative organisations cooperate. A message sent from a web browser may pass through a wireless access point, switches, routers, firewalls and several telecommunications networks before reaching a server. The receiving system must interpret the message correctly even though the two end systems may use different hardware and communicate across many intermediate devices.

Network architecture provides an organised way to design and understand this complexity. It identifies the functions required for communication, assigns those functions to layers or components, and defines the rules by which components interact. A protocol is a set of rules governing communication. A model is a conceptual framework used to describe those functions and their relationships; it is not necessarily a complete implementation.

The two most important reference frameworks are the Open Systems Interconnection (OSI) model and the Internet protocol suite, commonly called the TCP/IP model. The OSI model is particularly useful for learning, analysis and troubleshooting. TCP/IP is the practical foundation of the modern Internet.

Learning Objectives

By the end of this chapter, a student should be able to:

  1. Explain why layered network architectures are used.
  2. Describe the seven layers of the OSI reference model.
  3. Relate the OSI model to the TCP/IP protocol suite.
  4. Explain encapsulation, decapsulation and protocol data units.
  5. Distinguish services, interfaces and protocols.
  6. Identify important standards organisations and their roles.
  7. Compare client-server and peer-to-peer architectures.
  8. Apply layered models to practical network troubleshooting and design.

1. The Need for Layered Communication

A communication system performs several logically different tasks. It must represent data, identify communicating applications, deliver information to the correct host, select routes, transfer frames across an individual link, and transmit signals through a medium. Combining all these responsibilities into one large protocol would make development, testing and maintenance difficult.

Layering divides communication into manageable functional levels. Each layer:

  • provides services to the layer above;
  • uses services supplied by the layer below;
  • communicates logically with the corresponding layer at the remote system; and
  • hides unnecessary implementation details from other layers.

For example, an application does not need to know whether its data is carried over copper cable, fibre, radio or a satellite link. The application uses a service such as reliable byte delivery, while lower layers handle addressing, routing and transmission.

Layering has several advantages. It promotes modularity, allows a protocol at one layer to be replaced without redesigning every other layer, supports interoperability between vendors, and simplifies fault isolation. It also permits independent technological development: wireless technologies can evolve while application protocols remain stable.

Layering is not free of disadvantages. Headers add overhead, functions may be duplicated at different layers, and strict separation can make optimisation more difficult. A practical protocol suite therefore uses layering as a design principle rather than as an absolute prohibition against interaction between layers.

Peer-layer communication and actual transmission

Communication between corresponding layers on two hosts is called peer-to-peer or logical communication. The transport layer on one host is logically communicating with the transport layer on another host, even though the actual bits are transmitted through lower layers and physical media. In reality, data moves vertically down the protocol stack at the sender, across the network, and vertically up the stack at the receiver.

2. The OSI Reference Model

The OSI model, standardised by the International Organization for Standardization (ISO), contains seven layers. It is a reference model: it describes functions and relationships rather than requiring every network to implement seven separate protocols.

LayerNameMain responsibilitiesTypical examples
7ApplicationNetwork services directly used by applicationsHTTP, DNS, SMTP, FTP
6PresentationData representation, translation, compression and encryptionCharacter encoding, data formats, TLS-related functions
5SessionEstablishing, managing and terminating logical sessionsDialog control, checkpoints
4TransportEnd-to-end delivery, reliability, flow control and multiplexingTCP, UDP
3NetworkLogical addressing and routing between networksIP, ICMP, routers
2Data LinkFraming, local delivery, medium access and error detectionEthernet, Wi-Fi MAC, switches
1PhysicalTransmission of raw bits as signalsCopper, fibre, radio, connectors

2.1 Physical layer

The physical layer specifies how bits are represented and transmitted. Its concerns include electrical or optical signals, radio frequencies, modulation, bit timing, connectors, pin arrangements and transmission media. It does not interpret the meaning of a message or decide which application should receive it.

A physical-layer problem may result from a damaged cable, incorrect connector, radio interference, loss of optical power or incompatible signalling parameters. Hubs and repeaters operate mainly at this layer.

2.2 Data-link layer

The data-link layer provides communication across a single local link or network segment. It groups bits into frames, uses hardware or link-layer addresses, controls access to a shared medium and commonly detects transmission errors using a frame check sequence.

Ethernet and Wi-Fi define important data-link functions. A bridge or Ethernet switch examines link-layer addresses and forwards frames within a local network. A frame normally has a header and trailer in addition to the payload supplied by the network layer.

Data-link delivery is usually local. A frame is not carried unchanged across every network between a source and a destination. At each router, the old link-layer frame is removed and a new frame appropriate to the next link is created.

2.3 Network layer

The network layer provides logical addressing and delivery across interconnected networks. Internet Protocol (IP) addresses identify interfaces in a way that supports routing. Routers inspect network-layer information and select a next hop according to routing information.

The network layer normally offers a best-effort datagram service. IP does not, by itself, guarantee delivery, ordering or duplicate prevention. These functions may be provided by a higher-layer protocol such as TCP or by the application itself.

2.4 Transport layer

The transport layer provides process-to-process communication between applications running on end systems. It uses port numbers to distinguish applications and may provide reliability, sequencing, flow control and congestion control.

TCP provides a connection-oriented, reliable byte-stream service. It acknowledges received data, retransmits selected lost data and presents an ordered stream to the application. UDP provides a connectionless datagram service with low protocol overhead; it does not guarantee delivery, ordering or retransmission. Applications using UDP must tolerate loss or implement any required recovery themselves.

2.5 Session layer

The session layer manages dialogues or logical conversations between applications. Its theoretical functions include establishing and terminating sessions, controlling which party transmits, and placing checkpoints in long exchanges. In many modern Internet systems, session functions are incorporated into application or transport protocols rather than being implemented as a distinct layer.

2.6 Presentation layer

The presentation layer concerns the syntax and representation of information. It may translate character encodings, negotiate data formats, compress information and encrypt or decrypt data. For example, two systems may use different internal representations but exchange data using a common encoding such as UTF-8 or a structured format such as JSON.

Encryption is often described in textbooks as a presentation-layer function, but in practical Internet implementations security mechanisms such as TLS do not fit perfectly into one OSI layer. This illustrates that the OSI model is an analytical framework, not a literal map of every protocol.

2.7 Application layer

The application layer provides network services to user applications and system processes. It includes protocols for web access, name resolution, electronic mail, file transfer, remote administration and network management. An application-layer protocol defines message formats, meanings, sequencing rules and expected responses.

The application layer is not the same as the application program itself. A browser is an application; HTTP is an application-layer protocol used by browsers and web servers.

3. The TCP/IP Model

The TCP/IP model developed from research associated with the United States Department of Defense and the Internet engineering community. Its layers are commonly presented in four levels:

TCP/IP layerMain roleApproximate OSI correspondence
ApplicationApplication protocols and data representationOSI layers 5–7
TransportEnd-to-end process communicationOSI layer 4
InternetInternetwork addressing and routingOSI layer 3
Link or network accessLocal delivery and physical transmissionOSI layers 1–2

Some textbooks use a five-layer version by separating the physical and data-link functions. Both descriptions are useful if their terminology is stated clearly.

The TCP/IP model differs from OSI in history and purpose. OSI was designed as a general reference architecture before widespread deployment of the Internet suite. TCP/IP developed through working protocols and operational experience. Consequently, TCP/IP combines some OSI layers and does not require a separate session or presentation layer.

Mapping examples

HTTP, DNS and SMTP belong to the TCP/IP application layer. TCP and UDP belong to the transport layer. IPv4, IPv6 and ICMP belong primarily to the Internet layer. Ethernet and Wi-Fi provide link-layer functions, while their signalling specifications operate at the physical level.

The mapping is approximate. A protocol may perform functions that cross textbook boundaries, and a single application may use several protocols. For instance, a web transaction may use HTTP, TLS, TCP, IP, Ethernet and a physical medium.

4. Protocols, Services and Interfaces

These three terms are related but should not be confused.

A protocol is a set of rules used by peer entities to communicate. It specifies message formats, field meanings, ordering, error handling and state transitions. HTTP request syntax and TCP acknowledgement behaviour are protocol matters.

A service is what one layer offers to the layer above. A transport layer may offer reliable ordered delivery, while a network layer may offer best-effort datagram delivery. The service describes capability without necessarily specifying how the capability is implemented.

An interface is the boundary through which a layer accesses a service. In an operating system, a socket API is an important interface through which applications request transport services. A programmer can call an operation such as opening a connection or sending data without implementing TCP’s retransmission algorithm.

The distinction can be expressed as follows:

  • peer layers use protocols to communicate with one another;
  • adjacent layers interact through service interfaces;
  • a service is the capability made available at an interface.

This distinction helps network engineers change an implementation while preserving the service expected by users or higher layers.

5. Encapsulation, Decapsulation and Protocol Data Units

When an application sends data, each lower layer normally adds control information. This process is called encapsulation. At the destination, each layer removes and interprets the information intended for it; this is decapsulation.

The data unit associated with a particular layer is called its protocol data unit (PDU). Common names are:

Layer or functionCommon PDU name
Application, presentation or sessionData or message
TransportSegment for TCP; datagram for UDP
Internet/networkPacket or IP datagram
Data linkFrame
PhysicalBits or symbols

Terminology can vary. In particular, “datagram” may refer to a connectionless transport unit or an IP packet, so the protocol context should always be stated.

Suppose a user sends an HTTP request over TCP and IPv4 on Ethernet. The application creates an HTTP message. TCP adds a header containing source and destination ports and other control fields, producing a TCP segment. IP adds source and destination IP addresses, producing an IP packet. Ethernet adds a frame header and trailer containing local link addresses and error-detection information. The physical layer transmits the resulting frame as signals.

At the receiver, Ethernet checks and removes its frame information, IP processes the packet, TCP verifies and reorders the segment if necessary, and the HTTP data is delivered to the web application.

Encapsulation is not simply the repeated addition of arbitrary labels. Each header has a defined scope and purpose. A router normally removes the incoming link-layer frame and encapsulates the IP packet in a new link-layer frame. The IP source and destination usually remain unchanged during ordinary routing, although fields such as the hop limit or time-to-live change.

Addressing at different layers

Different layers use different identifiers because they solve different problems:

  • Application identifiers, such as a URL or an email address, identify a resource or service.
  • Transport port numbers identify processes or service endpoints on a host.
  • IP addresses identify network interfaces for internetwork delivery.
  • Link-layer addresses identify interfaces on a local network.

Confusing these address types causes many configuration and troubleshooting errors.

6. Standards and Standards Organisations

Interoperability depends on shared technical specifications. Standards may be formal or de facto. A formal standard is published through an established standards process; a de facto standard becomes widely adopted through use, even if it did not originate in a formal standards organisation.

Important organisations include:

OrganisationMain contribution
ISOInternational standards, including the OSI reference model
IECInternational electrotechnical standards, often jointly with ISO
IETFInternet standards and protocols; publishes RFCs
IEEENetworking and communications standards, including Ethernet and Wi-Fi families
ITU-TInternational telecommunications recommendations
ICANN and IANA-related functionsCoordination of names, numbers and protocol registries
W3CStandards and specifications for major Web technologies

An IETF document is called an RFC, or Request for Comments. RFC status varies: some are proposed standards, Internet standards, informational documents or experimental specifications. Publication as an RFC does not automatically mean that every RFC is a mandatory Internet standard.

Standards support vendor-neutral procurement, compatibility, security review and long-term maintenance. However, standards can lag behind technology, contain optional features that lead to interoperability differences, or be implemented with defects. Engineers must therefore consult the current specification, implementation documentation and security advisories.

7. Client-Server and Peer-to-Peer Architectures

Layered models describe protocol functions; client-server and peer-to-peer models describe how networked applications and resources are organised.

7.1 Client-server architecture

In a client-server architecture, a client requests a service and a server provides it. A web browser is a client, while a web server responds to HTTP requests. A database server stores and processes data for database clients.

A server may listen on a known address and port, authenticate clients, enforce access controls and maintain shared data. Centralisation simplifies administration, backup, auditing and policy enforcement. It also supports consistent updates and professional service management.

The disadvantages include possible bottlenecks, dependence on server availability and the cost of server infrastructure. These risks can be reduced through replication, load balancing, clustering, caching and geographically distributed deployment.

Client-server does not mean that only one server exists. A modern service may consist of many application servers, database systems, caches, identity services and content-delivery nodes.

7.2 Peer-to-peer architecture

In a peer-to-peer (P2P) architecture, participating systems can act as both clients and providers. Resources may be distributed among peers rather than controlled by one central server. File distribution, some voice and video systems, distributed ledgers and collaborative applications may use P2P techniques.

P2P systems can scale by adding peers, avoid a single central failure point and use resources close to users. Their challenges include peer availability, inconsistent performance, discovery, trust, security, data integrity and legal control over shared content. Many practical systems are hybrid: a central service performs discovery or authentication while peers exchange the actual data.

Comparison

CriterionClient-serverPeer-to-peer
ControlCentral or hierarchicalDistributed among peers
AdministrationRelatively straightforwardMore complex
Failure patternServer can be a critical dependencyIndividual peer failures may be tolerated
Security policyCentrally enforceableMore difficult to enforce uniformly
ScalabilityRequires server scaling and distributionMay grow with participating peers
Typical useWeb, enterprise databases, emailContent distribution, decentralised collaboration

8. Applied Case: Diagnosing a Failed Web Service

The following is an illustrative case.

Background

A college’s student portal is available to users on the campus network but cannot be reached from the Internet. Internal users can access other websites, and the portal server is operating normally.

Problem analysis

A layered investigation avoids random changes. At the physical and data-link layers, the campus gateway has power, link indicators are active and local devices communicate normally. At the Internet layer, the gateway has a valid address and can reach external IP addresses. A route examination shows that the public route to the portal was accidentally withdrawn from the campus border router.

At the transport layer, attempts to connect to the portal’s TCP service fail because traffic never reaches the server. DNS testing shows that the portal name resolves to the correct public address, so the application naming service is not the primary fault. The evidence points to routing rather than HTTP configuration.

Solution

The network administrator restores the correct route, verifies routing policy and checks that the firewall permits the intended TCP service. Tests are then performed from an external network. The administrator confirms name resolution, establishes a TCP connection, negotiates security, sends an HTTP request and receives the expected response.

Outcome and learning points

The service is restored without changing the web application. The case demonstrates that:

  1. a successful local link does not prove end-to-end reachability;
  2. DNS resolution and server application health are separate questions;
  3. protocols at different layers provide different evidence;
  4. troubleshooting should proceed from symptoms and measurements rather than assumptions; and
  5. packet captures and command-line tools are useful only when their observations are interpreted through a sound model.

Useful tools include cable and interface diagnostics, switch statistics, ping or equivalent reachability tests, traceroute, DNS query tools, socket inspection, firewall logs and packet analysers. These tools must be used with authorisation because captures may contain credentials or personal data.

9. Design, Security and Governance Considerations

A layered design should specify responsibilities clearly. Engineers should document addressing plans, protocol versions, interfaces, trust boundaries, failure modes and monitoring points. They should prefer well-supported standards and remove obsolete protocols where possible.

Security is not confined to one layer. Link encryption may protect a local wireless connection, IP-layer controls may filter traffic, transport security may protect a connection, and application authentication may protect an account or transaction. Confidentiality, integrity and availability should be considered together.

Network records can reveal user behaviour, locations and relationships. Packet capture, traffic inspection and logging should therefore follow organisational policy, applicable privacy law, data minimisation principles and access-control requirements. Administrators should retain only what is necessary, protect logs from alteration, and define retention periods.

Contemporary networks increasingly use virtualisation, software-defined networking, cloud services, content-delivery networks, IPv6, encrypted application protocols and zero-trust security principles. These developments do not eliminate layered reasoning. Instead, they introduce additional logical layers and control planes. Artificial intelligence and machine learning may assist anomaly detection or capacity planning, but their alerts require validation, and their training data and decisions must be governed responsibly.

Best Practices

  • Use the OSI model as a troubleshooting and communication vocabulary, while recognising that real protocols may cross layer boundaries.
  • Identify the PDU, address type and responsible device when analysing traffic.
  • Distinguish a protocol from the service it provides and the interface used to access that service.
  • Document protocol versions, optional features and dependencies.
  • Use standards from authoritative sources and verify their current status.
  • Apply defence in depth rather than relying on one security layer.
  • Test client-server and P2P systems under realistic load and failure conditions.
  • Protect diagnostic data and obtain permission before capturing traffic.

Chapter Summary

Network architectures organise the many functions needed for communication. Layering divides these functions into modules that provide services upward and use services downward. Peer layers communicate logically through protocols, while adjacent layers interact through service interfaces.

The seven-layer OSI model contains physical, data-link, network, transport, session, presentation and application layers. The practical TCP/IP model commonly groups these functions into application, transport, Internet and link or network-access layers. The models are complementary: OSI is valuable for explanation and diagnosis, while TCP/IP describes the protocol suite used by the Internet.

Encapsulation adds layer-specific control information as data moves down a sender’s stack; decapsulation removes and interprets it at the receiver. Application data becomes a transport segment or datagram, an IP packet, and a link-layer frame before transmission as bits or symbols. Different layers use different identifiers, including application names, ports, IP addresses and link-layer addresses.

ISO, IETF, IEEE, ITU-T, W3C and Internet coordination organisations contribute to interoperability through standards and registries. Client-server architectures centralise services and administration, whereas peer-to-peer architectures distribute roles and resources. Both models have strengths and limitations, and hybrid designs are common. Effective network professionals use layered reasoning, standards awareness, security controls and evidence-based troubleshooting.

Key Terms

Layered architecture: A design that divides communication functions into related levels.

Protocol: Rules governing message exchange between communicating entities.

Service: A capability offered by one layer to the layer above it.

Interface: A defined boundary through which a service is accessed.

OSI model: A seven-layer reference model for network communication.

TCP/IP model: A practical layered framework associated with the Internet protocol suite.

Encapsulation: Adding protocol control information as data moves down a stack.

Decapsulation: Removing and processing protocol information at the receiver.

Protocol data unit (PDU): The data unit associated with a particular protocol layer.

Segment: The usual PDU name for TCP transport data.

Datagram: A self-contained connectionless data unit, used by UDP or IP terminology.

Packet: A network-layer data unit, commonly an IP datagram.

Frame: A data-link-layer data unit.

Port number: A transport-layer identifier for an application endpoint.

Router: A device that forwards packets between networks.

Switch: A device that forwards frames within a local network.

Client-server architecture: An arrangement in which clients request services from servers.

Peer-to-peer architecture: An arrangement in which participating systems can provide and consume services.

Standards body: An organisation that develops, publishes or coordinates technical specifications.

Interoperability: The ability of different systems to communicate and work together.

Review Questions

5 Short Answer Questions

  1. Why is layering used in network architecture?
  2. State two main responsibilities of the transport layer.
  3. What is the difference between a protocol and a service?
  4. Define encapsulation and decapsulation.
  5. Name two standards organisations relevant to computer networking.

5 Long Answer Questions

  1. Describe all seven OSI layers and give an example of a technology or protocol associated with each.
  2. Compare the OSI and TCP/IP models, including their historical purposes and layer mappings.
  3. Explain the complete encapsulation process for an HTTP message sent using TCP, IP and Ethernet.
  4. Discuss the advantages and limitations of client-server and peer-to-peer architectures.
  5. Explain how layered reasoning can be applied to diagnose a web service that users cannot reach.

3 Analytical / Application Questions

  1. A workstation can access a local file share but cannot open any Internet website by name or IP address. Design a layered troubleshooting sequence and identify at least two possible faults at different layers.
  2. An organisation is choosing between a centralised file service and a peer-to-peer distribution system for a large training-video collection. Analyse the decision using control, scalability, security, availability and administration criteria.
  3. A packet capture shows an Ethernet frame containing an IPv6 packet, which contains a UDP datagram addressed to a particular port. Identify the PDU at each relevant layer and explain what each address or identifier accomplishes.

Multiple Choice Questions with Answers

Question 1

Which OSI layer is primarily responsible for routing packets between different networks?

A. Physical

B. Data Link

C. Network

D. Transport

Correct Answer: C. Network

Question 2

What is the correct order of units produced when application data is sent through TCP/IP and Ethernet?

A. Frame, packet, segment, data

B. Data, segment, packet, frame

C. Data, packet, frame, segment

D. Segment, data, frame, packet

Correct Answer: B. Data, segment, packet, frame

Question 3

Which statement best distinguishes a protocol from a service?

A. A protocol is a cable; a service is a connector

B. A protocol is a set of communication rules; a service is a capability offered to another layer

C. A protocol is always hardware; a service is always software

D. A protocol identifies a user; a service identifies a cable

Correct Answer: B. A protocol is a set of communication rules; a service is a capability offered to another layer

Question 4

Which transport protocol provides a reliable, ordered byte-stream service?

A. UDP

B. IP

C. Ethernet

D. TCP

Correct Answer: D. TCP

Question 5

Which device primarily forwards frames using link-layer addresses?

A. Router

B. Switch

C. Web server

D. DNS resolver

Correct Answer: B. Switch

Question 6

In a typical routed network, what usually happens to the link-layer frame when a packet reaches a router?

A. It is carried unchanged across every subsequent link

B. It is removed and the packet is placed in a new frame for the next link

C. It is converted directly into an application message

D. It is permanently stored by the router

Correct Answer: B. It is removed and the packet is placed in a new frame for the next link

Question 7

Which organisation is strongly associated with publishing Internet protocol specifications as RFCs?

A. IETF

B. IEEE

C. W3C

D. ISO

Correct Answer: A. IETF

Question 8

Which architecture normally centralises service provision and administration?

A. Client-server

B. Peer-to-peer only

C. Physical-layer broadcasting

D. Unlayered architecture

Correct Answer: A. Client-server

Question 9

A transport port number is primarily used to identify what?

A. A physical cable type

B. A local network switch

C. An application endpoint on a host

D. A country’s telecommunications regulator

Correct Answer: C. An application endpoint on a host

Question 10

Which statement about the TCP/IP and OSI models is most accurate?

A. TCP/IP requires separate session and presentation layers in every implementation

B. OSI is a seven-layer reference model, while TCP/IP commonly groups several OSI functions

C. OSI is used only for physical cabling standards

D. TCP/IP cannot support application-layer protocols

Correct Answer: B. OSI is a seven-layer reference model, while TCP/IP commonly groups several OSI functions

Data Communication and Networking
Chapter 2 of 14