zeta-chain / network-athens3

genesis, script, docs for athens3
45 stars 55 forks source link

Full node cannot be started #66

Open barryz opened 1 year ago

barryz commented 1 year ago

Hi, Zeta team. I am from the DeBank team. We have noticed that Zetachain has released the Athens3 testnet and we would like to integrate with it as soon as possible. However, we encountered an issue when trying to deploy our own RPC node using the instructions provided in the official documentation for deploying a full node. The specific error message is pasted below.

barryz commented 1 year ago

Here is the panic log when we starting zetacored service:

zeta-testnet  | github.com/spf13/cobra.(*Command).ExecuteC(0xc0013f3500)
zeta-testnet  |     /go/pkg/mod/github.com/spf13/cobra@v1.6.1/command.go:1044 +0x3bd
zeta-testnet  | github.com/spf13/cobra.(*Command).Execute(...)
zeta-testnet  |     /go/pkg/mod/github.com/spf13/cobra@v1.6.1/command.go:968
zeta-testnet  | github.com/spf13/cobra.(*Command).ExecuteContext(...)
zeta-testnet  |     /go/pkg/mod/github.com/spf13/cobra@v1.6.1/command.go:961
zeta-testnet  | github.com/cosmos/cosmos-sdk/server/cmd.Execute(0x254e0b0?, {0x0, 0x0}, {0xc00012f5a0, 0x10})
zeta-testnet  |     /go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.46.8/server/cmd/execute.go:36 +0x20f
zeta-testnet  | main.main()
zeta-testnet  |     /go/delivery/zeta-node/cmd/zetacored/main.go:17 +0x35
zeta-testnet  | {"level":"info","time":"2023-07-27T06:00:16Z","message":"Unlocking keyring"}
zeta-testnet  | {"level":"info","time":"2023-07-27T06:00:16Z","message":"starting ABCI with Tendermint"}
zeta-testnet  | {"level":"info","time":"2023-07-27T06:00:16Z","message":"starting node with ABCI Tendermint in-process"}
zeta-testnet  | {"level":"info","server":"node","module":"proxy","impl":"multiAppConn","msg":{},"time":"2023-07-27T06:00:16Z","message":"service start"}
zeta-testnet  | {"level":"info","server":"node","module":"proxy","connection":"query","module":"abci-client","impl":"localClient","msg":{},"time":"2023-07-27T06:00:16Z","message":"service start"}
zeta-testnet  | {"level":"info","server":"node","module":"proxy","connection":"snapshot","module":"abci-client","impl":"localClient","msg":{},"time":"2023-07-27T06:00:16Z","message":"service start"}
zeta-testnet  | {"level":"info","server":"node","module":"proxy","connection":"mempool","module":"abci-client","impl":"localClient","msg":{},"time":"2023-07-27T06:00:16Z","message":"service start"}
zeta-testnet  | {"level":"info","server":"node","module":"proxy","connection":"consensus","module":"abci-client","impl":"localClient","msg":{},"time":"2023-07-27T06:00:16Z","message":"service start"}
zeta-testnet  | {"level":"info","server":"node","module":"events","impl":"EventBus","msg":{},"time":"2023-07-27T06:00:16Z","message":"service start"}
zeta-testnet  | {"level":"info","server":"node","module":"events","module":"pubsub","impl":"PubSub","msg":{},"time":"2023-07-27T06:00:16Z","message":"service start"}
zeta-testnet  | {"level":"info","server":"node","module":"txindex","impl":"IndexerService","msg":{},"time":"2023-07-27T06:00:16Z","message":"service start"}
zeta-testnet  | {"level":"info","server":"node","module":"consensus","hash":"","height":0,"protocol-version":0,"software-version":"","time":"2023-07-27T06:00:16Z","message":"ABCI Handshake App Info"}
zeta-testnet  | {"level":"info","server":"node","module":"consensus","appHeight":0,"stateHeight":0,"storeHeight":0,"time":"2023-07-27T06:00:16Z","message":"ABCI Replay Blocks"}
zeta-testnet  | {"level":"info","time":"2023-07-27T06:00:16Z","message":"initializing blockchain state from genesis.json"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"1/12","name":"gov/module-account","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"2/12","name":"group/Group-TotalWeight","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"3/12","name":"bank/nonnegative-outstanding","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"4/12","name":"bank/total-supply","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"5/12","name":"distribution/nonnegative-outstanding","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"6/12","name":"distribution/can-withdraw","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"7/12","name":"distribution/reference-count","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"8/12","name":"distribution/module-account","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"9/12","name":"staking/module-accounts","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"10/12","name":"staking/nonnegative-power","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"11/12","name":"staking/positive-delegation","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","inv":"12/12","name":"staking/delegator-shares","time":"2023-07-27T06:00:16Z","message":"asserting crisis invariants"}
zeta-testnet  | {"level":"info","module":"x/crisis","duration":0.53028,"height":0,"time":"2023-07-27T06:00:16Z","message":"asserted all invariants"}
zeta-testnet  | panic: unknown field "keygen" in types.GenesisState
zeta-testnet  |
zeta-testnet  | goroutine 1 [running]:
zeta-testnet  | github.com/cosmos/cosmos-sdk/codec.(*ProtoCodec).MustUnmarshalJSON(0x7d0?, {0xc000e5e000?, 0x1e?, 0x64?}, {0x3b5d890?, 0xc00117b040?})
zeta-testnet  |     /go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.46.8/codec/proto_codec.go:187 +0x45
zeta-testnet  | github.com/zeta-chain/zetacore/x/crosschain.AppModule.InitGenesis({{{0x3b803b8, 0xc001278960}}, {{0x3b803b8, 0xc001278960}, {0x3b45810, 0xc001e9c640}, {0x3b45810, 0x0}, {0x3b45a40, 0xc001f34f20}, ...}, ...}, ...)
zeta-testnet  |     /go/delivery/zeta-node/x/crosschain/module.go:163 +0xa2
zeta-testnet  | github.com/cosmos/cosmos-sdk/types/module.(*Manager).InitGenesis(_, {{0x3b625b8, 0xc00012a000}, {0x3b77ef0, 0xc0017325c0}, {{0x0, 0x0}, {0xc001de4420, 0xd}, 0x0, ...}, ...}, ...)
zeta-testnet  |     /go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.46.8/types/module/module.go:322 +0x423
zeta-testnet  | github.com/zeta-chain/zetacore/app.(*App).InitChainer(_, {{0x3b625b8, 0xc00012a000}, {0x3b77ef0, 0xc0017325c0}, {{0x0, 0x0}, {0xc001de4420, 0xd}, 0x0, ...}, ...}, ...)
zeta-testnet  |     /go/delivery/zeta-node/app/app.go:625 +0x12e
zeta-testnet  | github.com/cosmos/cosmos-sdk/baseapp.(*BaseApp).InitChain(0xc00018e540, {{0x1d6dd810, 0xedc005e93, 0x0}, {0xc001de4420, 0xd}, 0xc000146540, {0x538fd58, 0x0, 0x0}, ...})
zeta-testnet  |     /go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.46.8/baseapp/abci.go:71 +0x3f5
zeta-testnet  | github.com/tendermint/tendermint/abci/client.(*localClient).InitChainSync(0xc001575b00, {{0x1d6dd810, 0xedc005e93, 0x0}, {0xc001de4420, 0xd}, 0xc000146540, {0x538fd58, 0x0, 0x0}, ...})
zeta-testnet  |     /go/pkg/mod/github.com/tendermint/tendermint@v0.34.24/abci/client/local_client.go:272 +0x118
zeta-testnet  | github.com/tendermint/tendermint/proxy.(*appConnConsensus).InitChainSync(0xc001f9c8c0?, {{0x1d6dd810, 0xedc005e93, 0x0}, {0xc001de4420, 0xd}, 0xc000146540, {0x538fd58, 0x0, 0x0}, ...})
zeta-testnet  |     /go/pkg/mod/github.com/tendermint/tendermint@v0.34.24/proxy/app_conn.go:77 +0x55
zeta-testnet  | github.com/tendermint/tendermint/consensus.(*Handshaker).ReplayBlocks(_, {{{0xb, 0x0}, {0x2c286aa, 0x7}}, {0xc001de4420, 0xd}, 0x1, 0x0, {{0x0, ...}, ...}, ...}, ...)
zeta-testnet  |     /go/pkg/mod/github.com/tendermint/tendermint@v0.34.24/consensus/replay.go:319 +0xd78
zeta-testnet  | github.com/tendermint/tendermint/consensus.(*Handshaker).Handshake(0xc0017db288, {0x3b7b780, 0xc0010508f0})
zeta-testnet  |     /go/pkg/mod/github.com/tendermint/tendermint@v0.34.24/consensus/replay.go:268 +0x3d4
zeta-testnet  | github.com/tendermint/tendermint/node.doHandshake({_, _}, {{{0xb, 0x0}, {0x2c286aa, 0x7}}, {0xc001de4420, 0xd}, 0x1, 0x0, ...}, ...)
zeta-testnet  |     /go/pkg/mod/github.com/tendermint/tendermint@v0.34.24/node/node.go:329 +0x1b8
zeta-testnet  | github.com/tendermint/tendermint/node.NewNode(0xc00150c640, {0x3b5ba30, 0xc0001d1180}, 0xc001ebab50, {0x3b3b900, 0xc00105ddd0}, 0x1?, 0x538fd58?, 0xc001ebacf0, {0x3b64068, ...}, ...)
zeta-testnet  |     /go/pkg/mod/github.com/tendermint/tendermint@v0.34.24/node/node.go:777 +0x597
zeta-testnet  | github.com/zeta-chain/zetacore/server.startInProcess(_, {{0x0, 0x0, 0x0}, {0x3b8df18, 0xc001c48270}, 0x0, {0x0, 0x0}, {0x3b803b8, ...}, ...}, ...)
zeta-testnet  |     /go/delivery/zeta-node/server/start.go:374 +0xf47
zeta-testnet  | github.com/zeta-chain/zetacore/server.StartCmd.func2(0xc001440600?, {0xc001c0c540?, 0x0?, 0x4?})
zeta-testnet  |     /go/delivery/zeta-node/server/start.go:158 +0x225
zeta-testnet  | github.com/spf13/cobra.(*Command).execute(0xc001440600, {0xc001c0c500, 0x4, 0x4})
zeta-testnet  |     /go/pkg/mod/github.com/spf13/cobra@v1.6.1/command.go:916 +0x862
zeta-testnet  | github.com/spf13/cobra.(*Command).ExecuteC(0xc0013b9500)
zeta-testnet  |     /go/pkg/mod/github.com/spf13/cobra@v1.6.1/command.go:1044 +0x3bd
zeta-testnet  | github.com/spf13/cobra.(*Command).Execute(...)
zeta-testnet  |     /go/pkg/mod/github.com/spf13/cobra@v1.6.1/command.go:968
zeta-testnet  | github.com/spf13/cobra.(*Command).ExecuteContext(...)
zeta-testnet  |     /go/pkg/mod/github.com/spf13/cobra@v1.6.1/command.go:961
zeta-testnet  | github.com/cosmos/cosmos-sdk/server/cmd.Execute(0x254e0b0?, {0x0, 0x0}, {0xc00012a400, 0x10})
zeta-testnet  |     /go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.46.8/server/cmd/execute.go:36 +0x20f
zeta-testnet  | main.main()
zeta-testnet  |     /go/delivery/zeta-node/cmd/zetacored/main.go:17 +0x35
CharlieMc0 commented 1 year ago

