Author

Topic: Best practices installing Bitcoind on a Linux Server (Debian 11) (Read 165 times)

legendary
Activity: 2870
Merit: 7490
Crypto Swap Exchange
As described by it's name, txindex only index transaction and cannot be used to query balance of specific address.

Not exactly true. You can use the listunspent RPC for addresses in legacy wallets or the scantxoutset RPC if you're comfortable with descriptors (it does not require creating any wallet file), and then add up the resulting "address" fields in the array.

This method also lets you get the balance of some or all the addresses as well, and in the case of descriptors, even an extended public key.

You can even get the confirmed balance by ignoring every item with confirmations field set to 0.

You're not wrong, but there are few serious limitation with RPC call you mentioned,
1. listunspent only works on address on your legacy address. It's not practical when you need to regularly add new address to wallet.dat since you need to perform re-scan.
2. scantxoutset is experimental feature.
3. AFAIK scantxoutset is very slow, unless you load whole UTXO to RAM or you use very fast storage to store chainstate folder.
legendary
Activity: 2870
Merit: 7490
Crypto Swap Exchange
In fact, I don't know exactly what a full node is.
A full node starts by downloading ~500 GB. After that, it's ~2 GB per week.
And in case OP wants to use 'txindex' (I assume he would prefer to have it, as he plans "to query the balance of a specific address"*), then there are extra 50G.

* - it will be much easier installing additional software for that, like https://github.com/janoside/btc-rpc-explorer

As described by it's name, txindex only index transaction and cannot be used to query balance of specific address. While additional software such as btc-rpc-explorer let you query balance of specific address, take note it require Electrum server which perform address indexing.
legendary
Activity: 1568
Merit: 6660
bitcoincleanup.com / bitmixlist.org
As described by it's name, txindex only index transaction and cannot be used to query balance of specific address.

Not exactly true. You can use the listunspent RPC for addresses in legacy wallets or the scantxoutset RPC if you're comfortable with descriptors (it does not require creating any wallet file), and then add up the resulting "address" fields in the array.

This method also lets you get the balance of some or all the addresses as well, and in the case of descriptors, even an extended public key.

You can even get the confirmed balance by ignoring every item with confirmations field set to 0.
legendary
Activity: 952
Merit: 1385
In fact, I don't know exactly what a full node is.
A full node starts by downloading ~500 GB. After that, it's ~2 GB per week.


And in case OP wants to use 'txindex' (I assume he would prefer to have it, as he plans "to query the balance of a specific address"*), then there are extra 50G.

* - it will be much easier installing additional software for that, like https://github.com/janoside/btc-rpc-explorer

legendary
Activity: 2534
Merit: 6080
Self-proclaimed Genius
And now maybe another stupid question: The Bitcoin Daemon doesn't do any mining? I haven't found any option with which I can switch off mining. As far as I understand, the mining software runs separately and only uses the Bitcoin Daemon to communicate with the network. Is my understanding correct? In that case, there would be nothing else for me to do at this point, because I don't want to mine.
Yes, the mining commands generatetoaddress or generate do not automatically run since it's only recommended to use in RegTest.
And AFAIK, even in the old versions, the "Generate Coin" option wasn't toggled on by default.
legendary
Activity: 3290
Merit: 16489
Thick-Skinned Gang Leader and Golden Feather 2021
In fact, I don't know exactly what a full node is.
A full node starts by downloading ~500 GB. After that, it's ~2 GB per week.

Quote
I think the option "blocksonly" does what I want (only download blocks and ignore unconfirmed transaction). I would like to limit the network traffic for the time being.
Unconfirmed transactions (AKA the mempool) are small in size compared to the existing blockchain.

Quote
The Bitcoin Daemon doesn't do any mining?
Correct. Mining on a computer isn't feasible.
jr. member
Activity: 42
Merit: 48
Thank you all for the useful advice. I'm working through right now.

Maybe OP wanted to say he want to run pruned node.

In fact, I don't know exactly what a full node is. In the meantime I have done some more research and I think the option "blocksonly" does what I want (only download blocks and ignore unconfirmed transaction). I would like to limit the network traffic for the time being.

And now maybe another stupid question: The Bitcoin Daemon doesn't do any mining? I haven't found any option with which I can switch off mining. As far as I understand, the mining software runs separately and only uses the Bitcoin Daemon to communicate with the network. Is my understanding correct? In that case, there would be nothing else for me to do at this point, because I don't want to mine.
hero member
Activity: 714
Merit: 1010
Crypto Swap Exchange

Additionally to above threads you can also have a look at the setup steps of https://raspibolt.org/. You will not need everything of and you may skip certain Raspi specific things along the setup. I have done this on an Ubuntu box and it works just fine.

A pruned blockchain will have its limitations on certain RPC commands, so it really depends on which things you're going to query.
legendary
Activity: 2534
Merit: 6080
Self-proclaimed Genius
Requirements:
  • No full node
I don't know how it's possible with this requirement since bitcoind is a Bitcoin full node.

My understanding so far is that the bitcoin daemon is included in the Core Client and can be started independently of the QT client.
Yes, bitcoind will run independently, and you can communicate with it using RPC or other methods. (e.g.: bitcoin-cli)

Here's the developers guide for Bitcoin Core: https://developer.bitcoin.org/devguide/index.html
legendary
Activity: 952
Merit: 1385
jr. member
Activity: 42
Merit: 48
I apologise if this has already been answered somewhere. But I'm having trouble finding best practices instructions for installing the bitcoin daemon (bitcoind) on a Linux Server (Debian 11).

Requirements:
  • No mining
  • No full node
  • The daemon should connect to the network via a VPN or TOR (both are present)

I'm interested in a watch-only service that provides the complete blockchain online for me personally. I would like to be able to use RPC commands, e.g. to query the balance of a specific address.

I have solid experience with running Linux servers. No experience with running Bitcoin services. My understanding so far is that the bitcoin daemon is included in the Core Client and can be started independently of the QT client.

Thank you for your attention.



Jump to: