bnb-chain / node-binary

Binaries for full nodes, light-weighted clients
178 stars 117 forks source link

Failed to sync full node #105

Closed ddggstudy closed 5 years ago

ddggstudy commented 5 years ago

同步了几天报错了:

24373859 24606286 24838944 25072940 panic: Failed to process committed block (25120001:3741D350B55D07017F39209DD36231372DEB5FB49082A699B0F268BEB02FA7DC): Wrong Block.Header.AppHash. Expected 9B3777FD460822F10E9BF06888DC02B6D2535D7D72965C9B0E9AF11AB2BC0901, got 974B56A413D30A923B80C8AEA337B028086A8EFE149934C3ACD176C81FE333D2

goroutine 1413 [running]: github.com/binance-chain/node/vendor/github.com/tendermint/tendermint/blockchain.(BlockchainReactor).poolRoutine(0xc000d921a0) /Users/huangsuyu/go/src/github.com/binance-chain/node/vendor/github.com/tendermint/tendermint/blockchain/reactor.go:372 +0x1874 created by github.com/binance-chain/node/vendor/github.com/tendermint/tendermint/blockchain.(BlockchainReactor).OnStart /Users/huangsuyu/go/src/github.com/binance-chain/node/vendor/github.com/tendermint/tendermint/blockchain/reactor.go:117 +0x84

环境: 版本号: root@bnb-node:/data/bnb_node# ./bnbchaind version Binance Chain Release: 0.6.0;Binance Chain Commit: ba88c58; Cosmos Release: =v0.25.0-binance.18; Tendermint Release: =v0.31.5-binance.0; 操作系统: root@bnb-node:/data/bnb_node# uname -a Linux bnb-node 4.4.0-151-generic #178-Ubuntu SMP Tue Jun 11 08:30:22 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

作为钱包接入点来使用的,麻烦帮忙看一下。

ddggstudy commented 5 years ago

补充一下系统参数: root@bnb-node:/data/bnb_node# ulimit -a core file size (blocks, -c) 0 data seg size (kbytes, -d) unlimited scheduling priority (-e) 0 file size (blocks, -f) unlimited pending signals (-i) 31779 max locked memory (kbytes, -l) 64 max memory size (kbytes, -m) unlimited open files (-n) 65535 pipe size (512 bytes, -p) 8 POSIX message queues (bytes, -q) 819200 real-time priority (-r) 0 stack size (kbytes, -s) 8192 cpu time (seconds, -t) unlimited max user processes (-u) 31779 virtual memory (kbytes, -v) unlimited file locks (-x) unlimited

abelliumnt commented 5 years ago

Can you share your app.toml? This is the suggested one: https://github.com/binance-chain/node-binary/blob/master/fullnode/prod/0.6.1/config/app.toml. Besides, please upgrade to 0.6.1

ddggstudy commented 5 years ago

ok, i upgrade 0.6.1 now. and this is app.toml:

[base]
# Interval blocks of breathe block, if breatheBlockInterval is 0, breathe block will be created every day.
breatheBlockInterval = 0
# Size of account cache
accountCacheSize = 30000
# Size of signature cache
signatureCacheSize = 30000
# Running mode when start up, 0: Normal, 1: TransferOnly, 2: RecoverOnly
startMode = 0
# Concurrency of OrderKeeper, should be power of 2
orderKeeperConcurrency = 2
# Days count back for breathe block
breatheBlockDaysCountBack = 7

[upgrade]
# Block height of BEP6 upgrade
BEP6Height = 20300000
# Block height of BEP9 upgrade
BEP9Height = 20300000
# Block height of BEP10 upgrade
BEP10Height = 20300000
# Block height of BEP19 upgrade
BEP19Height = 20300000

[addr]
# Bech32PrefixAccAddr defines the Bech32 prefix of an account's address
bech32PrefixAccAddr = "bnb"
# Bech32PrefixAccPub defines the Bech32 prefix of an account's public key
bech32PrefixAccPub = "bnbp"
# Bech32PrefixValAddr defines the Bech32 prefix of a validator's operator address
bech32PrefixValAddr = "bva"
# Bech32PrefixValPub defines the Bech32 prefix of a validator's operator public key
bech32PrefixValPub = "bvap"
# Bech32PrefixConsAddr defines the Bech32 prefix of a consensus node address
bech32PrefixConsAddr = "bca"
# Bech32PrefixConsPub defines the Bech32 prefix of a consensus node public key
bech32PrefixConsPub = "bcap"

