4 ms·
Most of the time the hash isn't successful, so you modify the block slightly and try again, over and over billions of times. Question: What exactly gets modifi
by stevewepay 11y ago
Most of the time the hash isn't successful, so you modify the block slightly and try again, over and over billions of times.
Question: What exactly gets modified over and over again? Is it the nonce that gets tweaked through every iteration? And is it correct to assume that for a fixed number of transactions that are added to a block, that there may not be a hash that works?
- kens 11y agoThe nonce is the expected thing to tweak, but given current difficulty, it's pretty likely that trying all the nonces will fail. The timestamp can also be tweaked, and the transaction list changed. But miners usually change the "coinbase" transaction (which is the transaction that grants bitcoins to the miners) by putting an extra nonce in there, since there's extra room and the transaction can be modified without messing anything up. This is important in mining pool so miners can do a lot of hashes without constantly contacting the server to request a new block. See my blog post on mining for details of how the coinbase transaction is built by concatenation: http://www.righto.com/2014/02/bitcoin-mining-hard-way-algorithms.html http://www.righto.com/2014/02/bitcoin-mining-hard-way-algori...