Home | 簡體中文 | 繁體中文 | 雜文 | 知乎專欄 | Github | OSChina 博客 | 雲社區 | 雲棲社區 | Facebook | Linkedin | 視頻教程 | 打賞(Donations) | About
知乎專欄多維度架構 | 微信號 netkiller-ebook | QQ群:128659835 請註明“讀者”

第 4 章 EOS 安裝

目錄

4.1. CentOS
4.2. Mac
4.3. Docker 開發環境
4.4. 主網
4.5. 啟動 EOS 節點
4.5.1. EOS 本地網
4.5.1.1. 單節點私鏈
4.5.1.2. 單機多節點
4.5.1.3. 多機多節點
4.5.1.3.1. 節點一
4.5.1.3.2. 節點二
4.5.1.3.3. 節點三
4.5.1.3.4. 進入 Node 1 創建錢包和部署合約
4.5.2. 測試網
4.5.2.1. Public Testnet Endpoints(公共測試網絡的接入點)
4.5.2.1.1. testnet1.eos.io
4.5.2.1.2. http://testnet.eoswtz.com
4.5.2.2. 本地連接到測試網
4.5.2.3. EOS (testnet) Explorer (Dawn 2.0)
4.5.2.4. EOS Jungle Testnet Monitor (Dawn 4.0)
4.5.3. 主網
4.5.3.1. 創世區塊
4.5.3.2. eosnodes.privex.io
4.5.3.2.1. 創世區塊
4.5.3.2.2. 主網超級節點
4.5.3.3. mainnet.genereos.io
4.5.3.4. mainnet.eoswz.com
4.6. nodeos 命令
4.6.1.
4.6.1.1. --contracts-console
4.6.2. config.ini 配置檔案
4.6.2.1. 插件配置

4.1. CentOS

		 
yum install -y centos-release-scl
yum install -y devtoolset-7
yum install -y git

yum install -y gcc gcc-c++ make patch cmake automake autoconf \
libtool ocaml doxygen graphviz-devel libicu-devel bzip2-devel gmp-devel python-devel gettext-devel


cd /usr/local/src/
git clone https://github.com/EOSIO/eos --recursive
cd eos/
# git submodule update --init --recursive

./eosio_build.sh
		
		

		
[root@iZj6c7cj14ulhfndlmeicbZ eos]# ./eosio_build.sh

	Beginning build version: 1.2
	Wed May  2 03:15:34 UTC 2018
	User: root
	git head id: f537bc50b21a7807ff0ee3af83d8f560ce09afa5
	Current branch: * master

	ARCHITECTURE: Linux

	OS name: CentOS Linux
	OS Version: 7
	CPU speed: 2494Mhz
	CPU cores: 4
	Physical Memory: 7822 Mgb
	Disk install: /dev/vda1
	Disk space total: 492G
	Disk space available: 138G

	Checking Yum installation
	Yum installation found at /usr/bin/yum.

	Checking installation of Centos Software Collections Repository.

	The Centos Software Collections Repository, devtoolset-7 and Python3 are required to install EOSIO.
	Do you wish to install and enable this repository, devtoolset-7 and Python3 packages?
1) Yes
2) No
#? 1
		
		

輸入 1 回車繼續

		
Complete!

	YUM repository successfully updated.

	Checking YUM for installed dependencies.

	Package git found.
	Package autoconf found.
	Package automake found.
	Package libtool  NOT  found.
	Package ocaml.x86_64  NOT  found.
	Package doxygen  NOT  found.
	Package graphviz-devel.x86_64  NOT  found.
	Package libicu-devel.x86_64  NOT  found.
	Package bzip2-devel.x86_64  NOT  found.
	Package openssl-devel.x86_64  NOT  found.
	Package gmp-devel.x86_64  NOT  found.
	Package python-devel.x86_64  NOT  found.
	Package gettext-devel.x86_64  NOT  found.

	The following dependencies are required to install EOSIO.

	1. libtool
	2. ocaml.x86_64
	3. doxygen
	4. graphviz-devel.x86_64
	5. libicu-devel.x86_64
	6. bzip2-devel.x86_64
	7. openssl-devel.x86_64
	8. gmp-devel.x86_64
	9. python-devel.x86_64
	10. gettext-devel.x86_64


	Do you wish to install these dependencies?
1) Yes
2) No
#?
		
		

輸入 1 回車繼續

			

	 _______  _______  _______ _________ _______
	(  ____ \(  ___  )(  ____ \\__   __/(  ___  )
	| (    \/| (   ) || (    \/   ) (   | (   ) |
	| (__    | |   | || (_____    | |   | |   | |
	|  __)   | |   | |(_____  )   | |   | |   | |
	| (      | |   | |      ) |   | |   | |   | |
	| (____/\| (___) |/\____) |___) (___| (___) |
	(_______/(_______)\_______)\_______/(_______)

	EOSIO has been successfully built. 01:20:59

	To verify your installation run the following commands:

	/root/opt/mongodb/bin/mongod -f /root/opt/mongodb/mongod.conf &
	source /opt/rh/python33/enable
	export PATH=${HOME}/opt/mongodb/bin:$PATH
	cd /usr/local/src/eos/build; make test

	For more information:
	EOSIO website: https://eos.io
	EOSIO Telegram channel @ https://t.me/EOSProject
	EOSIO resources: https://eos.io/resources/
	EOSIO Stack Exchange: https://eosio.stackexchange.com
	EOSIO wiki: https://github.com/EOSIO/eos/wiki
			
			
		

這裡跳過 make test 直接安裝

		
cd build
make install
		
		

預設配置檔案 cofnig.ini

		
[root@netkiller config]# grep -v "^#" config.ini | grep -v "^$"
bnet-endpoint = 0.0.0.0:4321
bnet-follow-irreversible = 0
bnet-no-trx = false
bnet-peer-log-format = ["${_name}" ${_ip}:${_port}]
blocks-dir = "blocks"
chain-state-db-size-mb = 1024
reversible-blocks-db-size-mb = 340
contracts-console = false
https-client-validate-peers = 1
http-server-address = 127.0.0.1:8888
access-control-allow-credentials = false
max-body-size = 1048576
verbose-http-errors = false
p2p-listen-endpoint = 0.0.0.0:9876
p2p-max-nodes-per-host = 1
agent-name = "EOS Test Agent"
allowed-connection = any
max-clients = 25
connection-cleanup-period = 30
network-version-match = 0
sync-fetch-span = 100
max-implicit-request = 1500
use-socket-read-watermark = 0
peer-log-format = ["${_name}" ${_ip}:${_port}]
enable-stale-production = false
pause-on-startup = false
max-transaction-time = 30
max-irreversible-block-age = -1
signature-provider = EOS6MRyAjQq8ud7hVNYcfnVPJqcVpscN5So8BhtHuGYqET5GDW5CV=KEY:5KQwrPbwdL6PhXujxW37FSSQZ1JiwsST4cqQzDeyXtP79zkvFD3
keosd-provider-timeout = 5
txn-reference-block-lag = 0
wallet-dir = "."
unlock-timeout = 900