For development reasons I'd like to have a private "real" bitcoin mainnet network. Bitcoin-core doesn't support mining any more.

I have set up a network of 2 nodes (using connect conf command). CPUminer is designed (as far as I know) to connect to a mining pool server.

Any idea how to directly do cpu solo mining with bitcoin?


  • It's not a duplicate of that thread. They are only loosely related.
    – educob
    Oct 22, 2018 at 10:58
  • 1
    Perhaps update the title of the question to reflect this is about a private test network. It does look very much like a duplicate right now. Oct 22, 2018 at 12:51

3 Answers 3


For development it's often helpful to start both nodes in regression test mode (regtest mode). The developer has his own private blockchain and can choose when to create a new block. You can use bitcoin-cli -regtest generate 1 to generate a new block.

For more information see Developer Examples - Regtest Mode.

  • I know all that but I don't like having different addresses. I want a 100% bitcoin network that produces a block every 10 minutes, etc. The real thing but private. I am developing a rather complex app and I need to test it as real as possible.
    – educob
    Oct 22, 2018 at 17:53

cpuminer does work for solo mining. I've used it successfully on the BCH testnet.

I don't have the exact command line handy right now, but if you can't figure it out, I can try to dig it up.

  • I thought I could do solo mining and tried and tried ( ./minerd --threads=1 --coinbase-addr=3GGvSvodq8Gp5pjWZxhihBxo4gEtSjKtKo -o -O xxx:yyy --no-longpoll --no-getwork --no-stratum ) until I realized I had to set a mining pool server which I don't know how to do. So I wonder if there is a software to do solo mining.
    – educob
    Oct 22, 2018 at 17:55
  • No, you don't have to set up a mining pool server. cpuminer can connect directly to your bitcoind. When I have some time, I can try to look up the syntax. Oct 22, 2018 at 19:53

I finally learn that mainnet has (among many other things) checkpoints (certain blocks with their hash hard coded and check they agree with the blockchain). So starting a private mainnet it's simply not possible (wihtout touching the code).

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.