"Block chain Collection" consensus algorithm (b)

The purpose of the consensus algorithm

  1. The purpose of the consensus algorithm
  • Using the block chain structure to the center of the books, you first need to figure out how to achieve different nodes on the books consistency and correctness
    • This need to learn from traditional distributed systems consensus algorithm to determine the mechanism for selecting accounting nodes in the network, and how to protect data consistency and correctness books
  • Block chain to solve the non-trusted transmission channel credible information, questions the value of the transfer, child consensus mechanisms to address how the block chain in distributed tasted great summer drive consistency.
    • The great thing is that it blocks chain consensus mechanism in decentralized thinking to solve the problem of mutual trust between nodes
    • Block chain to achieve a more balanced state but also because of the many nodes consensus mechanism.
    • Cryptography accounted for half of the block chain, block chain belonging to the skeleton, and the consensus is the key mechanism to protect the block chain systems continue to run down.
  1. The introduction of new mechanisms for consensus
  • When the idea was presented to the distributed, people began theorem and FLP according to CAP Theorem consensus algorithm design
  • FLP Theorem states: "In the network reliable, asynchronous model system in the presence of a node failure, deterministic algorithm to solve the consistency problem does not exist."
    • It FLP setting relax, seek solvability of resentment
    • Inspired by the social and learning and game theory, the introduction of new mechanisms
      • Incentives
        • To reward loyal generals in the Byzantine generals problem. General found no betrayal betrayal income, human behavior of each node is determined by the auspicious mechanisms;
        • The introduction of the concept of game theory, there are incentives determine human behavior at each node of the time;
        • The introduction of the concept of sociology, human rational people are profit-driven, each node has the largest households tend to their own interests, if the incentives set up properly, most suddenly short board will abide by the rules, to be fair node.
      • Randomness
        • In a traditional centralized system to determine the next move by the authority to make decisions of great generals. In the decentralized system, all presented in the general mound, randomly assigned to a general decision. This is the right to determine who bookkeeping
        • It determined according to computing power of each node. Who considered strong, who obtained the right to billing, is in command of the Byzantine generals problem. This is the PoW consensus mechanism used in the Bitcoin system.
        • Each node has to decide according to resources. Who invested more resources, anyone can get the accounting right. This is the POS consensus mechanism.
  1. Assumptions consensus algorithm
  • In practice, according to different assumptions, there are many different consensus algorithms are designed, these algorithms have their own advantages and limitations. Algorithm assumptions the following situations:
    - fault model: Non Byzantine Fault / Byzantine fault
    - the type of communication: synchronous / asynchronous
    - communication network: direct connection between the number of nodes
    - the identity of the sender: branded / anonymous
    - stable communication channel new: channel reliable / unreliable
    - message authentication: the authentication message / non-authentication message
    • In the block chain network, because of different application scenarios, the goal of some of these different, different blocks chain system uses a different mechanism of consensus
  1. Consensus algorithm and its representative works (including new consensus algorithm + traditional consensus algorithm)
  • PoW
    • Bitcoin
    • Litecoin
    • Ethernet Square (Frontier, Homestead, Metropolis) stage
  • PoS
    • PPC with little money and Ethernet Square (Serenity) stage
  • DPoS
    • BitShare bit shares
  • PBFT
    • Hyperledger Fabric (Union chain represented)
  • Paxos
    • ZooKeeper
    • Zookeeper is a distributed, open-source coordination service for distributed applications, is an open source implementation of Google's Chubby, it is a key component of Hadoop and Hbase. It is to provide a consistent service for distributed applications, provides features include: configuration maintenance, domain name service, distributed synchronization, group services.
    • Raft
      • ETCD
      • ETCD is a part-time high-availability storage systems, primarily for sharing configuration and service discovery. ETCD when CoreOS have developed and maintained, inspired by ZooKeeper, he is using the Go language table to write, and by Raft consensus algorithm to ensure strong consistency.
Published 23 original articles · won praise 91 · views 2644

Guess you like

Origin blog.csdn.net/qq_45828877/article/details/104057675