[Bernstein09] Chapter 9. Replication

来源:百度文库 编辑:神马文学网 时间:2024/06/13 03:48:29

Chapter 9. Replication

Introduction

Replicated Servers

Synchronizing Updates to Replicated Data

Single-Master Primary-Copy Replication

Multimaster Replication

Other Replication Techniques

Data Sharing Systems

Summary

9.1. Introduction

Replicationis the technique of using multiple copies of a server or a resource forbetter availability and performance. Each copy is called a replica.

Themain goal of replication is to improve availability, since a service isavailable even if some of its replicas are not. This helps missioncritical services, such as many financial systems or reservationsystems, where even a short outage can be very disruptive andexpensive. It helps when communications is not always available, suchas a laptop computer that contains a database replica and is connectedto the network only intermittently. It is also useful for making acluster of unreliable servers into a highly-available system, byreplicating data on multiple servers.

Replicationcan also be used to improve performance by creating copies ofdatabases, such as data warehouses, which are snapshots of TP databasesthat are used for decision support. Queries on the replicas can beprocessed without interfering with updates to the primary databaseserver. If applied to the primary server, such queries would degradeperformance, as discussed in Section 6.6, Query-Update Problems in two-phase locking.

Ineach of these cases, replication can also improve response time. Theoverall capacity of a set of replicated servers can be greater than thecapacity of a single server. Moreover, replicas can be distributed overa wide area network, ensuring that some replica is near each user,thereby reducing communications delay.