2

I want to store my bitcoins into a server into a datacenter and access it via SSH/VNC.

The problem here is:

If the hard drive gets destroyed/fails/gets problems, how do I recover my bitcoins?

A friend of mine said that I must have an encrypted backup of the private key.

What private key? How do I do all of this if I'm gonna use a Centos/Debian OS for the server and the Bitcoin core client?

Thank you!

1

If you are running bitcoin core daemon on the server, it will have a wallet.dat which you can encrypt (with the encryptwallet command), containing the private keys. So then you can just back up that wallet file, and your private keys will be safe as long as you have the backup and the decryption key for the wallet

1

Your private key is stored in your wallet. This is the critical piece of information that will allow you to use this address in the future. Encrypting the wallet have having a backup of wallet.dat are important steps.

But, you can even store you keys completely offline.
Even on a computer that has never been connected to the network.

  • Create a new address with:bitcoin-cli getnewaddress ""
  • List all the addresses of account "" with: bitcoin-cli getaddressesbyaccount ""
  • You can now print the private key of an address
    bitcoin-cli dumpprivkey <BITCOIN_ADDRESS>

If your wallet is encrypted, you have to unlock it first.

The result of this command will be your private key. You can copy it to a piece of paper and put it somewhere you can safely store it.

You can add it to a wallet in the future. Following this wiki: https://en.bitcoin.it/wiki/How_to_import_private_keys

Using the bitcoin-cli you need to run (After unlocking your wallet):
bitcoin-cli importprivkey "<YOUR_PRIVATE_KEY>" "" false

The false at the end is to prevent a rescan of the blockchain.

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.