I bought a second hand red compac F miner, and followed your instructions. I need help to get it working.
Bitcoin Core, cgminer and the compac F are installed on the same system.
Now let's prepare the configuration file. Create a text file named bitcoin_testnet.conf in ~/bitcoin_testnet/ and put these content in it:
I use this:
testnet=1
txindex=0
server=1
[test]
rpcport=5000
rpcallowip=172.0.0.1
rpcuser=USESR
rpcpassword=PASS
rpcbind=0.0.0.0
prune=550
Now, in theory we should be ready, but we need one extra change. Open the file
cgminer.c with your favorite text editor and change this line:
if (opt_btc_address[0] != '1') {
To this:
if (opt_btc_address[0] != '1' && opt_btc_address[0] != 'm' && opt_btc_address[0] != 'n' ) {
I think I can skip this because the code on github is updated already:
switch (opt_btc_address[0]) {
case '1':
case 'm':
case 'n':
break;
default:
applog(LOG_ERR, "Bitcoin address %s is NOT a P2PKH address, unable to mine solo on %s",
opt_btc_address, pool->rpc_url);
goto out;
}
.
Create a text file named ~/bitcoin_testnet/cgminer_testnet.conf with these contents:
I use this (last comma removed, thanks n0nce)
{
"pools" : [
{
"url" : "http://172.0.0.1:5000",
"user" : "USER",
"pass" : "PASS"
}
],
"btc-address": "moZKMsGTNSd3Ngu5i6RN7CC7PHaQ5wd5ms",
"gekko-compacf-freq" : "400",
"gekko-compacf-detect" : true,
"gekko-start-freq" : "300",
"gekko-mine2" : true,
"gekko-tune2" : "60",
"suggest-diff" : "442",
"failover-only" : true
}
And now you can simply run cgminer like this:
sudo /home/user/bitcoin_testnet/cgminer/cgminer -c /home/user/bitcoin_testnet/mine_testnet.conf
It doesn't work. I get:
[date] Started cgminer 4..12.1
A minute later:
Loaded configuration file ../cgminer_testnet.conf
Probing for an alive pool
No servers were found that could be used to get work from.
Please check the details from the list below of the servers you have input
Most likely you have input the wrong URL, forgotten to add a port, or have not set up workers
Pool: 0 URL: http://172.0.0.1:5000 User: USER Password: PASS
Press any key to exit, or cgminer will wait indefinitely for an alive pool.
2 minutes later:
No Stratum, GBT or Solo support in pool 0 http://172.0.0.1:500 unable to use
Why can't cgminer connect to Bitcoin Core? What do I have to change?