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

mempool 模块导致交易查重出现问题 #948

Open
caopingcp opened this issue Jan 20, 2021 · 1 comment
Open

mempool 模块导致交易查重出现问题 #948

caopingcp opened this issue Jan 20, 2021 · 1 comment
Milestone

Comments

@caopingcp
Copy link
Contributor

四个节点组成的 tendermint 集群,分别往四个节点发送大量交易(每秒2万笔),四个节点均出现 ErrMemFull 错误,此时 mempool 也缓存了大量交易(15多万笔),节点通过从 mempool 获取交易并查重 来判断是否有未处理交易,从而决定是否进入共识流程打包区块
当停止发送交易后,由于节点还有未处理交易,仍然进入共识流程,直至 mempool 缓存没有交易
blockchain模块和发送的交易都使用 TxHeight 选项

然而可以复现出:有两个节点率先处理完 mempool 缓存的交易,不再进入共识,通过 ./chain33-cli net peer info |grep mempoolSize 可以看到值为0, 而其他两个节点的值不为0(几万笔),所以依然进入共识,由于不满足多于 2/3 的节点参与共识,整个共识流程会出现问题;继续观察一段时间,其他两个节点 mempoolSize 值会慢慢减少,直至为 0,说明原先缓存的交易不是合法交易,而之前的交易查重也存在问题。

@bysomeone
Copy link
Collaborator

这个问题可以用最新修复版本测试下,看能不能复现出来,单纯看问题现象还是有点抽象

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