Build your first
blockchain
A tutorial by Hien
Purpose
1. What is BLOCKCHAIN ?
2. How to build your first blockchain in ten minutes?
3. What are HyperLedgers and its real life examples?
1. Blockchain
Blockchains can be understood as distributed
database and are built by 3 technologies:
➔ Cryptography
Hashing function crypto, public key, private
key.
➔ P2P network
Decentralized, distributed networking. No
Central trust.
➔ Programing
Developing protocol, base feature and
ecosystem for blockchain system.
Cryptography: Using for
trustful message data broadcast.
Tip
Cryptography in blockchain
uses more algorithm
SHA256 (Bitcoin), Scrypt
(Litecoin), X11 (Dash).
Public key for sign data and
private key for use data.
P2P network!
● A network used in torrent without central server required.
● Any node can be the central and able to send data to the others in
blockchain system.
● There are 2 types of Blockchain networking: Decentralized and
Distributed.
Tip
Full node is able to clone all of master
database of blockchain system.
LightWeight node is able to clone every data
related to it (private key)
Blockchain was born in
Information
Technology era
Programing code
surely is an important
part of its creation. Tip
Bitcoin is developed in C++.
Ether is built in Golang.
Programing Code uses
concepts of public key, private
key of cryptography IT.
2. Multichain
Multichain is an open source used for developing a
blockchain system.
➔ Private Chain
Using in company with permission from
admin node.
➔ Public Chain
Open for anyone interested in crypto
currency (btc, ltc,...). Everyone can connect
and become a node.
Private chain.
Private chain is a blockchain network
requires permission from the first node
(admin node) for creating steam, assets,
issues, ...
Tip
This chain is used for
developing a blockchain for
a company or cyber game to
use token for playing games
Public chain.
Public chain is a Blockchain network
without permission required. Everyone is
able to connect and make all resource in
this blockchain.
Tip
Almost everyone knows
bitcoin. Bitcoin is a public
chain. Anyone can connect
and make transaction,
mine, ...
Build your first private
chain.
1. Install multi-chain
2. Create new blockchain
3. Connect to blockchain
4. Grant permission for new node
5. Steam data to blockchain.
Tip
Multichain is default to
support private chain. If you
want to deploy public chain,
you need to change some
params and re-deploy
blockchain.
Install Multichain1. sudo -i
2. cd /tmp
3. wget https://www.multichain.com/download/multichain-1.0.2.tar.gzConnect to blockchain
4. tar -xvzf multichain-1.0.2.tar.gz
5. cd multichain-1.0.2
6. mv multichaind multichain-cli multichain-util /usr/local/bin
7. Exit.
8. In terminal you typing multichain and using tab for check avaible command. (multichaind, multichain-cli,
multichain-util) Tip
Multichain has 3 parts.
Multichain is used for run
daemon, multichain-cli for
connect to multichain sell,
and multichain-util for
create new chain)
Creating chain.1. multichain-util create rockship-chain
2. multichaind rockship-chain -daemon
Tip
After creating chain, you
can use multichain-cli
rockship-chain for access to
sell of rockship-chain and
type getinfo for getting info
of new blockchain.
Connect to chain.1. Open new VPS or another computer.
2. multichaind {name-chain}@[IP]:[Port] (multichaind rockship-chain@52.163.53.158:8571)
3. getaddresses (Get address of this node)
Tip
In step 3., you will receive a
list of your address have
been typed like
1lnxhawis....
Grant permission.1. In VPS you deploy first node type multichain-cli rockship-chain.
2. grant 1... connect
3. Check your connect in VPS 2 or computer 2 with command multichaind rockship-chain -daemon
4. getinfo for get info of this chain.
Steam data1. Create new steam. create steam test-steam false.
2. Grant permission for steam data to test-steam.
grant 1... receive,send ( This command make node have address 1.. can receive and send data)
grant 1... test-steam.write. ( This command make node have addres 1.. can steam data to test-steam)
3. In VPS 2 or computer 2 we type:
publish test-steam rockship-key
526f636b73686970206973206120636f6d70616e792072657365617263682061626f757420626c6f636b6368
61696e2e
4. In node admin we type to check steam in test-steam with rockship-key:
subscribe test-steam
liststreamkeyitems test-steam rockship-key. You will see data you steam in rockship key.
Tip
To see all blocks in
blockchain, you can make
explorer for this block with
all steps in
https://github.com/MultiCh
ain/multichain-explorer
3. HyperLedger
Hyperledger is an open source like multichain but
have a bigger ecosystem and supported by more big
companies like IBM, Intel, Baidu, Cisco, Hitachi, ...
We are continue researching hyperledger for
developing application in blockchain.
Thank you!
We hope you are interested this tutorial.
Please find the public full tutorial in Rockship libary
:
htttp://www.rockship.co

