After an answer I made on the FB groupe to someone who asked if the nodes calculating PoW (in Bitcoin and then DUniter) are consuming energy for nothing in case of some other find a block before it.
The answer is abviously yes for Bitcoin, but also for DUniter.
I then thought about an enhancement to make in DUniter nodes, and wanted your feeling about it before writing an issue ingitlab… (I also want to say that I’m enable to develop it )
The enhancement is to calculate an average MAX difficulty for the node be able to find a block, and then just disable the calculation of PoW until the custom difficulty decrease under this limit.
The determination of this limit is quite complicated though because if the node’s calculation is off sometime then it can’t know if this limit had moved… But we can imagine a 1st study phase with statistics creation on block issuance versus difficulty, and a 2nd phase of activation of this limit. And even an alternance of study/activation to get the better compromise.
You may also say that even if the difficulty is high because of a recent bloc issuance, the node have a tiny chance to calculate a block still.
I’ll answer to that: in an idea of collaboration and because money issuance is not related to bloc calculation the node owner may renounce on participation for few blocks until the probability of finding one is greater than energy waste…
I don’t think it is the case !
Like for now, if run duniter on a raspberry pi you will have very little chance to find a block but the raspberry will still try to find one.
I think what means @devingfx is that if the difficulty is too high compare to his computational power, the node him self do not compute PoW. For now if the difficulty is too high the node stop the computation of the PoW but it is not related to the node computation power it self.
I think it is doable and it could be instersting to do it.
I just push a merge request yesterday to reduce energy waste by reducing the computation power of the most powerful nodes. So the common difficulty will decrease and smaller nodes will be able to compute the PoW.
I think it will have more impact on the energy waste. Any review is welcome
It is never too high, because PoW has randomness in it. You may very weel find a level 128 proof (8 zeros) with a Raspberry on the very first try. For example we have several proofs of level 112 (7 zeros) whereas the average level is 84 (a bit more than 5 zeros), which is a really big difference!
However, each node knows when it has a handicap. In these moments, depending on the handicap, the node will just stop computing a PoW and wait for better conditions. This handicap is something appart from the exclusion mechanism, where of course the node just stops computing as well when it is in this zone.
The really big deal is to have each member to have at least 1 block in the current window. This block in the window is what horizontalizes the difficulty, and punish the biggest computation machines. Having at least 1 block in the window should be our goal.
Yes we agree on that !
But we could say that when the probability to find a block is very very low (with a given power computation and difficulty) then there is no use to try to find a block.
Like for now there is raspberry that are not finding any block since months. I think they should not try to find a block and wait for better conditions because it will be energy waste in 99.999% of the time for example.
Not at all. It is a simple raspberry 3 running the stock raspbian. I do add some little cooling on the processor (a little radiator and a PC fan running on 5V, just reusing what I have around), otherwise it tends to get a little hot.
I don’t see your node on the network with your member identity. Did you configure the “Settings/Crypto” tab on your node to specify your identity? How much CPU percentage is dedicated to Duniter? Is your node actually calculating anything? (on the right hand side of the main screen in the “Blocks made by this key”, does it show some hex values like #0072F2 and so on?) Is it even in sync with the network? (what is your current block #?) Is the network config correct? There are quite a few things to double check here, no doubt. In 3 days it should definitely find something.