Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to export chainspec from already running node? #137

Closed
ashi20192020 opened this issue Mar 31, 2021 · 1 comment
Closed

How to export chainspec from already running node? #137

ashi20192020 opened this issue Mar 31, 2021 · 1 comment
Assignees

Comments

@ashi20192020
Copy link

We have built a custom blockchain on top of substrate, & we started the node few months back without generating the chainSpec file. Later we got to know that we should generate the chainSpec file & use that every time we want to start the new node, so we generated the new chainSpec file. But we cant use this chainSpec, since it has different block hash than the one we are already running, so we are getting the error saying node which we are trying connect with as boot node is at different chain than we expect it to be.
I am getting below error

Bootnode with peer id xxx is on a different chain (our genesis: 0x6913…c3c3 theirs: 0x9be3…54d6)

Is there any solution for this scenario? Can we export chainspec from already running node, so that we can use it while starting new node?

@nuke-web3 nuke-web3 self-assigned this Apr 7, 2021
@nuke-web3
Copy link
Contributor

The chainspec file should be passed to all nodes from the original node. There are non-determinism issues in generating this file. See the last note in the private network tutorial for more on this.

You likely need to perform a Re-Genesis if you somehow lost this file, and generate a new chain-spec that you then embed into the node's source for others to make sure they get the right one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants