Bitcoin Forum

Bitcoin => Bitcoin Discussion => Topic started by: julian_sun on October 08, 2020, 01:38:45 AM



Title: how to store wallet on usb drive with bitcoin core?
Post by: julian_sun on October 08, 2020, 01:38:45 AM
I have set up a full node of bitcoin core on an ARM board (Pine Rockpro64).  It is running well.

I'm thinking to make use its wallet feature to store/send/receive coins.  Since the node is up in the internet all the time, I think it should be better to store the wallet files on a USB drive.  When I do transactions, I will insert the USB.  When I'm done with the transactions, I will remove the USB.  There are some USB drive equipped with fingerprint unlocking, which adds additional security.

Does anybody know how this can be achieved?  The closest thing seems to be "open"/"close" wallet, which I'm not sure what it really means.  Also when I create a wallet it does not seem to let me select a directory to store the wallet files.

Thanks!


Title: Re: how to store wallet on usb drive with bitcoin core?
Post by: jackg on October 08, 2020, 02:27:12 AM
There are some USB drive equipped with fingerprint unlocking, which adds additional security.


That's not the consensus here, biometrics aren't very useful as they can be bypassed (they normally aren't used to directly encrypt data.

Quote

Does anybody know how this can be achieved?  The closest thing seems to be "open"/"close" wallet, which I'm not sure what it really means.  Also when I create a wallet it does not seem to let me select a directory to store the wallet files.

Thanks!

You might be better off running electrum personal server on that device and getting another to store your wallet/potentially using the same one and plugging it in when necessary if possible.

Afaik once you put a wallet file into core it'll start to at least rescan your blockchain data which may take some time...


Title: Re: how to store wallet on usb drive with bitcoin core?
Post by: tbct_mt2 on October 08, 2020, 03:13:39 AM
With USB, the speed of synchronisation will be slow down a bit.

You said you have a full node with Bitcoin Core and such a node (full) will require huge data storage space. I think that harddrive is better for you.

When use USB to store wallet and use it for transactions, it is good to try SPV (Simplified Payment Verification) wallet like Electrum. You don't to need wallet rescan like with Bitcoin Core (full or prune node). With Electrum, you don't need huge storage space and don't need to wait too long to sync wallet (a few seconds with good internet connection).

https://en.bitcoinwiki.org/wiki/Simplified_Payment_Verification



Title: Re: how to store wallet on usb drive with bitcoin core?
Post by: julian_sun on October 08, 2020, 03:28:09 AM
Thanks.

Maybe there are something I don't quite understand yet.

Currently if you create a new wallet (say "test'), the software just create directory "test" under ~/.bitcoin directory.

Can I do the following?

  • move "test" directory to usb drive
  • create a symlink from usb drive back to ~/.bitcoin/test
  • before I do transactions, I just insert usb drive, open "test" wallet, do transaction, close "test" wallet, and unplug USB drive

Will this work?  Are there any slow sync or capacity issue here?

I feel like I did all this work to set up a full node, at least I should get something out of it. :)  So if I can save some money and hassle of buying another wallet, I'm up for it.

---
P.S., Regarding fingerprint feature in USB drive, it is for just additional security - in addition to all the normal password/encryption practice, rather than replacing them.


Title: Re: how to store wallet on usb drive with bitcoin core?
Post by: hatshepsut93 on October 08, 2020, 01:50:29 PM
You can create an unsigned transaction, sign it on an offline machine with your private keys that are stored on a USB, then just transfer these signed transactions via another USB to your full node and simply broadcast them. This is known as a cold storage setup, and it's pretty easy to implement with Electrum, though it should also be possible with Bitcoin Core. This answer (https://bitcoin.stackexchange.com/questions/89962/how-to-send-bitcoin-from-an-offline-bitcoin-core-that-doesnt-have-a-synced-balal) on stackexchange explains how this setup works with Bitcoin Core.


Title: Re: how to store wallet on usb drive with bitcoin core?
Post by: julian_sun on October 08, 2020, 03:35:48 PM
Thanks.  This is really good info.

It seems more complicated than what I thought because it needs 2 bitcoin core clients running, one online and one offline, but it certain seems more secure than my original idea of storing wallet on USB.  I will take a look.

Maybe we can implement the offline bitcoin core client as a strip-down VM and store it on the USB disk.  That would be cool and secure as well.  I will give that a thought.  Any pointers are appreciated.