You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the validator set is greater than 1, but we have no peers, we will be stuck in fast sync, even if we have more than 2/3 of the voting power.
This is easy to replicate. Run a node with tendermint node --proxy_app=persistent_kvstore. Add a new validator with 1/11 of the voting power: curl localhost:26657/broadcast_tx_sync?tx=\"val:0e783029302e8e4713f2c3085ee35c3335bbfd698f2bba09d3196aca3872d651/1\". Now restart the node and it will be stuck in fast sync.
We treat the special case of being the only validator in https://github.com/tendermint/tendermint/blob/develop/node/node.go#L236. We should generalize this - instead of just checking if we're the sole validator, we should check if we have > 2/3 of the voting power - if so, we can skip fast sync. If we have less than 2/3 of the voting power, we'll need at least one peer before we can switch out of fast sync.
Discovered this while trying to test that #2747 is backwards compatible by making validator set changes on current version of the software and then trying to run that branch.
The text was updated successfully, but these errors were encountered:
Never mind - we don't necessarily want this. It's possible a node with +2/3 is still behind and wants to sync up. It's even possible if theres just a single validator. But we'll leave the heuristic for now and others can just turn off fast sync if they find themselves in this position.
If the validator set is greater than 1, but we have no peers, we will be stuck in fast sync, even if we have more than 2/3 of the voting power.
This is easy to replicate. Run a node with
tendermint node --proxy_app=persistent_kvstore
. Add a new validator with 1/11 of the voting power:curl localhost:26657/broadcast_tx_sync?tx=\"val:0e783029302e8e4713f2c3085ee35c3335bbfd698f2bba09d3196aca3872d651/1\"
. Now restart the node and it will be stuck in fast sync.We treat the special case of being the only validator in https://github.com/tendermint/tendermint/blob/develop/node/node.go#L236. We should generalize this - instead of just checking if we're the sole validator, we should check if we have > 2/3 of the voting power - if so, we can skip fast sync. If we have less than 2/3 of the voting power, we'll need at least one peer before we can switch out of fast sync.
Discovered this while trying to test that #2747 is backwards compatible by making validator set changes on current version of the software and then trying to run that branch.
The text was updated successfully, but these errors were encountered: