1

Ethereum Setup :

  1. I have created the private blockchain using two nodes (node1, node2).
  2. I have mounted a share drive between these two node to store keystore values so that both nodes can have same account details.
  3. I have used --keystore option to point shared keystore location

Issue: whenever I create an account from node1, it does not reflect into node2. but if i restart both node, the newly added account is getting reflected in both nodes.

Please suggest how to synchronize accounts in both node simultaneously ?

Please correct me if my approach is wrong.

0

I was also facing the same issue. Going through the documentation, I found that it is not required to synchronise accounts between different nodes.

From the documentation:

Creating a key is tantamount to creating an account.

  • You don’t need to tell anybody else you’re doing it.
  • You don’t need to synchronize with the blockchain
  • You don’t need to run a client
  • You don’t even need to be connected to the internet

So you do not even require to create share drive for the two nodes. Both nodes can have own keyfiles until you want to use accounts from both the nodes.

  • Thanks for your reply Ritesh, As per my use case, I have to use account from both the nodes. – Gunavant Jan 10 '18 at 13:34
0

Unfortunately, you cannot do it. I was experiencing the same problem. The best solution for your problem is to copy the keystore manually and merge it with all the keystores in all the nodes.

0

You can :

  1. Create the keys offline (outside the chain)
  2. Import same set of keys to each node (so that accounts are available on all nodes)

Following API can be used from various client languages (JS, Python etc).

https://github.com/ethereum/go-ethereum/wiki/Management-APIs#personal_importrawkey

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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