Author

Topic: Just starting out - in need of some assistance (Read 271 times)

newbie
Activity: 10
Merit: 11
November 16, 2019, 10:41:06 AM
#8
Quote
EDIT: btw, how did it go one day later ? Are you in sync ?

Need to take a step back and sort out my bitcoin.conf file first.

Thanks for all your help, I will probably post again soon.
sr. member
Activity: 279
Merit: 435
Quote
Hmm are you in sync ? You can check that you have an up-to-date block chain using the `getblockchaininfo` RPC command.
I'm not sure how you did both main and test network transactions with only one daemon though.
Did you get a transaction ID ?

Thanks for the reply. I have used getblockchaininfo, but I am not sure how to interpret the output?
The synchronisation (/bootstrap) process will fetch the headers of the blocks first. One way to see if you are not in sync is to check if the `block` entry output is less than the `header` entry output, it would mean that you know about some blocks that you have not downloaded yet.
Another interesting metric is the `verificationprogress` entry, the closer it is to 1, the more transactions you have validated in the best block chain.
Basically if `initialblockdownload` is true  .... You have to wait Wink

Does it show the hash of the first block in my copy of the blockchain, then I compare it to the hash of the first block everyone else has and if they match then I am in sync? (Sorry just guessing).
It indeed shows what is called "the best height": this is the hash of the (header of the) latest block in the longest chain you know about. This is the `bestblockhash` entry.


Also, apologies if I wasn't clear, I was using both bitcoind and bitcoind -testnet daemons one at a time whenever I was trying to use each wallet.

One thing I don't understand. I was wondering if I should be have used the createwallet command instead of the getnewaddress in order to create the wallet. I'm not sure on the difference between these two commands? The getnewaddress command presumably must require a public key in order to work, but not sure how it does that when I hadn't run createwallet. I think I might be way off base with this one.
The wallet is a key keeper. As you accurately presumed the invoice address is generated from a key, you could not have generated an invoice address without a wallet. Under the hood (you can checkout the log in /path/to/datadir/debug.log if you are interested) `bitcoind` created one from you at first startup.
The `createwallet` command can be used to create a new wallet with a completely different set of keys.

EDIT: btw, how did it go one day later ? Are you in sync ?
HCP
legendary
Activity: 2086
Merit: 4361
Thanks for the reply. I have used getblockchaininfo, but I am not sure how to interpret the output? Does it show the hash of the first block in my copy of the blockchain, then I compare it to the hash of the first block everyone else has and if they match then I am in sync? (Sorry just guessing).
Easiest way is to look at: "Blocks"

Quote
"blocks": 603968,
If the blocks number is equal to the height of the longest chain... you're synced. You can double check on any of the common block explorers... like blockcypher: https://live.blockcypher.com/btc/




#Blocks == Height... you're synced. So what is the "blocks" value from your getblockchaininfo command? Huh
legendary
Activity: 1946
Merit: 1427
One thing I don't understand. I was wondering if I should be have used the createwallet command instead of the getnewaddress in order to create the wallet. I'm not sure on the difference between these two commands? The getnewaddress command presumably must require a public key in order to work, but not sure how it does that when I hadn't run createwallet. I think I might be way off base with this one.

If you don't have a wallet, (wallet.dat), bitcoin core will automatically generate one on first start up. So, that's why you've never had to run the command.

getnewadress simply derives a new private key from the XPRV (if necessary), and then gives that to you (in the form of public key -> adress). ->
newbie
Activity: 10
Merit: 11
Quote
Hmm are you in sync ? You can check that you have an up-to-date block chain using the `getblockchaininfo` RPC command.
I'm not sure how you did both main and test network transactions with only one daemon though.
Did you get a transaction ID ?

Thanks for the reply. I have used getblockchaininfo, but I am not sure how to interpret the output? Does it show the hash of the first block in my copy of the blockchain, then I compare it to the hash of the first block everyone else has and if they match then I am in sync? (Sorry just guessing).

