具有启用权限错误的 Hyperledger besu

Hyperledger besu with permissioning enabled error

我正在使用 Hyperledger besu 提供的快速启动网络,我想测试并查看权限如何与权限管理 dapp 一起工作。我使用这个回购协议:https://github.com/bretthenderson/besu-quickstart 因此,当我 运行 运行-permissioning.sh 构建 dapp 的脚本和 运行 测试网络一切正常并且网络成功启动时,当我 运行 运行-permissioning-dapp.sh 脚本工作正常,它编译和部署许可智能合约,然后在启用许可的情况下重新启动网络,但之后引导节点容器崩溃并显示这些日志:

2021-04-02 10:25:11.294+00:00 | main | INFO  | KeyPairUtil | Loaded public key 0xc1979a8a48693db804316b5acebe35e11731e1fb1c9c21ff7268ab25db6f6e03390a429b83cf0ec0865a7205f2669ec1ace652a3def11e2e01571c74939cbe22 from /opt/besu/keys/key
Setting logging level to INFO
2021-04-02 10:25:42.930+00:00 | main | INFO  | AbstractAltBnPrecompiledContract | Using LibEthPairings native alt bn128
2021-04-02 10:25:55.841+00:00 | main | INFO  | SECP256K1 | Using native secp256k1
2021-04-02 10:25:55.933+00:00 | main | INFO  | Besu | Starting Besu version: besu/v21.1.3/linux-x86_64/oracle_openjdk-java-11
2021-04-02 10:25:59.261+00:00 | main | WARN  | Besu | --min-gas-price has been ignored because --miner-enabled was not defined on the command line.
2021-04-02 10:26:00.299+00:00 | main | INFO  | Besu | Static Nodes file = /opt/besu/data/static-nodes.json
2021-04-02 10:26:00.322+00:00 | main | INFO  | StaticNodesParser | StaticNodes file /opt/besu/data/static-nodes.json does not exist, no static connections will be created.
2021-04-02 10:26:00.351+00:00 | main | INFO  | Besu | Connecting to 0 static nodes.
2021-04-02 10:26:00.368+00:00 | main | INFO  | Besu | Security Module: localfile
2021-04-02 10:26:00.661+00:00 | main | INFO  | DatabaseMetadata | Lookup database metadata file in data directory: /opt/besu/data
2021-04-02 10:26:01.646+00:00 | main | INFO  | RocksDBKeyValueStorageFactory | Existing database detected at /opt/besu/data. Version 1
2021-04-02 10:26:03.790+00:00 | main | INFO  | KeyPairUtil | Loaded public key 0xc1979a8a48693db804316b5acebe35e11731e1fb1c9c21ff7268ab25db6f6e03390a429b83cf0ec0865a7205f2669ec1ace652a3def11e2e01571c74939cbe22 from /opt/besu/keys/key
2021-04-02 10:26:04.310+00:00 | main | INFO  | ProtocolScheduleBuilder | Protocol schedule created with milestones: [Petersburg: 0]
ANTLR Tool version 4.7.1 used for code generation does not match the current runtime version 4.8ANTLR Runtime version 4.7.1 used for parser compilation does not match the current runtime version 4.8ANTLR Tool version 4.7.1 used for code generation does not match the current runtime version 4.8ANTLR Runtime version 4.7.1 used for parser compilation does not match the current runtime version 4.8ANTLR Tool version 4.7.1 used for code generation does not match the current runtime version 4.8ANTLR Runtime version 4.7.1 used for parser compilation does not match the current runtime version 4.8ANTLR Tool version 4.7.1 used for code generation does not match the current runtime version 4.8ANTLR Runtime version 4.7.1 used for parser compilation does not match the current runtime version 4.8

Error: node permissioning contract at address 0x0000000000000000000000000000000000009999 does not match the expected interface version 1 

我在任何地方都找不到关于这个错误的任何信息,因为 hyperledger besu 的社区非常小...

问题的解决方法是将 --permissions-nodes-contract-version=2 添加到您的 besu 命令行。

这是因为在许可智能合约 repo 的 v 2.0.0 中,我们根据变更日志更改了界面 https://github.com/ConsenSys/permissioning-smart-contracts/releases/tag/v2.0.0 它在 besu 文档中 https://besu.hyperledger.org/en/stable/HowTo/Limit-Access/Specify-Perm-Version/ 但我已经报告了这个问题并且它已在链上许可教程的文档中得到修复。

您可以在此处找到更多详细信息

  1. Github issue
  2. Besu Docs