注:这里的工作目录路径为:/root/fisco/generator; 这里为机构C新增节点
cp -r scripts/gen_node_cert.sh ./
若没有此脚本,则执行下面命令获取:
curl -LO https://raw.githubusercontent.com/FISCO-BCOS/FISCO-BCOS/master/tools/gen_node_cert.sh
chmod u+x gen_node_cert.sh
cp -r scripts/cert.cnf ./dir_agency_ca/agencyC/
cp -r meta/agency.srl dir_agency_ca/agencyC/
./gen_node_cert.sh -c dir_agency_ca/agencyC/ -o node_192.168.xxx.xxx_30304
cd nodeC/
cp -r node_192.168.xxx.xxx_30302/config.ini node_192.168.xxx.xxx_30302/start.sh node_192.168.xxx.xxx_30302/stop.sh node_192.168.xxx.xxx_30304/
vi node_192.168.xxx.xxx_30304/config.ini
cp -r node_192.168.xxx.xxx_30302/conf/group.3.genesis node_192.168.xxx.xxx_30304/conf
cp -r node_192.168.xxx.xxx_30302/conf/group.3.ini node_192.168.xxx.xxx_30304/conf
cp -r node_192.168.xxx.xxx_30302/fisco-bcos node_192.168.xxx.xxx_30304/
cd node_192.168.xxx.xxx_30304/
mkdir -p log
./start.sh
more conf/node.nodeid
启动控制台将新节点设置为共识节点:
addSealer 07d5d61f6385932c3b6adaa299f279d4976967d5206872e895443fdba3924e64568f910e6dd919de161b719ac96ebd0deab376de8ee1eee4cc02139ab6ec2ef4
tail -f log/* | grep +++
至此,原有机构内新增节点操作过程结束