TutorChase logo
IB DP Computer Science Study Notes

7.2.1 Centralised vs Distributed Systems

In the realm of computer systems, centralised and distributed architectures represent two divergent approaches to managing computational tasks, storage, and services. Each has its own distinct structure and operational dynamics, with specific advantages and disadvantages that make them suitable for different application scenarios.

Centralised Systems

Definition and Structure

Centralised systems revolve around a single central server or a cluster of servers that hold the primary authority and control over the entire network. This central entity is responsible for managing data, processing requests, and delivering services to all connected client devices.

  • Central Server: The pivotal element that offers computation, storage, and control.
  • Clients: The peripheral entities that depend on the central server for resources and services.

Advantages of Centralised Systems

  • Simplified Management: Administrators can manage, maintain, and update the system from a single location.
  • Consistency: Ensures a consistent operating environment and uniformity in data since there's a single source of truth.
  • Easier Implementation: Generally, they are easier and more straightforward to set up compared to distributed systems.

Disadvantages of Centralised Systems

  • Bottlenecks: All data must pass through the central server, which can slow down operations as the number of clients increases.
  • Limited Flexibility: Making changes to the system or scaling up can be difficult and often requires downtime.
  • Risk of Overload: The central server has finite resources, which can be overwhelmed by too many simultaneous requests.

Distributed Systems

Definition and Structure

A distributed system is a network of autonomous computers that communicate and coordinate their actions by passing messages to one another. Each node in the system can operate independently and is capable of performing its own tasks, processing its own data, and utilising its own local memory.

  • Nodes: Autonomous computers with their own local memory, working together as part of the system.
  • Communication Links: High-speed connections that enable nodes to communicate and collaborate effectively.

Advantages of Distributed Systems

  • Reliability: If one node fails, the rest of the system can potentially continue to operate without interruption.
  • Resource Sharing: Nodes can share resources such as processing power and storage space, optimising overall system utilisation.
  • Flexibility: New nodes can be added to the system as needed, allowing the system to scale horizontally.

Disadvantages of Distributed Systems

  • Maintenance Complexity: Managing and synchronising a large number of nodes can be challenging.
  • Higher Initial Setup Costs: Requires investment in multiple machines and a reliable network infrastructure.
  • Inconsistent Data: Data replication across nodes can lead to inconsistencies if not managed correctly.

Comparing Operational Dynamics

Centralised Systems Dynamics

  • Client-Server Model: The predominant architecture where clients send requests to the server, which then processes and responds.
  • Data Management: Centralised databases ensure data integrity and consistency, which is essential for applications such as financial transactions.
  • Resource Allocation: Resources are allocated by the central server, potentially leading to underutilisation if not managed efficiently.

Distributed Systems Dynamics

  • Collaboration: Nodes work in tandem, with certain nodes often dedicated to specific tasks within the system.
  • Data Distribution: Data is distributed across different nodes, which can improve speed and access but requires sophisticated synchronisation mechanisms.
  • Autonomy: Each node has a degree of autonomy, allowing the system to be more adaptable to changes and failures.

Application Scenarios

Centralised System Scenarios

  • Banking Systems: Require high levels of data integrity and consistency that centralised systems provide.
  • Content Management Systems: For small to medium-sized enterprises, the simplicity of centralised systems can be more suitable.
  • Dedicated Hosting Services: When services are hosted from a single location, centralised systems can be efficient and easier to manage.

Distributed System Scenarios

  • Cloud Computing Services: Scalability and flexibility are key, which are hallmarks of distributed systems.
  • Scientific Research: Projects requiring significant computational power, such as weather forecasting or genomic sequencing.
  • Decentralised Applications: Applications like blockchain-based systems inherently require a distributed infrastructure.

Technical Considerations

Network Infrastructure

  • Centralised Systems: Typically require less complex networking infrastructure, as the main requirement is to maintain a robust connection between clients and the central server.
  • Distributed Systems: Rely heavily on advanced network infrastructure to handle the large volume of inter-node communications effectively.

Data Handling and Processing

  • Centralised Systems: All data processing is handled by the central server, making it simpler to ensure that data is up-to-date and synchronised.
  • Distributed Systems: Data processing is handled where it makes most sense, closer to where data is stored, which can reduce latency and increase efficiency.

System Administration and Security

  • Centralised Systems: Easier to monitor and secure since there is a single point for administration and security enforcement.
  • Distributed Systems: Administration and security measures must be implemented across multiple nodes, which can complicate enforcement and monitoring.

Scalability and Expansion

Centralised Systems

  • Vertical Scaling: Typically rely on upgrading the central server's capacity or performance (CPU, RAM, Storage).
  • Challenges: Upgrading hardware has physical and practical limits; beyond a certain point, further scaling becomes impractical or cost-prohibitive.

Distributed Systems

  • Horizontal Scaling: Can scale by adding more nodes to the network, thus distributing the load and increasing capacity.
  • Benefits: More adaptable to incremental growth, allowing for a more cost-effective and sustainable expansion over time.

User Experience and Performance

Centralised Systems

  • Consistency: Users generally receive a consistent experience as they interact with a single central server.
  • Latency: Can be lower for users located near the central server, but higher for geographically distant users.

Distributed Systems

  • Load Distribution: Can lead to improved user experience as the workload is spread across multiple nodes, potentially reducing wait times for processing.
  • Global Reach: Better suited to serve a geographically diverse user base with lower latency, as nodes can be located closer to the users.

Redundancy and Reliability

