Closed golashr closed 5 years ago
Hi @golashr, I tried to reproduce the issue, but so far no luck. Can you provide more details on your setup;
@jbhurat Thanks for the quick revert! How many nodes/validators are part of the network Ledgerium Blockchain will be public blockchain which will support private transactions using Quorum with Istanbul BFT as base. In the current test environment, there are 4 nodes.
What is the block period We have kept it 5 seconds. Default value is 1.
Is the network running locally or on cloud In the current test environment, all nodes are local.
Are you using docker Yes. These are docker containers
Also, please share your genesis json
{
"config":{
"chainId":2018,
"byzantiumBlock":1,
"eip150Block":2,
"eip150Hash":"0x0000000000000000000000000000000000000000000000000000000000000000",
"eip155Block":0,
"eip158Block":3,
"istanbul":{
"epoch":30000,
"policy":0
},
"isQuorum":true
},
"nonce":"0x0",
"timestamp":"0x5b7fa5cb",
"extraData":"0x0000000000000000000000000000000000000000000000000000000000000000f89af854941a67eea756b9c074219dbbd1a68b7a691941264594cb680d316b281aebb68e73e813b7a53ec93c8f0594c1836760988668eea5275cd562755ec0b82cef929486dc44a5ae35a09a62585f2e3de29f14dce2ff2cb8410000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0",
"gasLimit":"0x1FFFFFFFFFFC20",
"difficulty":"0x1",
"mixHash":"0x63746963616c2062797a616e74696e65206661756c7420746f6c6572616e6365",
"coinbase":"0x0000000000000000000000000000000000000000",
"alloc":{
"1a67eea756b9c074219dbbd1a68b7a6919412645":{
"balance":"0xfffffffffffffffffffffffffffffffffffff"
},
"cb680d316b281aebb68e73e813b7a53ec93c8f05":{
"balance":"0xfffffffffffffffffffffffffffffffffffff"
},
"c1836760988668eea5275cd562755ec0b82cef92":{
"balance":"0xfffffffffffffffffffffffffffffffffffff"
},
"86dc44a5ae35a09a62585f2e3de29f14dce2ff2c":{
"balance":"0xfffffffffffffffffffffffffffffffffffff"
}
},
"number":"0x0",
"gasUsed":"0x0",
"parentHash":"0x0000000000000000000000000000000000000000000000000000000000000000"
}
Could block period be a problem?
ok, so I tried with block period as 1 (default value) too. The same problem existed.
Thanks for info @golashr. I tried the below to reproduce the issue, but still no luck
eth.getBalance(eth.coinbase)
in succession to reproduce the issue, but no luckDid you do anything different?
The only difference that we have from the code is, https://github.com/jpmorganchase/quorum/blob/master/consensus/istanbul/backend/engine.go#L383 we are adding some balance to the miner by calling
state.AddBalance(author, minerblockReward)
Mind you, this code was working well before merging the last commit so I raised the ticket.
I am able to reproduce the issue after adding the above code. From the logs and correlating it back to the code, it looks like the issue is happening because the state is not in a consistent state. Also, Quorum v2.2.3 is based on Geth 1.8.18 and there are lots of changes around how state works.
I think you would want to enable miner block rewards with the above change. If yes, can you see if this PR addresses your needs https://github.com/jpmorganchase/quorum/pull/624
state.AddBalance(author, minerblockReward)
From the above code change, I thought that you are trying to enable miner block rewards. Also, #624 is to enable gas price and as you are using non-zero gas price it might help.
Hi @golashr, I believe this was working on quorum version v2.2.1
and earlier. Quorum v2.2.1
is based on Geth 1.8.12
and Quorum v2.2.3
is based on Geth 1.8.18
. The code around how state is handled is completely rewritten between these two versions. Also, looks like the changes you are trying to make changes to the state object and hence the error you are getting.
Ideally we only support issues with Quorum and not on changes being made on top of it. Please reach out on slack and we can bounce ideas around how to proceed from here
@jbhurat I guess, we need some investigation on it still. As mentioned above, adding AddBalance() only makes the state inconsistent. Else, the state remains stable. Geth 1.8.18 still has AddBalance() code in place as expected. https://github.com/ethereum/go-ethereum/blob/master/consensus/ethash/consensus.go#L614
Let me take the discussion on slack.
Hi, We have Geth+Tessera nodes deployed on distributed machines. So we are extending the quorum code. We are facing one issue after doing upstream synch with commit details given below.
System information
System information Geth version: 1.8.18-stable Quorum version:quorum-v2.2.3 Tessera version: quorumengineering/tessera:0.9.1 OS & Version: Linux/OSX Ubuntu 18.04.2 LTS (GNU/Linux 4.15.0-47-generic x86_64) Branch - master Commit -'53105b16400284551b5eefc491b7d7092a7b43c1'
The trie states are missing intermittently but pretty consistently.
The below is the log from the geth console
Below is the log from the application where we are trying to submit public transaction while deploying contract using nodejs/web3 tech stack.
Help appreciated.