3

I forked the BlackCoin source, changed the ports, generated the genesis block, merkle, blah blah blah. I set up a node on a DigitalOcean server and compiled my coin daemon there as well as on my local machine. They two coin daemons recognize each other, I put the addnode into the conf file, also put in rpcuser, rpcpassword, and rpcport into each conf file.

My coin-qt program on my local machine recognizes that it has 1 connection to the network, but for some reason will not stop syncing, even though only the genesis block has been created. It still says out of sync. My server daemon is still syncing too.

When I call getwork, they both return values. Here is what is returned:

{
"midstate" : "79f67436791f93f3eadc9926a8578baddfe15eebe894a6a59ba11fdfb889cef3",
"data" : "00000006edc7bd4e9e7c221bfcc052f25c28c6483d77e1c04ddce735d5a04ba000000ff977168febeac231c7109f85dc43cd9461b7763f9057bb3983622ff0986885b7d9539a6a001e0fffff00000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000080020000",
"hash1" : "00000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000010000",
"target" : "000000000000000000000000000000000000000000000000000000ffff0f0000"
}

If I try to call minerd and point them either to the local wallet or the node, like so:

./minerd --url=http://127.0.0.1:14632 -u user -p password

or

./minerd --url={My Node IP}:14632 -u username -p mypassword

it gives me an error!

Specifically:

for the local client:

Unrecognized block version: 6
json_rpc_call failed, retry after 30 seconds

and the node:

HTTP request failed; connect() timed out!
json_rpc_call failed, retry after 30 seconds

Any ideas? I am very close and would like to figure this out!

EDIT-- I went into main.h and changed the value of static const int CURRENT_VERSION from 6 to 1. This seems to have fixed the json problem. As far as the server, I simply had forgotten to open the rpc port and not just the port.

However, my client *coin-qt program continually says 'out of sync' and just says 'catching up. downloaded 0 blocks of transaction history. last block was 2 days ago.' That is the genesis block.

Since BlackCoin uses standard scrypt algorithm, I think minerd should be able to mine this coin. It seems to work alright but I get all 'boos' when mining.

This is the output on my laptop:

@crypto:~$ minerd -a scrypt --url=http://{{node ip}}:14632 -u user -p {{somepass}} --coinbase-addr={{address}} [2014-06-13 12:43:11] 
[2014-06-13 12:43:11] Binding thread 0 to cpu 0
[2014-06-13 12:43:11] 2 miner threads started, using 'scrypt' algorithm.
[2014-06-13 12:43:11] Binding thread 1 to cpu 1
[2014-06-13 12:43:12] thread 0: 4104 hashes, 4.76 khash/s
[2014-06-13 12:43:12] thread 1: 4104 hashes, 4.52 khash/s
...
[2014-06-13 12:45:58] thread 1: 756 hashes, 4.60 khash/s
[2014-06-13 12:45:58] accepted: 0/1 (0.00%), 9.33 khash/s (booooo)
[2014-06-13 12:46:02] thread 1: 18408 hashes, 4.71 khash/s

I don't understand why it isn't accepting anything. This coin uses scrypt, the same as BlackCoin. Any ideas?

  • github.com/anengineerinchina/TestCoin I went into main.h and changed the block version in class CBlock from 6 to 1. Minerd seems to be working now, but the wallet will not stop syncing for some reason. – Matthew Darnell Jun 13 '14 at 14:42
  • added an update – Matthew Darnell Jun 13 '14 at 17:37
  • Ok, something is very strange. On my local coin-qt, minerd is now working. I used this query: ./minerd --url=127.0.0.1:{{rpcport}} --userpass=user::{{pass}} -P -D --coinbase-addr={{mylocaladdress}} Everything is working and it is finding blocks. My node is picking up on these changes as well and it is syncing. However, I was getting all 'boos' in minerd, recompiled and it worked for some reason? So strange. I am going to recompile my node code now to see if it will work, since I am still getting rejects from it. – Matthew Darnell Jun 13 '14 at 18:25
1

Although this is rather old, I thought I should at least provide my knowledge on this - although it shows "0" blocks of transaction history, and continually states that it is catching up, it is however up to date - depending on the circumstances. First, you need to open "checkpoints.cpp" and remove all the checkpoints in the file (they'll be somewhere in the first 20 lines, it's fairly self explanatory), and create one checkpoint at 0 with the genesis block hash - the genesis block checkpoint. After you've done that, rebuild both clients, connect them, and instead of using minerd (or equivalent), instead use "setgenerate" through the console for at least 1 block. After that 1 block, you should be able to use minerd (or equivalent). Hope this helps for you

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.