零基础EOS 节点部署,BP出块(二)-->节点连接
1.进入eosio主机终端,
cd ~/.local/share/eosio/nodeos/config
//编辑配置文件
vi config.ini
//修改p2p-server-address 为本机ip
p2p-server-address = 192.168.1.116:9876
//修改初始化创世块
enable-stale-production = true
//修改producer-name 为eosio(创世节点必须此名)
producer-name = eosio
//修改key
private-key = ["EOS5DkKbBZnSKNSV1iu27ovnygGhoCA99eH69KyNNkSkNrrbBoiRe","5KeqsXty9Sa8GfJgNfkckYxKKGcAWE4AWmUHiw6ifDcn3jjUg2i"]
//添加插件支持
plugin = eosio::producer_plugin
plugin = eosio::chain_api_plugin
plugin = eosio::wallet_api_plugin
#plugin = eosio::account_history_api_plugin
plugin = eosio::http_plugin
2.进入 eosio.bp1主机终端
cd ~/.local/share/eosio/nodeos/config
//编辑配置文件
vi config.ini
//修改p2p-server-address 为本机ip
p2p-server-address = 192.168.1.116:9876
//p2p-peer-address 添加 eosio和eosio.bp2 ip
p2p-peer-address = 192.168.1.112:9876
p2p-peer-address = 192.168.1.168:9876
//修改 producer-name
producer-name = eosio.bp1
//修改 key
private-key = ["EOS6hfh1yup4tZjbjhD3oPuZwMFqL4iUVehgMsukuvx5ojTWuurtT","5HragVTsSmmAg1mznNMDSeAp2ZezcNBw6SbczrNpNtUqRcx4vhh"]
//添加插件支持
plugin = eosio::chain_api_plugin
plugin = eosio::chain_plugin
plugin = eosio::producer_plugin
plugin = eosio::http_plugin
plugin = eosio::net_api_plugin
plugin = eosio::net_plugin
plugin = eosio::wallet_api_plugin
plugin = eosio::history_api_plugin
3.进入eosio.bp2主机终端 同2
//注意修改 config.ini
//p2p-peer-address 添加 eosio和eosio.bp1 ip