<p><em>Bitcoin core executables (bitcoin-qt and bitcoind) cannot even attempt to mine real Bitcoin since 2016. At <a href="https://github.com/bitcoin/bitcoin/pull/7507" rel="nofollow noreferrer">https://github.com/bitcoin/bitcoin/pull/7507</a>
we can read</em></p>
<blockquote>
<p><em>This code removes the internal miner which is only useful on Testnet.
This leaves the internal miner that is useful on RegTest intact.</em></p>
</blockquote>
<p>With <code>-gen=1</code> on the command line or in the configuration file, <em>in conjunction with <code>regtest=1</code></em> <code>bitcoind</code> will use its built-in miner to search for blocks <em>in the regtest network</em>. It is inefficient, does not support pools, and does not use GPUs. It is only left as a reference and for testing, and <em>has been</em> removed <em>from mainnet</em> completely.</p>

CC BY-SA 3.0
2014-05-31T15:56:17.693Z
when i "setgenerate true" in bitcoin-qt console window, and then "gethashespersec" it reports my hashing power, and "getgenerate" returns true, isn't this a proof that it's mining ?
Farghaly
CC BY-SA 3.0
2014-06-01T07:02:07.560Z
Yes, but you'll never mine anything with it. It is far too slow.
Pieter Wuille
CC BY-SA 4.0
2011-11-13T17:25:14.957Z
2023-11-11T09:15:35.250Z
2023-11-11T09:15:35.250Z
Pieter Wuille
<p>That configuration parameter no longer has any effect because the CPU mining engine has been removed from the mainline client.</p>

<p>Earlier versions of the client did have a built in miner and the gen parameter controlled if it ran in the background.  Given the much higher difficulty today the developers felt it no longer served a purpose and would be confusing to new users (who could wait months of even years without generating a single coin).  It was removed from the client.  The wiki should be updated to reflect that.</p>

CC BY-SA 3.0
2016-03-16T12:46:33.307Z
Your answer is now correct. RIP internal miner (see https://github.com/bitcoin/bitcoin/pull/7507)
Pieter Wuille
CC BY-SA 3.0
2011-11-13T17:24:04.507Z
This is incorrect: the built in miner was removed from the GUI, but remains accessible in bitcoind.
Pieter Wuille
CC BY-SA 3.0
2011-11-10T07:23:57.553Z
2011-11-10T07:23:57.553Z
DeathAndTaxes
<p>The <code>gen</code> option isnt copiously described in <a href="https://en.bitcoin.it/wiki/Running_Bitcoin#Bitcoin.conf_Configuration_File" rel="nofollow">the sample bitcoin.conf file</a>  ... does that mean that the daemon started up will attempt to mine for coins?</p>

<bitcoin-core><miner-configuration><bitcoin.conf>
What does the `gen` option in bitcoin.conf do?
Terrence Brannon
# What does the `gen` option in bitcoin.conf do?

(Asked by: username_0 on 2011-11-10)

The `gen` option isnt copiously described in [the sample bitcoin.conf file](https://en.bitcoin.it/wiki/Running_Bitcoin#Bitcoin.conf_Configuration_File) ... does that mean that the daemon started up will attempt to mine for coins?

**Tags:** bitcoin-core, miner-configuration, bitcoin.conf


---

## 2 answers

### Answer by username_3 on 2011-11-10. Score: 7 | Accepted answer

That configuration parameter no longer has any effect because the CPU mining engine has been removed from the mainline client.

Earlier versions of the client did have a built in miner and the gen parameter controlled if it ran in the background. Given the much higher difficulty today the developers felt it no longer served a purpose and would be confusing to new users (who could wait months of even years without generating a single coin). It was removed from the client. The wiki should be updated to reflect that.

> **Comments:**
> **username_1**: This is incorrect: the built in miner was removed from the GUI, but remains accessible in bitcoind.  
> **username_1**: Your answer is now correct. RIP internal miner (see https://github.com/bitcoin/bitcoin/pull/7507)  

---

### Answer by username_1 on 2011-11-13. Score: 5

*Bitcoin core executables (bitcoin-qt and bitcoind) cannot even attempt to mine real Bitcoin since 2016. At <https://github.com/bitcoin/bitcoin/pull/7507>
we can read*

> *This code removes the internal miner which is only useful on Testnet.
> This leaves the internal miner that is useful on RegTest intact.*

With `-gen=1` on the command line or in the configuration file, *in conjunction with `regtest=1`* `bitcoind` will use its built-in miner to search for blocks *in the regtest network*. It is inefficient, does not support pools, and does not use GPUs. It is only left as a reference and for testing, and *has been* removed *from mainnet* completely.

> **Comments:**
> **username_2**: when i "setgenerate true" in bitcoin-qt console window, and then "gethashespersec" it reports my hashing power, and "getgenerate" returns true, isn't this a proof that it's mining ?  
> **username_1**: Yes, but you'll never mine anything with it. It is far too slow.  

---

