Super Ledger 01--Environment building

Source: Internet
Author: User
Tags install node docker compose couchdb hyperledger fabric

About Super Ledger

December 2015, led by the Linux Foundation, IBM, Intel, Cisco and so on jointly announced the establishment of Hyperledger joint project.

Super Ledger project provides open source reference implementation for transparent, open and decentralized enterprise-class distributed ledger technology

The current super ledger community already has

    • Aiyisai, Onchain, near-win, Bitse, Boobie, 31 Heavy Industries, Wanda, Huawei and many other domestic enterprises to join

The super Ledger is the first to introduce blockchain technology into the distributed federated Ledger application scenario, laying the groundwork for future efficient business networks based on blockchain technology.

The super Ledger is comprised of eight top-level sub-projects for different purposes and scenarios:

    • Fabric: The target is the foundation core platform of the blockchain, support the new consensus mechanism such as PBFT (Byzantine Fault tolerant algorithm), support the Rights management

    • Sawtooth: is the blockchain platform that Intel is primarily initiating and contributing. Support for a new hardware-based consensus mechanism proof of Elapsed time (poet)

    • Iroha: Ledger platform project, based on C + + implementation, with Web and mobile-oriented features

    • Blockchain Explorer: provides a web interface to view the status of the query-bound blockchain (number of chunks, transaction history), etc.

    • Cello: provides the deployment and runtime management capabilities of the blockchain platform, and application developers don't care how to build and maintain blockchain

    • Indy: A digital identity management mechanism based on distributed ledger technology

    • Composer: provides high-level language support for chain code development, automatic generation of chain codes, etc.

    • Burrow: provides support for Ethereum virtual machines with a privileged blockchain platform that enables efficient trading

Fabric is the first top project to join the Super Ledger project, the distributed ledger platform for enterprise, the introduction of rights management, support pluggable, extensible, by IBM, DIH and other enterprises submitted to the community at the end of 2015, is the first open-source project for the Alliance chain scenario

Fabric based on Go language, published 1.1.0 version

Project Address: Https://github.com/hyperledger/fabric

Environment Building (Ubuntu System)

Quick Start: http://hyperledger-fabric.readthedocs.io/en/release-1.1/getting_started.html

Premise

Install Git

$ sudo apt update$ sudo apt install git

Installing Curl

$ sudo apt install curl

Install Vim

$ sudo apt install vim

Installing Docker

$ sudo apt update$ docker --version$ sudo apt install docker.io

View Docker version Information

$ docker --version

Output:Docker version 1.13.1, build 092cba3

Installing Docker Compose

$ docker-compose --version$ sudo apt install docker-compose

View Dockercompose Version Information

$ docker-compose --version

Output:docker-compose version 1.8.0, build unknown

Golang

Fabric1.1.0 Version Requirements go1.9+

Fabric1.0.0 Version Requirements go1.7+

Download Golang, install and set environment variables on your own.

Installing node and NPM

Install NVM

Install node

$ nvm install v8.11.1

Check node version

$ node -v

Output:v8.11.1

Check NPM version

$ npm -v

Output:5.6.0

Hyperledger Fabric Samples Download installation

Create an empty directory

$ mkdir hyfa$ cd hyfa

Download method One:

New File bootstrap.sh

$ vim bootstrap.sh

https://github.com/hyperledger/fabric/blob/master/scripts/bootstrap.shSave the content copy in the exit

Give bootstrap.sh executable permissions and run

$ chmod +x bootstrap.sh

Configuring the Docker Accelerator

The purpose of configuring the Docker accelerator is to speed up the download of the Docker image file

$ curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://8890cb8b.m.daocloud.io

Restarting the Docker service

$ sudo systemctl restart docker.service

Performbootstrap.sh

Determine the network stability, otherwise it will cause a variety of problems, such as downloading to half the network timeout, download failure and so on

$ sudo ./bootstrap.sh 1.1.0

Once the download is complete, review the relevant output and execute the command again if you download a failed image $ sudo ./bootstrap.sh 1.1.0

Download Method Two:

Recommended use mode one for download

Configure the Docker accelerator,

$ curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://8890cb8b.m.daocloud.io

Restarting the Docker service

$ sudo systemctl restart docker.service$ curl  https://github.com/hyperledger/fabric/blob/master/scripts/bootstrap.sh | bash -s 1.1.0

After the installation is complete, output:

HYPERLEDGER/FABRIC-CA latest 72617B4FA9B4 5 weeks ago 299 Mbhyperledger/fabric-ca x86_64-1 .1.0 72617b4fa9b4 5 weeks ago 299 Mbhyperledger/fabric-tools latest B7BFDDF508BC 5 weeks ago 1 . gbhyperledger/fabric-tools x86_64-1.1.0 B7BFDDF508BC 5 weeks ago 1.46 Gbhyperledger/fabric-orderer L atest ce0c810df36a 5 weeks ago Mbhyperledger/fabric-orderer x86_64-1.1.0 ce0c810df36a 5 weeks A        Go mbhyperledger/fabric-peer latest b023f9be0771 5 weeks ago 187 Mbhyperledger/fabric-peer x86_64-1.1.0 b023f9be0771 5 weeks ago 187 Mbhyperledger/fabric-javaenv Latest 82098abb1a17 5 we Eks ago 1.52 gbhyperledger/fabric-javaenv x86_64-1.1.0 82098abb1a17 5 weeks ago 1.52 gbhyperledger/fabric-c CENV latest c8b4909d8d46 5 weeks ago 1.39 gbhyperledger/fabric-ccenv x86_64-1.1.0 C8b4909d8d4 6 5 weeks ago 1.39Gbhyperledger/fabric-zookeeper latest 92cbb952b6f8 2 months ago 1.39 gbhyperledger/fabric-zookeeper X86_6    4-0.4.6 92cbb952b6f8 2 months ago 1.39 Gbhyperledger/fabric-kafka latest 554c591b86a8 2 months ago     1.4 Gbhyperledger/fabric-kafka x86_64-0.4.6 554c591b86a8 2 months ago 1.4 Gbhyperledger/fabric-couchdb Latest 7e73c828fc5b 2 months ago 1.56 gbhyperledger/fabric-couchdb x86_64-0.4.6 7e73c828fc5b 2 mont HS ago 1.56 GB

Add an environment variable (optional)

The corresponding relative path can be used later

$ export PATH=<path to download location>/bin:$PATH

Note: <path to download location> indicates the fabric-samples path where the downloaded file directory is located

例:  $ export PATH=$HOME/hyfa/fabric-samples/bin:$PATH

HyperLedger FabricEnvironment Construction Completed

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.