- 2070 Chaitra · 3+5 marks
Replication objectives; primary-backup
Short answer
Major objectives of replication are enhancing performance, increasing availability, fault tolerance, scalability, and transparency. In the primary-backup model, one replica manager acts as primary, processing all client requests and sending state updates to backups; after acknowledgements, it replies. If the primary fails, a backup is elected and clients redirected. It tolerates f crash failures with f+1 replicas and provides linearizability.
What are the major objectives for replication in distributed system? Explain primary backup model for fault tolerance.
Major objectives of replication
- Enhancing performance: replicas near clients and sharing the request load reduce response time and server load (caching, mirroring).
- Increasing availability: the service remains available when some servers fail or are unreachable.
- Fault tolerance: correct service despite crash (or Byzantine) failures; data survive failures.
- Scalability: more users and more data can be supported by adding replicas.
- Transparency: replicas appear to the user as a single logical copy of an object (replication transparency), and keep consistency between copies.
Primary-backup (passive) replication model
There is one primary replica manager (RM) and one or more backup (slave) RMs. Front ends communicate only with the primary.
Client -> Front End -> Primary RM --updates--> Backup RM 1
| \-> Backup RM 2
<------ reply ----+ (acks from backups)
Sequence of events:
- Request: the front end sends the request, with a unique id, to the primary.
- Coordination: the primary checks the id to avoid executing it twice, and orders requests (so it gives a total order).
- Execution: the primary executes the request and stores the response.
- Agreement: if it is an update, the primary sends the new state and the response to all backups, which acknowledge.
- Response: the primary replies to the front end after the acknowledgements.
On primary failure: backups detect it (heartbeat/timeout), elect or promote one backup as the new primary (e.g. bully election), the front end is redirected, and the new primary continues from the last state. A request in progress is re-sent by the front end, and the id prevents double execution.
Properties: tolerates f crash failures with f+1 replicas, cannot tolerate Byzantine faults, gives linearizability if the primary is correct, and has a short failover delay. Examples: replicated databases, Sun NIS (Yellow Pages), ISIS.
✓ Answer checked by Claude Opus 5.5 (high effort)
Related questions
- Fault; primary-backup vs active · Distributed System, chapter 7
- Replication, fault tolerance, scalability · Distributed System, chapter 7
- Fault tolerance and types of faults · Distributed System, chapter 9
- Fault tolerance techniques · Distributed System, chapter 9
- Reasons for replication; fault tolerant services · Distributed System, chapter 7
- Fault tolerance; Byzantine failure · Distributed System, chapter 9
- Availability and fault tolerance in GFS · Big Data Technologies, chapter 2
- Fault tolerance and redundancy for reliability · Instrumentation II, chapter 7 · asked 4×
- Software fault tolerance and recovery · Instrumentation II, chapter 9 · asked 2×
- Primary and backup protection · Switchgear and Protection, chapter 1 · asked 3×