I have 2 nodes running on private network under the same network id connecting through

sudo geth --identity "testpython manage.py runserver" --networkid 1100 --mine --nodiscover --rpc --rpcport 8544 --rpccorsdomain "*" --rpcapi "eth,web3" --port 30304 --ipcpath ~/.ethereum/geth.ipc --genesis /home/user/genesis.json --datadir /home/user/genesis console privatenet 2>/home/user/genesis/log_output5 

In one node and in other with different ports. It has same genesis.json and connected to the same network. When i connect via,


It will show the connection in admin.peers and in few seconds it will go off in both the nodes. it keep connecting and disconnecting between the nodes. and in admin.peers remoteAddress port is coming as 59823 though I have given 30305 port.

localAddress: "",
remoteAddress: ""

I felt this is causing me not to do node to node ether transaction. once node to node transaction has happened. after that i couldnot.

I read in other links that static-nodes.json / trusted-nodes.json may help in having stable connection. please help me

  1. How to have stable connection
  2. If we use static-nodes.json / trusted-nodes.json , how to use and which one to use. syntax please
  3. How to do transactions in one node and mining from another node?

Losing connection between nodes on private network

2 Answers 2


Data format


You can configure permanent static nodes by putting something like the following into <datadir>/static-nodes.json

Common problems with connectivity

Sometimes you just can't get connected. The most common reasons are:

  1. Your local time might be incorrect. An accurate clock is required to participate in the Ethereum network. Check your OS for how to resync your clock (example sudo ntpdate -s time.nist.gov) because even 12 seconds too fast can lead to 0 peers.
  2. Some firewall configurations can prevent UDP traffic from flowing. You can use the static nodes feature or admin.addPeer() on the console to configure connections by hand.

1. https://github.com/ethereum/homestead-guide/blob/master/source/network/connecting-to-the-network.rst#static-nodes-trusted-nodes-and-boot-nodes


Geth also supports a feature called static nodes if you have certain peers you always want to connect to. Static nodes are re-connected on disconnects. You can configure permanent static nodes by putting something like the following into <datadir>/geth/static-nodes.json:



Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.