设置创世交易时出错——我做错了什么?
Error in setting up genesis transactions -- what am I doing wrong?
我正在尝试在此处完成“运行 节点”教程:https://github.com/cosmos/cosmos-sdk/blob/master/docs/run-node/run-node.md
不过我似乎遇到了一些问题,创世交易无法设置验证器,因此验证器集为空并且应用程序停止。我错过了什么吗?
我是 运行 script.sh
,在 error.log
中收到错误消息
simd version
: goz-phase-1-1119-g8572a84eb
script.sh
#!/bin/bash
set -eu
PATH=build:$PATH
MONIKER=foobar
simd init $MONIKER --chain-id my-test-chain
simd keys add my_validator --keyring-backend test
# Put the generated address in a variable for later use.
MY_VALIDATOR_ADDRESS=$(simd keys show my_validator -a --keyring-backend test)
simd add-genesis-account $MY_VALIDATOR_ADDRESS 100000000stake
# Create a gentx.
simd gentx my_validator 100000stake --chain-id my-test-chain --keyring-backend test
# Add the gentx to the genesis file.
simd collect-gentxs
simd start
error.log
:
5:09PM INF starting ABCI with Tendermint
5:09PM INF Starting multiAppConn service impl={"Logger":{}} module=proxy
5:09PM INF Starting localClient service connection=query impl="marshaling error: json: unsupported type: abcicli.Callback" module=abci-client
5:09PM INF Starting localClient service connection=snapshot impl="marshaling error: json: unsupported type: abcicli.Callback" module=abci-client
5:09PM INF Starting localClient service connection=mempool impl="marshaling error: json: unsupported type: abcicli.Callback" module=abci-client
5:09PM INF Starting localClient service connection=consensus impl="marshaling error: json: unsupported type: abcicli.Callback" module=abci-client
5:09PM INF Starting EventBus service impl={"Logger":{}} module=events
5:09PM INF Starting PubSub service impl={"Logger":{}} module=pubsub
5:09PM INF Starting IndexerService service impl={"Logger":{}} module=txindex
5:09PM INF ABCI Handshake App Info hash= height=0 module=consensus protocol-version=0 software-version=
5:09PM INF ABCI Replay Blocks appHeight=0 module=consensus stateHeight=0 storeHeight=0
5:09PM INF asserting crisis invariants inv=0/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=1/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=2/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=3/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=4/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=5/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=6/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=7/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=8/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=9/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=10/11 module=x/crisis
5:09PM INF asserted all invariants duration=0.844065 height=0 module=x/crisis
5:09PM INF created new capability module=ibc name=ports/transfer
5:09PM INF port binded module=x/ibc/port port=transfer
5:09PM INF claimed capability capability=1 module=transfer name=ports/transfer
Error: error during handshake: error on replay: validator set is nil in genesis and still empty after InitChain
Usage:
simd start [flags]
Flags:
--abci string specify abci transport (socket | grpc) (default "socket")
... [other usage info]
我自己尝试过,看到了同样的错误,但能够通过将 simd gentx
命令中的股份数量增加到 100000000stake
来修复它。它现在的工作方式如下:
#!/bin/bash
set -eu
PATH=build:$PATH
MONIKER=foobar
simd init $MONIKER --chain-id my-test-chain
simd keys add my_validator --keyring-backend test
# Put the generated address in a variable for later use.
MY_VALIDATOR_ADDRESS=$(simd keys show my_validator -a --keyring-backend test)
simd add-genesis-account $MY_VALIDATOR_ADDRESS 100000000stake
# Create a gentx.
simd gentx my_validator 100000000stake --chain-id my-test-chain --keyring-backend test
# Add the gentx to the genesis file.
simd collect-gentxs
# simd start
您从哪里得到 script.sh
文件?我没有在 https://github.com/cosmos/cosmos-sdk/blob/master/docs/run-node/run-node.md
中看到它
okwme的回答是正确的。但是,如果您想使用该帐户进行更多游戏,则还应增加初始余额(用 simd add-genesis-account
设置)。在本教程中,稍后该帐户将一些 stake
发送到另一个帐户。但是通过上面的脚本,委托了$MY_VALIDATOR_ADDRESS
中的全部金额,所以none可以发送。
我正在尝试在此处完成“运行 节点”教程:https://github.com/cosmos/cosmos-sdk/blob/master/docs/run-node/run-node.md
不过我似乎遇到了一些问题,创世交易无法设置验证器,因此验证器集为空并且应用程序停止。我错过了什么吗?
我是 运行 script.sh
,在 error.log
simd version
: goz-phase-1-1119-g8572a84eb
script.sh
#!/bin/bash
set -eu
PATH=build:$PATH
MONIKER=foobar
simd init $MONIKER --chain-id my-test-chain
simd keys add my_validator --keyring-backend test
# Put the generated address in a variable for later use.
MY_VALIDATOR_ADDRESS=$(simd keys show my_validator -a --keyring-backend test)
simd add-genesis-account $MY_VALIDATOR_ADDRESS 100000000stake
# Create a gentx.
simd gentx my_validator 100000stake --chain-id my-test-chain --keyring-backend test
# Add the gentx to the genesis file.
simd collect-gentxs
simd start
error.log
:
5:09PM INF starting ABCI with Tendermint
5:09PM INF Starting multiAppConn service impl={"Logger":{}} module=proxy
5:09PM INF Starting localClient service connection=query impl="marshaling error: json: unsupported type: abcicli.Callback" module=abci-client
5:09PM INF Starting localClient service connection=snapshot impl="marshaling error: json: unsupported type: abcicli.Callback" module=abci-client
5:09PM INF Starting localClient service connection=mempool impl="marshaling error: json: unsupported type: abcicli.Callback" module=abci-client
5:09PM INF Starting localClient service connection=consensus impl="marshaling error: json: unsupported type: abcicli.Callback" module=abci-client
5:09PM INF Starting EventBus service impl={"Logger":{}} module=events
5:09PM INF Starting PubSub service impl={"Logger":{}} module=pubsub
5:09PM INF Starting IndexerService service impl={"Logger":{}} module=txindex
5:09PM INF ABCI Handshake App Info hash= height=0 module=consensus protocol-version=0 software-version=
5:09PM INF ABCI Replay Blocks appHeight=0 module=consensus stateHeight=0 storeHeight=0
5:09PM INF asserting crisis invariants inv=0/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=1/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=2/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=3/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=4/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=5/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=6/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=7/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=8/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=9/11 module=x/crisis
5:09PM INF asserting crisis invariants inv=10/11 module=x/crisis
5:09PM INF asserted all invariants duration=0.844065 height=0 module=x/crisis
5:09PM INF created new capability module=ibc name=ports/transfer
5:09PM INF port binded module=x/ibc/port port=transfer
5:09PM INF claimed capability capability=1 module=transfer name=ports/transfer
Error: error during handshake: error on replay: validator set is nil in genesis and still empty after InitChain
Usage:
simd start [flags]
Flags:
--abci string specify abci transport (socket | grpc) (default "socket")
... [other usage info]
我自己尝试过,看到了同样的错误,但能够通过将 simd gentx
命令中的股份数量增加到 100000000stake
来修复它。它现在的工作方式如下:
#!/bin/bash
set -eu
PATH=build:$PATH
MONIKER=foobar
simd init $MONIKER --chain-id my-test-chain
simd keys add my_validator --keyring-backend test
# Put the generated address in a variable for later use.
MY_VALIDATOR_ADDRESS=$(simd keys show my_validator -a --keyring-backend test)
simd add-genesis-account $MY_VALIDATOR_ADDRESS 100000000stake
# Create a gentx.
simd gentx my_validator 100000000stake --chain-id my-test-chain --keyring-backend test
# Add the gentx to the genesis file.
simd collect-gentxs
# simd start
您从哪里得到 script.sh
文件?我没有在 https://github.com/cosmos/cosmos-sdk/blob/master/docs/run-node/run-node.md
okwme的回答是正确的。但是,如果您想使用该帐户进行更多游戏,则还应增加初始余额(用 simd add-genesis-account
设置)。在本教程中,稍后该帐户将一些 stake
发送到另一个帐户。但是通过上面的脚本,委托了$MY_VALIDATOR_ADDRESS
中的全部金额,所以none可以发送。