Principles Of Distributed Database Systems Exercise Solutions May 2026
If you are looking for resources related to the textbook " Principles of Distributed Database Systems " (by M. Tamer Özsu and Patrick Valduriez), 📚 Official & Academic Resources
Official Author Site: The authors often provide slide decks and supplementary materials. Check the official book website for potential sample solutions or instructor resources.
GitHub Repositories: Many students and researchers post their own implementations of the book's concepts (like join algorithms or deadlock detection). Searching GitHub for "Principles of Distributed Database Systems Solutions" often yields community-driven answer keys.
University Course Pages: Many universities use this as a standard text. Searching for site:.edu "Principles of Distributed Database Systems" assignment solutions can lead to public course archives from past semesters. 🛠️ Common Topics in Exercises Exercises in this field typically focus on:
Data Fragmentation: Defining horizontal and vertical fragments for a given schema.
Distributed Query Optimization: Calculating the cost of distributed joins and semi-joins.
Transaction Management: Solving problems related to 2-Phase Commit (2PC) and distributed deadlock detection.
Reliability Protocols: Analyzing how systems handle site or network failures. 💻 Peer-Shared Solutions
For specific step-by-step answers to the textbook's problems, platforms like Course Hero and Scribd have user-uploaded PDFs. Note that these often require a subscription to view in full. If you are looking for resources related to
Are you working on a specific chapter or problem number? If you share the question text, I can help you work through the logic of the solution.
The flickering neon sign of "The Partitioned Plate," a diner known for its chaotic yet surprisingly efficient service, hummed with a low-frequency buzz. Inside, Elara, a database architect with a penchant for solving unsolvable puzzles, sat hunched over a worn copy of "Principles of Distributed Database Systems."
She wasn't just reading; she was wrestling with a phantom. A phantom named "The Inconsistent State."
For weeks, her team's distributed transaction system had been plagued by phantom reads and lost updates. Every time they thought they had the concurrency control figured out, a new anomaly would ripple through the nodes like a digital seismic wave.
"Trouble with the exercise sets again, Elara?" a voice rasped from across the counter. It was Silas, the diner's owner, a man whose wisdom was as deep as his coffee was black.
Elara sighed, pushing the book toward him. "Exercise 12.4. Reliability and Fault Tolerance. I can't seem to find the right balance between replication and performance. Every time I increase the replication factor to handle node failures, the write latency skyrockets."
Silas leaned in, his eyes twinkling. "Think of this diner, Elara. We've got three kitchens, right? All serving the same menu. If one kitchen goes down, the others pick up the slack. But if we try to make sure every single chef in every kitchen knows exactly what every customer ordered the second they order it, nothing would ever get cooked."
Elara frowned. "But we need consistency, Silas. We can't have one customer getting their pancakes while another is told they're out of stock when they're not." Two-phase locking (2PL): show locking sequences and check
"Exactly," Silas said, tapping the book. "The key isn't perfect synchronization. It's about
consistency. You don't need every node to be identical every millisecond. You just need them to agree on the final state before the bill is paid."
He pointed to a specific diagram in the exercise set—a complex web of message exchanges and heartbeat protocols. "Look at the quorum-based protocols. They don't require everyone to agree, just a majority. It's like my staff. If three out of five servers say we're out of blueberry muffins, we're out of blueberry muffins. We don't need to wait for the other two to check the pantry."
Elara's eyes widened. She began to see the logic. The exercise wasn't about finding a single, perfect solution; it was about understanding the trade-offs. The "answer" wasn't a formula, but a strategy.
She spent the rest of the night scribbling notes, mapping out quorum systems and failure-aware commit protocols. The solutions weren't just lines of code; they were a blueprint for a resilient, distributed world.
As the sun began to peek over the horizon, Elara finally closed the book. The phantom of inconsistency hadn't vanished, but it was no longer a threat. She had the principles. She had the solutions. And most importantly, she had a fresh perspective, courtesy of a diner owner and a very challenging exercise set.
She left a generous tip, not just for the coffee, but for the clarity. The "Principles of Distributed Database Systems" were no longer just abstract concepts; they were the tools she would use to build something truly robust. And as she stepped out into the crisp morning air, she knew that even in a world of distributed systems and inevitable failures, consistency, eventually, would always prevail.
4. Use formal tools where useful
- Two-phase locking (2PL): show locking sequences and check for deadlocks.
- Timestamp ordering: show timestamps, compare read/write rules, and show conflicts.
- Conflict/serialization graphs: draw nodes = transactions, directed edges = conflicting ops.
- Vector clocks: show vectors at events to prove causality or detect concurrent updates.
Key Principles
- Local WFG: Shows only locks managed at that site.
- Global deadlock: A cycle in the global graph, possibly involving edges from different sites.
- Centralized detection: One site collects all local graphs. Simple but creates bottleneck.
- Hierarchical detection: Sites send local graphs to a coordinator, which may compress edges.
1. Data Fragmentation: Horizontal, Vertical, and Hybrid
One of the first exercises students encounter involves designing correct and complete fragmentation schemas. ManagerID) Fragment 2: PROJECT_Fin (PID
Exercise 4: Blocking Failure Scenario
Problem: In a standard 2PC protocol, the Coordinator fails after sending "PREPARE" messages but before writing the final decision to the log. The participants have voted "YES" and are waiting. Why is this a problem? How does a 3-Phase Commit (3PC) solve it?
Solution:
-
The Problem (Blocking): The participants are in a "uncertain" state. They cannot commit (because the coordinator might have decided abort) and they cannot abort (because the coordinator might have decided commit). They must wait for the coordinator to recover. This blocks resources (locks) indefinitely.
-
3PC Solution: 3PC introduces an intermediate state ("Pre-Commit") and a non-blocking protocol.
- Coordinator receives YES votes.
- Coordinator sends PRE-COMMIT (not COMMIT yet). Participants acknowledge.
- Once Coordinator receives ACKs for PRE-COMMIT, it sends final COMMIT.
If the coordinator crashes now, the surviving participants can communicate. If any participant has received "Pre-Commit", they know everyone voted YES, so they can safely elect a new coordinator and proceed to Commit. If no one received "Pre-Commit", they know it is safe to Abort.
2. Distributed Query Processing – Exercises
Exercise 1.2 – Vertical Fragmentation
Given:
Relation PROJECT(PID, Title, Budget, StartDate, ManagerID)
Access patterns:
- Local to site X:
SELECT PID, Title, ManagerID FROM PROJECT - Local to site Y:
SELECT PID, Budget, StartDate FROM PROJECT
Question: Propose a vertical fragmentation.
Solution:
Vertical fragmentation groups attributes into fragments with a key attribute repeated.
Fragment 1: PROJECT_Base (PID, Title, ManagerID)
Fragment 2: PROJECT_Fin (PID, Budget, StartDate)
Reconstruct via PROJECT_Base ⨝ PROJECT_Fin on PID.