You can’t sync from block 0 with the latest binary. You'll need to restore from state sync or a snapshot. State sync instructions are included at the bottom of the node setup documentation.

If you want an archive node with historical data you have to start with version v1.0.7 and upgrade as each upgrade height is hit. The easiest way to do that is to use zetavisor. https://www.zetachain.com/docs/validators/setting-up-zetavisor/

What is your goal? A standard RPC node or archive node?

barryz commented 1 year ago

Thanks for your reply. We need a full archive node.

And we got a startup error when starting Zetavisor service by following the instruction you mentioned.

Below are the error message and corresponded configuration.

image

Zetavisor systemd config file:

[Unit]
Description=Zetavisor ZetaChain Service
After=multi-user.target
StartLimitIntervalSec=0
[Install]
WantedBy=multi-user.target
[Service]
WorkingDirectory=/data/zeta/.zetacored/zetavisor
Environment="DAEMON_HOME=/data/zeta/.zetacored"
Environment="DAEMON_NAME=zetacored"
Environment="DAEMON_ALLOW_DOWNLOAD_BINARIES=true"
Environment="DAEMON_RESTART_AFTER_UPGRADE=true"
Environment="DAEMON_DATA_BACKUP_DIR=/data/zeta/.zetacored"
Environment="CLIENT_DAEMON_NAME=zetaclientd"
Environment="CLIENT_SKIP_UPGRADE=false"
Environment="CLIENT_START_PROCESS=false"
Environment="UNSAFE_SKIP_BACKUP=true"
Type=simple
Restart=always
RestartSec=600
User=root
LimitNOFILE=262144
ExecStart=zetavisor start --home /data/zeta/.zetacored/ --log_format json  --moniker zeta-athens3-tester

Can you help us to locate this problme?