Pages:
Author

Topic: SoloMining with CGMiner against Bitcoind / Bitcoin Core v0.18.1 - page 5. (Read 2560 times)

legendary
Activity: 4256
Merit: 8551
'The right to privacy matters'
The odds of finding a block with 22 th are about 1 in 144 years.

Assuming we stay flat.

It would be funny if the op beats those odds and gets orphaned , but the likely hood of hitting the block and getting orphaned

would be once every 1440 to 7220 years.

Assuming 10 to one up to 50 to one for the Orphan. x the 1 time in 144 years for the block.
full member
Activity: 626
Merit: 159
Your setup looks quite good.  Cool But note that cgminer does not support BECH (bc1...) addresses for solo mining, so stick to legacy addresses p2pkh (1...) here.

In general, I would suggest to first mine some low diff bitcoin-forked altcoin (for example Bitflate or Widecoin) for testing purposes. So that you can verify your setup and make sure that you actually find blocks.

To avoid having the rpc password stored in plaintext in the bitcoin.conf config file, you can use rpcauth.py to generate a salted password hash, see https://github.com/bitcoin/bitcoin/blob/master/share/rpcauth/rpcauth.py

Noted and changed the BTC address. Thank you for this!

I'm not overly concerend with the RPC call showing the password in plain text as the LAN is isolated from the WAN and world so the plain text password doesn't concern me too much but I will look into modifying this in the future.


I guess the true test will be if you find a block, hopefully no-one else finds it at the same time and you can propogate the results out the rest of the network fast enough so that it recognizes your result before anyone elses.

Dedicated Fiber internet so I think I would be good on the network side.

I am most concerned if I have my setup correct! Smiley
legendary
Activity: 3234
Merit: 1220
I guess the true test will be if you find a block, hopefully no-one else finds it at the same time and you can propogate the results out the rest of the network fast enough so that it recognizes your result before anyone elses.
member
Activity: 100
Merit: 29
Your setup looks quite good.  Cool But note that cgminer does not support BECH (bc1...) addresses for solo mining, so stick to legacy addresses p2pkh (1...) here.

In general, I would suggest to first mine some low diff bitcoin-forked altcoin (for example Bitflate or Widecoin) for testing purposes. So that you can verify your setup and make sure that you actually find blocks.

To avoid having the rpc password stored in plaintext in the bitcoin.conf config file, you can use rpcauth.py to generate a salted password hash, see https://github.com/bitcoin/bitcoin/blob/master/share/rpcauth/rpcauth.py
full member
Activity: 626
Merit: 159
Okay so my efforts came up empty with the solomining using CGMiner 4.1.12 on the latest Bitcoin Core v22.  So since this info seems to be difficult to come by I figured i would continue my journey and attempt to document it and ask questions along the way:-)

So.... I decided to try my luck with getting BitcoinCore v0.18.1 running which I seem to have accomplished a good portion but still could use guidance....

Here were my steps:
1. I downloaded v0.18.1 https://bitcoincore.org/bin/bitcoin-core-0.18.1/ and synced the full node. It took just over 26 hours to fully sync.

2. After what feels like waiting for an eternity I have my full node running on an internal static IP of 192.168.50.151 and my Miner is running on a static IP of 192.168.50.217

3. To get the miner on my LAN to connect to the full node here is what I added to my Bitcoin.conf file
(Obviously your network settings and username / passwords will most likely be different):

Code:
server=1
listen=1
daemon=1
rpcuser=USER
rpcpassword=PASS
rpcallowip=192.168.50.217
rpcallowip=192.168.50.0/255.255.255.0
rpcallowip=127.0.0.1
rpcbind=192.168.50.151
rpcport=3333

Some notes:
*Without the rpcbind= in the Bitcoin.conf file I was only able to mine locally on the full node. I was not able to mine from any remote hosts on my LAN. So if you are only interested in mining directly on the full node you can do so by creating the CGMiner startup batch with the following:

Code:
cgminer -o http://localhost:3333 -u USER -p PASS --btc-address YOURBITCOINADDRESS

Now by adding the rpcbind=192.168.50.151 it broke the ability to mine locally to localhost however I found out I was then able to still mine locally on the full node as well as mine to the full node on remote machines by using the full nodes IP address of 192.168.50.151 in the startup batch like this:
  
Code:
cgminer -o http://192.168.50.151:3333 -u USER -p PASS --btc-address YOURBITCOINADDRESS

The rpcallowip= sections essentially whitelists the IP addresses you are allowing to connect to your full node for the purposes of mining. I would suggest keeping these IP addresses limited to your LAN.

Now with these settings I do believe I have CGMiner connecting correctly to BitcoinCore as I am seeing activity on the miner side however I am not seeing Accepted shares or Rejected shares. I understand this is due to not having a result sent back from an actual mining pool.

I can now see that I am submitting shares (I belive this is correct) since I can now see the best share number as seen here:



Now in most of the solomining threads or videos I came across I see people use the generate=true command in the CLI to enable mining however this doesn't seem to work for me as I get a json error. The results of running this command are:

Code:
The wallet generate rpc method is deprecated and will be fully removed in v0.19. To use generate in v0.18, restart bitcoind with -deprecatedrpc=generate.
Clients should transition to using the node rpc method generatetoaddress
 (code -32)


Here is what my getmininginfo results looks like:


Would love to know if anyone has recommendations on if I am on the right path!!!!


Pages:
Jump to: