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

overlord链间歇性同步区块 #213

Open
rink1969 opened this issue Feb 27, 2023 · 0 comments
Open

overlord链间歇性同步区块 #213

rink1969 opened this issue Feb 27, 2023 · 0 comments
Assignees

Comments

@rink1969
Copy link
Member

2023-02-16T06:02:45.548909Z  INFO store: storage::db: store_all_block_data: height(104) start                                                                                                                                                                                              │
│ 2023-02-16T06:02:45.549542Z  INFO store: storage::db: store_all_block_data: height(104) finish                                                                                                                                                                                             │
│ 2023-02-16T06:02:48.566154Z  INFO store: storage::db: store_all_block_data: height(105) start                                                                                                                                                                                              │
│ 2023-02-16T06:02:48.566819Z  INFO store: storage::db: store_all_block_data: height(105) finish                                                                                                                                                                                             │
│ 2023-02-16T06:02:54.952859Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:03:04.932347Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:03:14.950916Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:03:25.108714Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:03:35.004521Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:03:44.934317Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:03:55.035932Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:04:04.950905Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:04:14.925013Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:04:25.045829Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:04:35.006285Z  INFO storage::health_check: healthcheck entry!                                                                                                                                                                                                                │
│ 2023-02-16T06:04:38.646835Z  INFO store: storage::db: store_all_block_data: height(106) start                                                                                                                                                                                              │
│ 2023-02-16T06:04:38.648078Z  INFO store: storage::db: store_all_block_data: height(106) finish                                                                                                                                                                                             │
│ 2023-02-16T06:04:38.653829Z  INFO store: storage::db: store_all_block_data: height(107) start                                                                                                                                                                                              │
│ 2023-02-16T06:04:38.654206Z  INFO store: storage::db: store_all_block_data: height(107) finish                                                                                                                                                                                             │
│ 2023-02-16T06:04:38.663554Z  INFO store: storage::db: store_all_block_data: height(108) start 

中间有很长一段时间不同步,然后突然同步20多个区块,跟上其他节点,周而复始。

原因分析:
一段时间同步后,节点会出一个proposal,导致链进入online mod。
但是因为网络半连接的问题,迟迟无法达成共识。本节点高度就慢慢落后了。
这时本来应该从其他节点同步区块的。但是因为一直处于online mod,不会发送sync req。

而要从online mod切换到sync mod有2个条件:

  1. 对端节点高度大于当前节点的高度
  2. 没有候选块

清理掉当前已经存在的候选块的条件:

  1. 正常的commit block
  2. 收到更高高度的proposal
  3. set node返回early status
  4. inner health check
  5. 收到同步区块

其中1,3,5都显然不可能,只剩下2和4。

2在使用bft的时候是成立的,bft收到未来高度的proposal也会拿来检测。
但是overlord不会,只会检测当前高度的proposal。

所以只能靠4来触发同步,而inner health check是按时间触发的,也就是看到过一段时间突然同步一些区块的原因。

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

3 participants