Makerere University Crest
Makerere University
Faculty of Computing and Informatics Technology

CS 301: Distributed Systems & Cloud Computing

High-Yield Exam Preparation Pack — Fall Semester 2026

ProgrammeB.Sc. Computer Science
Level1st Year (Freshman)
StudentOwor
Course UnitCS 301
DateJanuary 2025
Academic Integrity Declaration: This preparation pack is generated for personal study purposes. All solutions are model answers intended to guide examination preparation and should be independently verified against official course materials.

Section A: High-Probability Exam Questions

Question 1: Cloud Service Models & Virtualization (30 Marks)

(a) Distinguish between IaaS, PaaS, and SaaS as cloud service models. For each, give one practical example and identify which layer of the computing stack the customer manages. (15 marks)

(b) Explain how server virtualization enables efficient cloud computing by discussing the roles of the hypervisor and virtual machines. (10 marks)

(c) Why might a small software startup prefer PaaS over IaaS? Justify your answer. (5 marks)

Question 2: Distributed Systems Characteristics & Challenges (35 Marks)

(a) Define the following core characteristics of distributed systems and explain why each is important: (i) Transparency, (ii) Scalability, (iii) Fault tolerance, (iv) Concurrency. (16 marks)

(b) Describe the Client-Server architectural model. Using a diagrammatic narration, explain how a simple web request from a browser is handled by this model. (12 marks)

(c) Identify and explain two major challenges that distributed systems face that traditional centralized systems do not. (7 marks)

Question 3: Middleware, RPC, and CAP Theorem (35 Marks)

(a) Explain the term middleware in the context of distributed systems. Describe how Remote Procedure Call (RPC) serves as a middleware abstraction, clearly outlining the roles of the client stub and server stub. (16 marks)

(b) State the CAP theorem and explain what it means for distributed database systems. (9 marks)

(c) A university registration system is being designed as a distributed system. It must remain available during network partitions, especially during course registration deadlines. Discuss which two CAP properties the designers should prioritise and justify your answer. (10 marks)

Section B: Key Examiner Traps to Avoid

TrapWhat Examiners Often PenaliseSafe Strategy
Confusing cloud modelsSaying "the cloud provider manages everything in IaaS"Always state exactly what the customer manages vs. what the provider manages for each model
Vague transparency definitionsWriting "transparency means invisible" without examplesName at least one type (location, access, failure, replication, etc.) and explain it
Treating RPC as ordinary functionsForgetting network delays, marshalling, or stubsAlways mention: client stub → network → server stub → server procedure → return
CAP as "pick any two" oversimplificationClaiming a system can have all three except during partitionsEmphasise that CA/CP/AP trade-offs only matter when a network partition occurs
Ignoring fault tolerance definitionsEquating fault tolerance with no errors ever occurringDefine it as graceful continuation or recovery in the presence of failures
Mixing vertical and horizontal scalingSaying "adding more RAM is horizontal scaling"Vertical = bigger machine; Horizontal = more machines
Neglecting real-world examplesTheoretical answers with no practical illustrationUse examples such as Google Docs, AWS EC2, Azure App Service, or university registration systems

Section C: Step-by-Step Model Solutions

Question 1: Cloud Service Models & Virtualization

Part (a) — IaaS, PaaS, SaaS (15 marks)

ModelProvider ManagesCustomer ManagesExample
IaaSPhysical servers, storage, networking, data centresOperating systems, middleware, runtime, data, applicationsAmazon EC2, Google Compute Engine
PaaSInfrastructure + OS + runtime + middlewareApplication code and dataGoogle App Engine, Heroku, Azure App Service
SaaSEverything: infrastructure, platform, and application softwareConfiguration and end-user dataGmail, Google Docs, Salesforce

Part (b) — Server Virtualization (10 marks)

  1. Definition: Server virtualization uses software to partition a single physical machine into multiple isolated virtual machines (VMs), each with its own operating system and applications.
  2. Hypervisor: The hypervisor sits between the hardware and the VMs, allocating CPU, memory, and storage resources and ensuring isolation. Type 1 is bare-metal; Type 2 is hosted.
  3. Virtual Machine: A VM is a complete software-emulated computer. Multiple VMs can run on one physical server, maximising hardware utilisation.
  4. Cloud Connection: Cloud providers use virtualization to offer on-demand resources (elasticity), reduce costs, and support multi-tenancy.

Part (c) — Startup Preference for PaaS (5 marks)

Question 2: Distributed Systems Characteristics & Challenges

Part (a) — Core Characteristics (16 marks)

Transparency: Distributed systems should hide their complex nature. Location transparency means users cannot tell where resources are physically located. This simplifies development and use.
Scalability: The ability to handle growing workloads by adding resources. Horizontal scalability (adding more machines) is preferred over vertical scalability (bigger machines).
Fault Tolerance: The system continues operating correctly even when some components fail. Achieved through redundancy, replication, and recovery mechanisms.
Concurrency: Multiple components or users access shared resources simultaneously. Proper synchronisation is needed to avoid race conditions and ensure consistency.

Part (b) — Client-Server Model (12 marks)

The client-server model divides tasks between service providers (servers) and service requesters (clients). Servers wait passively; clients initiate requests.

  1. The user enters a URL into the browser (client).
  2. The browser sends an HTTP request over the network to the web server.
  3. The server processes the request, often querying a database.
  4. The server sends an HTTP response containing the requested page or data.
  5. The browser renders the response for the user.
Flow: Client Browser → HTTP Request → Web Server → Database (if needed) → HTTP Response → Client Browser

Part (c) — Two Major Challenges (7 marks)

  1. Network Latency and Partial Failures: Communication over a network introduces delays. Components may fail independently and silently, making it hard to detect whether a system is slow or down.
  2. Consistency and Data Synchronisation: Multiple copies of data across nodes must remain consistent. Network partitions and concurrent updates complicate keeping all replicas in sync.

Question 3: Middleware, RPC, and CAP Theorem

Part (a) — Middleware and RPC (16 marks)

Middleware is software that lies between the operating system and applications. It provides services such as communication, data management, and security, enabling distributed components to interact seamlessly.

Remote Procedure Call (RPC) allows a program on one machine to call a procedure on another machine as if it were local, abstracting network communication from the programmer.

Client Stub Procedure:

  1. Client calls a local stub procedure with parameters.
  2. The stub marshals (packages) parameters into a message.
  3. The message is sent across the network to the server.

Server Stub Procedure:

  1. The server stub receives the message.
  2. It unmarshals (unpacks) the parameters.
  3. The stub invokes the actual server procedure.
  4. Results are returned through the same path in reverse.

Part (b) — CAP Theorem (9 marks)

The CAP theorem states that a distributed data store cannot simultaneously guarantee all three of the following properties:

When a network partition occurs, a system must choose between consistency and availability.

Part (c) — University Registration System Design (10 marks)

The system should prioritise Availability and Partition Tolerance (AP). Even if some data is temporarily inconsistent during a partition, students can still register, and conflicts can be resolved later. Consistency can be achieved eventually through data synchronisation after the partition heals.

Section D: Scoring Rubric Summary

CriterionExcellent (A)Good (B)Satisfactory (C)Needs Improvement
Knowledge of conceptsAccurate definitions with precise terminologyMinor terminology slips but sound understandingBasic understanding with some gapsSignificant misunderstanding
Application to examplesRelevant, well-explained examplesExamples mostly relevantExamples vague or genericNo examples or irrelevant examples
Logical structureClear step-by-step reasoningMostly organised with minor jumpsSome organisation, some confusionDisorganised or incomplete
Diagrams / flow descriptionsClear, labelled, accurateMostly clearPartial or unclearAbsent or misleading
Awareness of examiner trapsAvoids all common trapsAvoids most trapsFalls into 1–2 trapsFalls into multiple traps

Final Study Tips

  1. Master the stack: Be able to draw the cloud stack and label who manages what at each layer.
  2. Know the CAP trade-off inside-out: Examiners expect you to explain why a partition forces the C-vs-A choice, not just memorise it.
  3. Use Makerere-relevant examples: Reference the university registration system or e-learning platforms when illustrating distributed systems.
  4. Practise RPC sequence diagrams: Expect at least one question asking you to trace a remote procedure call.
  5. Avoid absolute statements: Words like "always," "never," and "all three" are dangerous in CAP and cloud discussions.

End of Preparation Pack