3

I am running bitcoind, and I have cgminer solo-mining on it. I am mining on Testnet3. My hash rate (this is an OLD computer) is ~800Khash/s, so according to one online calculator I should be generating a block every 1.5hrs at difficulty 1. The difficulty has been one for quite some time now, and I still haven't gotten any blocks, though I have been mining for much more than 1.5hrs. More like 7 or 8 total I think.

What is wrong?

  • I don't think the difficulty is really 1; see my question here. – Nate Eldredge Dec 11 '13 at 23:34
  • As far as I know, ./bitcoind getdifficulty is the actual difficulty. Also, ./bitcoind getmininginforeports the same difficulty. – BenjiWiebe Dec 11 '13 at 23:44
  • I don't think that's true. If you browse on blockexplorer.com/testnet, you'll see that all the difficulty 1 blocks are just over 20 minutes apart. If the real difficulty were 1, we should see blocks being mined much more often. The most recent block submitted less than 20 minutes after its predecessor is 153337 which has a difficulty of 11512. So I think the "real" difficulty on testnet is 11512, unless it has adjusted very recently. – Nate Eldredge Dec 11 '13 at 23:49
  • Oh...are you saying that within seconds of the diff being set to 1, a block is found? And I should have to mine for 1.5 hours avg AFTER the diff reset to get a block. Correct? – BenjiWiebe Dec 11 '13 at 23:57
  • Exactly. I've elaborated in an answer. – Nate Eldredge Dec 12 '13 at 0:00
3

The difficulty is not really 1.

testnet has a "20-minute rule": if no block is successfully mined within 20 minutes, the difficulty drops to 1 until a block is mined. Then it reverts to its previous value. However, it appears that getdifficulty returns 1 whenever the most recent block was difficulty 1, even if it was accepted under the 20-minute rule; this doesn't necessarily match the "real" difficulty.

I've asked a new question about how to find the real difficulty. But by browsing blocks on http://blockexplorer.com/testnet, the most recent block which was less than 20 minutes newer than its predecessor is 153337, which has a difficulty of 11512. So most likely the real difficulty right now is 11512, unless it has adjusted very recently.

Thus there are two possible ways for you to mine a block:

  • Find a block at difficulty 11512. If your computation was right, this will happen on average once every 2 years with your current machine.

  • Wait until it has been 20 minutes since the last block, and find a block at difficulty 1 before anyone else does. Looking at recent timestamps, it appears that difficulty 1 blocks are typically submitted about 20 minutes and 4 seconds after the previous block. Thus, you have about a 4 second window to find a difficulty 1 block (probably even less due to propagation delays). Based on your computation, your probability of successfully doing this on any given block is at most about 0.0007, suggesting that you would succeed roughly once every 3 weeks on average (this is probably very optimistic as noted). Even if you do mine a block within this time, another miner may find a block at roughly the same time; if the next miner to find a block decides to accept his instead of yours, yours will be orphaned and excluded from the chain.

So it is not surprising that you have not successfully generated a block.

  • I think I'll switch to WorldCoins... They shouldn't be easier to mine than "value-less" testnet bitcoins, but I think they are... – BenjiWiebe Dec 12 '13 at 5:36
1

First of all, this might not be impossible. The time to mine a block can vary greatly depending on your luck.

But 7-8 hrs is quite a long time. You should make sure your cgminer is correctly connected to your bitcoind instance. Also, I think bitcoind should be fully synchronized and being up-to-date for mainnet does not mean testnet is up-to-date as well.

  • 1
    If the expected time to mine a block was 1.5 hours, the probability of not mining one in 8 hours would be e^(-8/1.5) = 0.0048. That would be pretty unlucky. – Nate Eldredge Dec 11 '13 at 23:37
  • That's what I'm wondering (if cgminer is set up correctly). I am using version 2.7 or something, because later versions don't support CPU mining. Should I use a different miner? – BenjiWiebe Dec 11 '13 at 23:44
  • Also, bitcoind is running ONLY in testnet. It IS up-to-date. – BenjiWiebe Dec 11 '13 at 23:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.