##### publication related configurations #####
[publication]
# configurations ends with Kafka can be a semi-colon separated host-port list
# Whether we want publish market data (this includes trades and order)
publishOrderUpdates = true
orderUpdatesTopic = "orders"
orderUpdatesKafka = "127.0.0.1:9092"

# Whether we want publish account balance to notify browser db indexer persist latest account balance change
publishAccountBalance = true
accountBalanceTopic = "accounts"
accountBalanceKafka = "127.0.0.1:9092"

# Whether we want publish order book changes
publishOrderBook = true
orderBookTopic = "orders"
orderBookKafka = "127.0.0.1:9092"

# Whether we want publish block fee changes
publishBlockFee = true
blockFeeTopic = "accounts"
blockFeeKafka = "127.0.0.1:9092"

# Whether we want publish transfers
publishTransfer = true
transferTopic = "transfers"
transferKafka = "127.0.0.1:9092"

# Global setting
publicationChannelSize = "10000"
publishKafka = false
publishLocal = true
# max size in megabytes of marketdata json file before rotate
localMaxSize = 1024
# max days of marketdata json files to keep before deleted
localMaxAge = 7

[log]

# Write logs to console instead of file
logToConsole = false

## The below parameters take effect only when logToConsole is false
# Log file root, if not set, use home path
logFileRoot = ""
# Log file path relative to log file root path
logFilePath = "bnc.log"
# Number of logs keep in memory before writing to file
logBuffSize = 10000
ddggstudy commented 5 years ago

0.6.1 have no binarys, could you supply one. our os version is :ubuntu 16.04 LTS

ddggstudy commented 5 years ago

Block height of BEP12 upgrade

BEP12Height = 25120000

if this config must use version 0.6.1 ?

our latest block number is extranctly height=25120000

abelliumnt commented 5 years ago

BEP12Height = 25120000

if this config must use version 0.6.1 ?

Yes. You must add this config and update bnbchaind to 0.6.1. You need to learn how to use Git LFS to download large file from github. Download link is https://github.com/binance-chain/node-binary/blob/master/fullnode/prod/0.6.1/linux/bnbchaind

ddggstudy commented 5 years ago

after upgrade to 0.6.1, and add config: BEP12Height = 25120000:

root@bnb-node:/data/bnb_node# ./bnbchaind start --home=./bnb_data ERROR: Error during handshake: Error on replay: Wrong Block.Header.AppHash. Expected 9B3777FD460822F10E9BF06888DC02B6D2535D7D72965C9B0E9AF11AB2BC0901, got 974B56A413D30A923B80C8AEA337B028086A8EFE149934C3ACD176C81FE333D2 root@bnb-node:/data/bnb_node# root@bnb-node:/data/bnb_node# root@bnb-node:/data/bnb_node# root@bnb-node:/data/bnb_node# root@bnb-node:/data/bnb_node# ./bnbchaind version Binance Chain Release: 0.6.1;Binance Chain Commit: 5ce5c59; Cosmos Release: =v0.25.0-binance.19; Tendermint Release: =v0.31.5-binance.1;

if i should replay? if so if there some method to sync quickly?

abelliumnt commented 5 years ago

Please refer to this: https://github.com/binance-chain/node-binary/blob/v0.6.1/tools/recover/README.md

ddggstudy commented 5 years ago

thank you for your quickly and professional help. after state recover, the node is started but not syncing, how long it will take to enter syncing state? and if it is in replaying from block 0 to 25120000?

abelliumnt commented 5 years ago

[log]

Write logs to console instead of file

logToConsole = false

According to your log config, your log is redirected to the log file bnc.log. Please check it under your home path.

ddggstudy commented 5 years ago

thank you, it is in syncing state. my Wechat id is bmw746 . ^ ^