Closed summerxue1992 closed 4 years ago
Use SetGenerate ?
If by automatic mining you mean smth like setgenerate
rpc then it's not possible anymore, it was deprecated few versions ago because CPU mining no longer makes sense even on testnet (diff is too high). You can use generate
rpc to produce blocks on regtest/devnet.
Well, I'm learning the dash source code now.I want to build a private chain to test the synchronization and transaction between p2p nodes.During the process, a script started by a node loops through the call to the generate RPC interface to dig the block,If I launch mainnet,it didn't work.A regtest works.
Another problem is that the addnode RPC interface doesn't seem to work either.The nodes after addnode in BTC can be synchronized normally, while the dashd cannot be synchronized now.Why?
@summerxue1992 It sounds like you may want to set up a devnet. You can find some info here - https://blog.dash.org/dash-devnets-bc27ecbf0085.
Also, I would recommend going to either Discord or https://www.dash.org/forum/ for questions like this. In this repository, Github issues are intended to just be used for bug reporting/tracking and not general support.
If I launch mainnet,it didn't work.A regtest works.
That's because diff is way to high on mainnet - you won't find any blocks with cpu mining there. (well, you can, theoretically, but chances are ~0)
The nodes after addnode in BTC can be synchronized normally, while the dashd cannot be synchronized now.Why?
They should synchronize blocks but there is another additional step to synchronize sporks and governance data. You can force these steps to complete by using mnsync next
rpc a couple of times (you can check current sync status via mnsync status
).
@thephez ok,i see。Thanks for your help。I will go to https://www.dash.org/forum/ and all people to communicate。 @UdjinM6 I still has something don't understand.Do you have any sources on sporks and governance?
@thephez
There is a falut. I can't fill in "Verification:".
@summerxue1992 Not sure what the issue is on the forum - maybe an adblocker or something?
Re: sporks/governance - https://docs.dash.org/en/stable/ and https://dash-docs.github.io/ have a lot of good info. You may find answers there (e.g. https://dash-docs.github.io/en/developer-reference#spork and https://docs.dash.org/en/stable/introduction/features.html#sporks)
Closing as it seems like all the answers have been answered and there's been no activity in ~1 year
I have spent the corresponding source, did not find how to open automatic mining。