我尝试了最新版本(v.0.19.6)和v0.18.5,但两者似乎与bitcoin.com testnet explorer上显示的观点不同,并且bitcoin-abc的最新高度总是比比特币上显示的高100个街区.com 浏览器
例如,下面是我使用来自 bitcoin-abc 的 rpc 调用获取高度为 1306255 的块:
{
"bits": "1b3037a6",
"chainwork": "00000000000000000000000000000000000000000000004c90a4d396ee6583d7",
"confirmations": 57,
"difficulty": 1359,
"hash": "00000000002b9e83a7f55211bdb847b58ad7f37fae879478f9e32f8e75e6c9b4",
"height": 1306255,
"mediantime": 1559185963,
"merkleroot": "088f104ca41a7ca4f83d6de267a85724dc0283aefc27d7ae978badcd571d40c0",
"nextblockhash": "0000000000066ba2e8a751149138dc3a1be8168ea85fab1bc398ff3fbb9307e2",
"nonce": 1464894606,
"previousblockhash": "000000000020127e583624c682c96efb50cd56fc189928de917faba96a9c3d40",
"size": 201,
"time": 1559188014,
"tx": [{
"blockhash": "00000000002b9e83a7f55211bdb847b58ad7f37fae879478f9e32f8e75e6c9b4",
"blocktime": 1559188014,
"confirmations": 57,
"hash": "088f104ca41a7ca4f83d6de267a85724dc0283aefc27d7ae978badcd571d40c0",
"hex": "01000000010000000000000000000000000000000000000000000000000000000000000000ffffffff23038fee1300fefc980800fefb2308000963676d696e6572343208040000000000000000ffffffff01c817a804000000001976a9146db2250c113ad124a60e0a522faef0b7f0c8b0ed88ac00000000",
"locktime": 0,
"size": 120,
"time": 1559188014,
"txid": "088f104ca41a7ca4f83d6de267a85724dc0283aefc27d7ae978badcd571d40c0",
"version": 1,
"vin": [{
"sequence": 4294967295
}],
"vout": [{
"addressValid": true,
"n": 0,
"scriptPubKey": {
"addresses": ["bchtest:qpkmyfgvzyadzf9xpc99ytaw7zmlpj9sa5qrn24u9t"],
"asm": "OP_DUP OP_HASH160 6db2250c113ad124a60e0a522faef0b7f0c8b0ed OP_EQUALVERIFY OP_CHECKSIG",
"hex": "76a9146db2250c113ad124a60e0a522faef0b7f0c8b0ed88ac",
"reqSigs": 1,
"type": "pubkeyhash"
},
"value": 0.78125
}]
}],
"version": 536870912,
"versionHex": "20000000"
}
而 bitcoin.com 显示以下相同高度 1306255(即使块哈希不同): https://explorer.bitcoin.com/tbch/block/00000000000000340762ba9648a982a18442ff7423e787d4115da323a399dc57b
我不确定是什么导致了问题,下面是我的conf:
server=1
daemon=1
txindex=1
logtimestamps=1
rpcuser=xxx
rpcpassword=xxxx
rpcport=18332
rpcallowip=0.0.0.0/0
datacarriersize=80
regtest=0
testnet=1
我使用以下 cmd 启动 bitcoin-abc 节点:
bin/bitcoind -conf=/data/xxx-bch-test/bitcoin.conf -datadir=/data/xxx-bch-test/testnet -testnet &
我注意到 debug.log 中有一个日志,不确定它是否相关:
2019-05-30T11:33:56Z ERROR: AcceptBlockHeader: block 000000000000003a3fb0ca1611035346a803e0344d6bb2eb4f5ea75f4dc2291c is marked invalid
2019-05-30T11:33:56Z ERROR: invalid header received
但是在 bitcoin.com explorer 中哈希看起来不错