Also, apologies if I wasn't clear, I was using both bitcoind and bitcoind -testnet daemons one at a time whenever I was trying to use each wallet.

One thing I don't understand. I was wondering if I should be have used the createwallet command instead of the getnewaddress in order to create the wallet. I'm not sure on the difference between these two commands? The getnewaddress command presumably must require a public key in order to work, but not sure how it does that when I hadn't run createwallet. I think I might be way off base with this one.
HCP
legendary
Activity: 2086
Merit: 4361
I sent from my own wallet and transaction shows as complete
Which wallet did you send from exactly? Was it sending from a different wallet to your Bitcoin Core wallet? Or did you send from Bitcoin Core to Bitcoin Core? Huh
sr. member
Activity: 279
Merit: 435
Hi, I'm in the process of trying to improve my computer science skills (and employability). I find bitcoin really interesting and thought that this would be a good way to help keep me motivated.

It's been a tough start so far, but I've reached the point of having my bitcoin-cli and daemon up and running. I guess in the grand scheme of learning bitcoin, that means I'm almost at the level of the chimpanzee on the Darwin chart.
Welcome to a new chimpanzee on our big earth full of mysteries  Wink

I created a couple of wallets in both the MainNet and TestNet environments using the getnewaddress command, and all seems well with them when I run the validateaddress command. I sent some test coins from a few different faucets to my TestNet wallet and sent about $5 to my MainNet one.

However its been a day and I cannot see any sign of the coins in either of my wallets? When I run: getbalance, listunspent or listreceivedbyaddress there is no sign of any coins or transactions. Does TestNet have it's own blockchain?
It does have a separate block chain and hence run on a different network. You should know if you ran a testnet daemon, as you need to pass the `-testnet` startup parameter (to run both you have to start bitcoind 2 times, once with the `-testnet` option, the other without.


If it does, I have not downloaded it. So that could explain that. I really want to avoid the risk of accidently spamming the MainNet with my broken transactions, so I really hope I can find a way to get the testnet to work.
Don't be afraid of spamming, if your transaction relayed (i.e. you were paying enough fees) then you are in your own right of using the network (I think?). A broken transaction won't relay as it won't pass validation of your peers.
If you just started bitcoind it might take some time to bootstrap.

But not sure why the MainNet coins are not showing? I sent from my own wallet and transaction shows as complete, I also have my bitcoind running along with my bitcoin-qt and an up to date blockchain. Not sure what I am missing here?
Hmm are you in sync ? You can check that you have an up-to-date block chain using the `getblockchaininfo` RPC command.
I'm not sure how you did both main and test network transactions with only one daemon though.
Did you get a transaction ID ?
newbie
Activity: 10
Merit: 11
Hi, I'm in the process of trying to improve my computer science skills (and employability). I find bitcoin really interesting and thought that this would be a good way to help keep me motivated.

It's been a tough start so far, but I've reached the point of having my bitcoin-cli and daemon up and running. I guess in the grand scheme of learning bitcoin, that means I'm almost at the level of the chimpanzee on the Darwin chart.

I created a couple of wallets in both the MainNet and TestNet environments using the getnewaddress command, and all seems well with them when I run the validateaddress command. I sent some test coins from a few different faucets to my TestNet wallet and sent about $5 to my MainNet one.

However its been a day and I cannot see any sign of the coins in either of my wallets? When I run: getbalance, listunspent or listreceivedbyaddress there is no sign of any coins or transactions. Does TestNet have it's own blockchain? If it does, I have not downloaded it. So that could explain that. I really want to avoid the risk of accidently spamming the MainNet with my broken transactions, so I really hope I can find a way to get the testnet to work.

But not sure why the MainNet coins are not showing? I sent from my own wallet and transaction shows as complete, I also have my bitcoind running along with my bitcoin-qt and an up to date blockchain. Not sure what I am missing here?

I would really appreciate any comments or observations.

Thanks in advance.
Jump to: