Ethereum builds a node cluster

Note: I am running on Centos7, the firewall is turned off in the early stage, systemctl stop firewalld

1. Start the Ethereum node, ./geth --datadir "chain" --networkid 100000 --port 61910 --rpcport 8200 console 2>> geth.log

    If it has been started, you can go back to Geth's JavaScript interface through the ipc file: ./geth attach "chain/geth.ipc"

2. View your own node information: admin.nodeInfo.endoe

3. The above will show


4. Start again a Geth client admin.addPeer ( "enode: // 6ff8ef9dd25bea0d5346f62f9a092d62cd7e912411a8f36a14f14486fed39b9183e292b9f988ed1c9d6bedc8802adfc3507c0b7743bc70588e9028f40fb4afda @ [::]: 61910"), [], fill the first machine ip address

5. You can view the connected node information through admin.peers.

 

I used the Ethereum Wallet of Ethereum to connect to my private chain on Windows, but when the wallet is started, a Geth will be established to connect to the public network,

So I installed a Geth on windows, and added it to my private chain after startup (the firewall under windows will also affect the node connection, because the firewall under my Centos is closed, so the geth in windows can connect to Centos), when I start the wallet Do not start directly, under cmd:

"Ethereum Wallet.exe" --rpc "\\.\pipe\geth.ipc", which specifies the connection to our private chain.


Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326111222&siteId=291194637