November 2018
Intermediate to advanced
528 pages
13h 21m
English
Now that we have the genesis.json file, let's forge the genesis block. Both nodes should initialize their chain using the same genesis file by running the following commands:
geth --datadir nodeA init genesis.jsongeth --datadir nodeB init genesis.json
All set. Now you can start your new chain on both nodes using two Terminals.
Starting node A as follows:
geth --datadir nodeA --networkid 1234 --rpc --rpcport 8545 --port 8888 --rpcapi “db,eth,net,web3,personal,miner,admin” --cache=128 --rpcaddr 0.0.0.0 --rpccorsdomain "*" console
And it's the same for node B (update parameters specific to the node):
geth --datadir nodeB --networkid 1234 --rpc --rpcport 9545 --port 9999 --rpcapi “db,eth,net,web3,personal,miner,admin” --cache=128 ...
Read now
Unlock full access