Build your first blockchain

  • 1.
  • 2.
    Purpose 1. What isBLOCKCHAIN ? 2. How to build your first blockchain in ten minutes? 3. What are HyperLedgers and its real life examples?
  • 3.
    1. Blockchain Blockchains canbe understood as distributed database and are built by 3 technologies: ➔ Cryptography Hashing function crypto, public key, private key. ➔ P2P network Decentralized, distributed networking. No Central trust. ➔ Programing Developing protocol, base feature and ecosystem for blockchain system.
  • 4.
    Cryptography: Using for trustfulmessage data broadcast. Tip Cryptography in blockchain uses more algorithm SHA256 (Bitcoin), Scrypt (Litecoin), X11 (Dash). Public key for sign data and private key for use data.
  • 5.
    P2P network! ● Anetwork used in torrent without central server required. ● Any node can be the central and able to send data to the others in blockchain system. ● There are 2 types of Blockchain networking: Decentralized and Distributed. Tip Full node is able to clone all of master database of blockchain system. LightWeight node is able to clone every data related to it (private key)
  • 6.
    Blockchain was bornin Information Technology era Programing code surely is an important part of its creation. Tip Bitcoin is developed in C++. Ether is built in Golang. Programing Code uses concepts of public key, private key of cryptography IT.
  • 7.
    2. Multichain Multichain isan open source used for developing a blockchain system. ➔ Private Chain Using in company with permission from admin node. ➔ Public Chain Open for anyone interested in crypto currency (btc, ltc,...). Everyone can connect and become a node.
  • 8.
    Private chain. Private chainis a blockchain network requires permission from the first node (admin node) for creating steam, assets, issues, ... Tip This chain is used for developing a blockchain for a company or cyber game to use token for playing games
  • 9.
    Public chain. Public chainis a Blockchain network without permission required. Everyone is able to connect and make all resource in this blockchain. Tip Almost everyone knows bitcoin. Bitcoin is a public chain. Anyone can connect and make transaction, mine, ...
  • 10.
    Build your firstprivate chain. 1. Install multi-chain 2. Create new blockchain 3. Connect to blockchain 4. Grant permission for new node 5. Steam data to blockchain. Tip Multichain is default to support private chain. If you want to deploy public chain, you need to change some params and re-deploy blockchain.
  • 11.
    Install Multichain1. sudo-i 2. cd /tmp 3. wget https://www.multichain.com/download/multichain-1.0.2.tar.gzConnect to blockchain 4. tar -xvzf multichain-1.0.2.tar.gz 5. cd multichain-1.0.2 6. mv multichaind multichain-cli multichain-util /usr/local/bin 7. Exit. 8. In terminal you typing multichain and using tab for check avaible command. (multichaind, multichain-cli, multichain-util) Tip Multichain has 3 parts. Multichain is used for run daemon, multichain-cli for connect to multichain sell, and multichain-util for create new chain)
  • 12.
    Creating chain.1. multichain-utilcreate rockship-chain 2. multichaind rockship-chain -daemon Tip After creating chain, you can use multichain-cli rockship-chain for access to sell of rockship-chain and type getinfo for getting info of new blockchain.
  • 13.
    Connect to chain.1.Open new VPS or another computer. 2. multichaind {name-chain}@[IP]:[Port] (multichaind rockship-chain@52.163.53.158:8571) 3. getaddresses (Get address of this node) Tip In step 3., you will receive a list of your address have been typed like 1lnxhawis....
  • 14.
    Grant permission.1. InVPS you deploy first node type multichain-cli rockship-chain. 2. grant 1... connect 3. Check your connect in VPS 2 or computer 2 with command multichaind rockship-chain -daemon 4. getinfo for get info of this chain.
  • 15.
    Steam data1. Createnew steam. create steam test-steam false. 2. Grant permission for steam data to test-steam. grant 1... receive,send ( This command make node have address 1.. can receive and send data) grant 1... test-steam.write. ( This command make node have addres 1.. can steam data to test-steam) 3. In VPS 2 or computer 2 we type: publish test-steam rockship-key 526f636b73686970206973206120636f6d70616e792072657365617263682061626f757420626c6f636b6368 61696e2e 4. In node admin we type to check steam in test-steam with rockship-key: subscribe test-steam liststreamkeyitems test-steam rockship-key. You will see data you steam in rockship key. Tip To see all blocks in blockchain, you can make explorer for this block with all steps in https://github.com/MultiCh ain/multichain-explorer
  • 16.
    3. HyperLedger Hyperledger isan open source like multichain but have a bigger ecosystem and supported by more big companies like IBM, Intel, Baidu, Cisco, Hitachi, ... We are continue researching hyperledger for developing application in blockchain.
  • 17.
    Thank you! We hopeyou are interested this tutorial. Please find the public full tutorial in Rockship libary : htttp://www.rockship.co