2
1
I've created a docker container of an ubuntu machine, loaded it up with all the dependencies specified in the unix build doc and then built bitcoin and run it with the following command:
./src/bitcoind
after that there's no output or evidence that anything is happening, the terminal is just hanging there, clearly something is going on- but I don't know/can't see what it is.
how can I examine the activity? For instance, see the coins that are being generated in my wallet, etc.
I've tried this proposed solution, i.e. to write
bitcoind getinfo
but I got the error
Error: There is no RPC client functionality in bitcoind anymore. Use the bitcoin-cli utility instead.
Regarding -regtest
I tried with:
./src/bitcoin-cli -regtest &
and I got the error:
too few parameters (need at least command)
I think I sort of got what I was looking for with this one
./src/bitcoin-cli getinfo, but actually I don't want to connect to the real bitcoin network, I want to start over from scratch, create my own personal testnet, do you know how to do this? – smatthewenglish – 2017-04-18T13:40:52.387so then does that mean that I can't use bitcoin core for creating a testnet, since it can't mine? – smatthewenglish – 2017-04-18T13:44:11.887
how to get around this error
error: Could not locate RPC credentials. No authentication cookie could be found, and no rpcpassword is set in the configuration file (/root/.bitcoin/bitcoin.conf)– smatthewenglish – 2017-04-18T13:47:40.303That means
bitcoindis not running (or perhaps you're running it with-testnetor-regtestbut not passing that same argument tobitcoin-cli?). – Pieter Wuille – 2017-04-18T13:48:39.167And you can always run external mining software (like bfgminer) to construct blocks; it's much faster than any code we're able to maintain in Core. If it's just for a local testnet (-regtest mode), you can use the built-in
generateRPC still (but only for chains where the difficulty is trivially low). – Pieter Wuille – 2017-04-18T13:56:14.943ah, ok. thank you for these insights. do you know what steps I would need to take to generate a fresh testnet from scratch? what I'd like to do eventually is have my own version of a real fork that I can make changes to- but I guess I might start by just creating my own version of bitcoin on a small network with some of my own machines – smatthewenglish – 2017-04-18T14:17:10.543
2I would suggest to start in
-regtestmode. You'll get an empty chain with only a genesis block, and no default connections anywhere. You can then use -connect to add nodes to your network and experiment. If you're further ahead, modify chainparams.cpp to add a definition for your own network and logic to select it. – Pieter Wuille – 2017-04-18T14:21:18.897do you know what I should do to chainparams.cpp to define my own network? – smatthewenglish – 2017-04-18T16:11:40.910
That's far too much to explain in comments of an answer here. I suggest you study the source code and experiment with regtest first. – Pieter Wuille – 2017-04-18T16:17:53.890
I've tried to start with 'regtest' and I got again that rpc error, and something about not enough arguments, do you know some resource I could look at about this? – smatthewenglish – 2017-04-19T11:37:29.747
https://bitcoin.org/en/developer-examples#regtest-mode – Pieter Wuille – 2017-04-19T11:38:53.337
I read that and tried those examples but it's what generated that not enough arguments error- also sometimes it refers to 'bitcoind' and sometimes 'cli', what about this one: https://bitcoin.stackexchange.com/questions/28107/bitcoin-is-not-connected-in-regtest-mode
– smatthewenglish – 2017-04-19T11:40:22.910Can you open a new question with the exact commands you're running and error messages you get? – Pieter Wuille – 2017-04-19T11:43:06.810
yes, sure I'll do that – smatthewenglish – 2017-04-19T11:44:02.150
https://bitcoin.stackexchange.com/questions/52857/trouble-with-bitcoin-cli-regtest – smatthewenglish – 2017-04-19T11:48:13.080