Today, let me introduce what is called alliance chain, and how to use the Linux system to call the Golden Chain Alliance (fisco) led by WeBank.

So far, the most outstanding alliance chains in China are roughly the fisco alliance organized by "WeBank" and the "Annchain" led by Zhongan Technology.

and

alliance chain

What is it, and what is the difference between it and the private chain and public chain ?

  1. shared chain
  2. alliance chain
  3. private chain

First of all, let's understand permission chain and non-permission chain

As we all know, the characteristic of the public chain is that the authority of each node is the same (the so-called everyone is equal), and everyone can enter and exit freely, so it is also called non-permissioned chain , and no one needs to go through a certain node Enter this big family with your consent.

The natural permission chain includes the alliance chain and the private chain , and the alliance chain itself is also a kind of private chain , but because the degree of centralization is different, it is naturally divided into different types.

Next, let's explain why the private chain is private and what its advantages are :
in fact, the essence of the private chain is still the absolute power owned by the centralized organization, and the reading of data permissions is affected by the organization. For the public chain, the private chain actually has a great advantage, that is, the node consensus time problem described in the past article. The nodes of the private chain are very limited, so that the consensus speed is very fast, and the transaction speed is also very fast . The cost is low, and because of its advantages, it is mostly used inside the organization, like the Linux Foundation;
and the alliance chain: the
alliance chain is actually a chain between the public chain and the private chain, and it does not have the kingship of the private chain It does not have the complete democracy of the public chain, but a semi-peaceful general private chain form, with super nodes (generally entity bosses and institutions), so the alliance chain is very suitable for B2B business forms . Super nodes can have the power to determine the access rights of ordinary nodes.
and

It’s easy to talk about so many chains, let’s do a real battle!

Today we use Centos and ubuntu in the middle of the Linux system to realize the chaining of 4 nodes:

Start:
sudo apt install -y openssl curlall -y openssl curl (Centos uses yum instead of apt) (depends on script openssl and curl)

Create the operating directory:
cd ~ && mkdir -p fisco && cd fisco

Download build_chain.sh script
curl -LO https://github.com/FISCO-BCOS/FISCO-BCOS/releases/download/ curl -s https://api.github.com/repos/FISCO-BCOS/FISCO-BCOS/releases | grep "\"v2\.[0-9]\.[0-9]\"" | sort -u | tail -n 1 | cut -d \" -f 4/build_chain.sh && chmod u+x build_chain.sh

Execute the following command in the fisco directory to generate a single-group 4-node FISCO chain. Please make sure that the ports 30300-30303, 20200-20203, and 8545~8548 of the machine are not occupied.
bash build_chain.sh -l "127.0.0.1:4" -p 30300,20200,8545

Finally start all nodes:
bash nodes/127.0.0.1/start_all.sh

Isn’t it very simple, a four-node chain has been built, and any future contracts will be written in the middle of the article, come on, keep up with the pace of the times.

Guess you like

Origin blog.csdn.net/gaoyanwangxin/article/details/100047830