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

p2p: Add option to not clear address book with unsafe reset #3585

Closed
greg-szabo opened this issue Apr 23, 2019 · 2 comments
Closed

p2p: Add option to not clear address book with unsafe reset #3585

greg-szabo opened this issue Apr 23, 2019 · 2 comments
Labels
C:p2p Component: P2P pkg good first issue Contributions Welcome!!

Comments

@greg-szabo
Copy link
Contributor

Summary

During Cosmos Hub upgrades it would be nice to keep the address book intact. The upgrade usually has an unsafe-reset-all command in there.

Proposal

gaiad unsafe-reset-chain
OR
gaiad unsafe-reset-all --keep-address-book

The new command / flag would keep the address book intact.

@melekes melekes added the C:p2p Component: P2P pkg label Apr 23, 2019
@melekes
Copy link
Contributor

melekes commented Apr 23, 2019

I like --keep-addr-book flag 👍

@melekes melekes added good first issue Contributions Welcome!! help wanted labels Apr 23, 2019
@xla xla added the tools label Apr 23, 2019
@xla xla changed the title Add open to not clear address book with unsafe reset Add option to not clear address book with unsafe reset Apr 23, 2019
@xla xla changed the title Add option to not clear address book with unsafe reset p2p: Add option to not clear address book with unsafe reset Apr 23, 2019
@melekes
Copy link
Contributor

melekes commented May 1, 2019

Merged #3606 to develop.

Example usage:

$ TMHOME=/tmp ./build/tendermint unsafe_reset_all --keep-addr-book
I[2019-05-01|05:53:03.269] The address book remains intact              module=main
I[2019-05-01|05:53:03.271] Removed all blockchain history               module=main dir=/tmp/data
I[2019-05-01|05:53:03.282] Reset private validator file to genesis state module=main keyFile=/tmp/config/priv_validator_key.json stateFile=/tmp/data/priv_validator_state.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C:p2p Component: P2P pkg good first issue Contributions Welcome!!
Projects
None yet
Development

No branches or pull requests

3 participants