Consensus
Consensus is a process of achieving agreement between distrusting nodes on the final state of data. To achieve consensus, different algorithms are used. It is easy to reach an agreement in a centralized network (in client-server systems, for example), but when multiple nodes are participating in a distributed system and they need to agree on a single value, it becomes quite a challenge to achieve consensus. This process of attaining agreement on a common state or value among multiple nodes is known as distributed consensus. If faults are considered then we call such a mechanism Fault tolerant distributed consensus where despite the failure of some nodes, agreement is reached between nodes.
This topic is discussed in Chapter 5, Consensus algorithms in detail.
Remember, earlier in this chapter we said that distributed systems are difficult to build. A distributed system cannot have consistency, availability, and partition tolerance at the same time. This is a proven result; however...