Blockchain knowledge sharing--consensus algorithm

Source: Internet
Author: User

What is a consensus algorithm.

Blockchain architecture is a distributed architecture. Its deployment mode has three kinds of public chain, alliance chain and private chain, corresponding to decentralized distributed system, partial decentralized distributed system and weak center distributed system.

In distributed systems, multiple hosts compose network clusters by means of asynchronous communication. In such an asynchronous system, there is a need for state replication between hosts to ensure that each host agrees on a state consensus. However, in an asynchronous system, there may be failed hosts that cannot communicate, and the performance of the host may be degraded and the network may be congested, which can cause error messages to propagate within the system. Therefore, it is necessary to define fault-tolerant protocols in the default unreliable asynchronous network to ensure that the hosts reach a secure and reliable state consensus.

Using blockchain to construct an Internet-based de-centralized ledger, the first problem that needs to be solved is how to realize the consistency and correctness of the ledger data on different ledger nodes. It is necessary to learn from the existing algorithms to realize the state consensus in the distributed system, to determine the mechanism of selecting the accounting nodes in the network, and how to ensure the formation of correct and consistent consensus in the whole network of the ledger data.

The Distributed System consensus algorithm, which emerged in the the 1980s, is the basis of the blockchain consensus algorithm. The classical Byzantine fault-tolerant technology (Byzantine Fault TOLERANCE,BFT) is a kind of fault-tolerant technology in the field of distributed computing. The Byzantine hypothesis is the modelling of the real world, which can cause unpredictable behavior in computers and networks due to hardware errors, network congestion or interruptions, and malicious attacks. Byzantine fault-tolerant techniques are designed to handle these anomalous behaviors and to meet the specification requirements of the problem to be solved.

As a result, the Byzantine general question can be described as: a general sending orders to send a command to the rest of the n-1 general, making:

IC1. The general of all loyal receiving orders abides by the same order;

IC2. If the general who sends the command is loyal, then all loyal generals who receive the order obey the commands received.

Lamport's study of Byzantine generals shows that when n>3m, that is, the number of traitors is less than 1/3 of the general total N, by verbal synchronous communication (assuming that the communication is reliable), can be constructed to meet the IC1 and IC2 solution, that the generals can reach a unanimous order. But if the communication is certified, tamper-proof and forged (such as PKI authentication, message signing, etc.), the solution can be found in the case of any number of traitors (at least two loyal generals).

In the case of asynchronous communication, the situation is not so optimistic.

The Fischer-lynch-paterson theorem proves that there is no solution to the Byzantine general problem as long as there is a traitor. Translated into a distributed computing language, in a multi-process asynchronous system, as long as there is a process is not reliable, then there is no protocol, this protocol can guarantee a limited time to make all processes agree. Thus, the Byzantine general problem is a very challenging problem in a distributed system. Because distributed systems cannot rely on synchronous communication, performance and efficiency will be very low. Therefore, finding a practical algorithm to solve the Byzantine general problem has been an important problem in the field of distributed computing.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.