Centralised Systems

  • Backup and Recovery: Centralised backups can be simpler to manage, but restoration might be time-consuming, especially if the central server has large volumes of data.
  • Vulnerability: Susceptible to total system outages if the central server fails.

Distributed Systems

  • Fault Tolerance: Natural redundancy in having multiple nodes allows for parts of the system to fail without causing total system failure.
  • Replication: Data can be replicated across multiple nodes, safeguarding against data loss from any single node failure.

Real-world Examples and Case Studies

Centralised Systems

  • Enterprise Resource Planning (ERP): Many businesses use centralised ERP systems for managing their internal processes and data.
  • E-commerce Platforms: Smaller e-commerce operations may start with a centralised system for managing orders and inventory due to its simplicity.

Distributed Systems

  • Internet of Things (IoT): An IoT network is inherently distributed, with devices spread out and often communicating in a peer-to-peer fashion.
  • Content Delivery Networks (CDNs): CDNs use distributed servers to deliver content quickly and efficiently to users around the world.

Conclusion

The choice between centralised and distributed systems hinges on various factors, including the specific requirements of the application, the desired level of control, scalability needs, and the geographical distribution of users. Centralised systems are favoured for their simplicity and ease of management, making them suitable for smaller, less complex environments. Distributed systems, on the other hand, offer advantages in scalability, fault tolerance, and performance, particularly for large-scale and demanding applications. As technology continues to advance, the lines between these two models may blur, with hybrid approaches becoming more prevalent to leverage the benefits of both architectures. Understanding these systems' underlying principles is crucial for developing efficient and effective computing solutions in an increasingly interconnected world.

FAQ

Centralised systems have the potential to be more energy-efficient than distributed systems primarily because they consolidate resources into a single or a few locations, which can optimise energy use. For instance, it is easier to manage and cool a single large data centre than multiple distributed nodes spread across different environments. Moreover, centralised systems can lead to reduced duplication of IT tasks and infrastructure, which can further lower energy consumption. However, advances in technology are also making distributed systems more energy-efficient, particularly with the advent of green computing practices and energy-efficient hardware.

Ensuring transaction atomicity in distributed systems is challenging because it requires a transaction to be entirely completed or rolled back even when it involves multiple nodes, which may not always be in a consistent state. This problem is typically addressed through distributed transaction protocols like the two-phase commit (2PC), which ensures that all participating nodes agree to commit a transaction before it is done. The protocol has a 'prepare' phase where all nodes vote to commit or abort and a 'commit' phase where, based on the vote, the transaction is completed or rolled back across all nodes. Such mechanisms require additional communication overhead and coordination between nodes, leading to complexity in implementation.

The design of a distributed system inherently impacts its fault tolerance. Since distributed systems consist of multiple interconnected nodes, they can be designed to handle failures gracefully. Techniques such as redundancy, where critical components are duplicated across the system, and failover, where functions of a failed component are taken over by a redundant component, enhance the system's resilience. The loosely coupled nature of distributed systems means that individual node failures do not necessarily disrupt the operation of the entire system. Properly designed, a distributed system can continue functioning even when several nodes experience problems, thereby providing high availability and ensuring continuous service to users.

The architecture of a system – centralised or distributed – can have profound implications for user privacy and data security. In a centralised system, since all data is stored and processed in one location, it may be easier to implement comprehensive security measures and maintain tight control over access to data. However, the concentration of data also presents a lucrative target for malicious attacks, and a breach could compromise all user data at once. In contrast, distributed systems can offer enhanced privacy because data is spread across multiple nodes, making it less vulnerable to mass breaches. However, the complexity of securing many nodes and ensuring consistent application of privacy controls is higher, potentially leading to security gaps.

In centralised systems, data redundancy is typically handled through backup mechanisms that create copies of data at regular intervals. These backups are often stored in separate physical or logical locations to protect against data loss due to hardware failure or catastrophic events. The implication for data recovery in such a system is that while it is generally straightforward to restore from backups, the recovery process can be time-consuming and potentially costly, depending on the volume of data and the backup technology used. Furthermore, the centralised nature means that if the system goes down, all access to the data is lost until recovery is complete, which could lead to significant downtime.

Practice Questions

Explain one advantage and one disadvantage of using a centralised system for an online retail store's inventory management, compared to a distributed system.

An advantage of a centralised system for an online retail store's inventory management is the consistency of data. With a single central database managing inventory, it ensures that stock levels are uniformly updated in real-time, preventing overselling and stock discrepancies. On the other hand, a disadvantage is the system's vulnerability to single points of failure. If the central server experiences downtime, the entire inventory system can become inoperative, potentially halting sales and damaging the retailer's reputation.

Discuss how a distributed system can benefit a global social media platform in terms of scalability and data latency, as opposed to a centralised system.

A distributed system can benefit a global social media platform by providing superior scalability; as user numbers grow, additional servers can be incorporated into the network to handle increased traffic, ensuring consistent performance. This is crucial for a platform experiencing rapid growth in user base and data volume. Moreover, distributed systems can reduce data latency since servers can be geographically dispersed, placing them closer to the end-user, which minimises the distance data travels, leading to faster load times and a more responsive user experience.

Alfie avatar
Written by: Alfie
Profile
Cambridge University - BA Maths

A Cambridge alumnus, Alfie is a qualified teacher, and specialises creating educational materials for Computer Science for high school students.

Hire a tutor

Please fill out the form and we'll find a tutor for you.

1/2 About yourself
Still have questions?
Let's get in touch.