Note this is not duplicate of Is there a way to change the wallet.dat location without changing the entire data directory?

I want to change wallet.dat file location. From the above link it seems to be impossible. But is there any way i can update wallet file location in bitcoin source code https://github.com/bitcoin/bitcoin and run make command to make it executable. Here is the reason why i want to do this: https://serverfault.com/questions/888293/share-a-file-between-aws-servers

I want to share a common wallet.dat file between two server.

  • 2
    You should not share a wallet.dat file between two servers. It may not even work and may result in wallet corruption and loss of funds. If you are planning on having the two instances open the same wallet file, that is not allowed. BDB (the database system used by Bitcoin Core) does not allow a database to be opened by multiple software simultaneously. If you are somehow able to do so, you can corrupt your wallet.
    – Ava Chow
    Commented Dec 15, 2017 at 14:20
  • 1
    Furthermore, even if the wallet file is not accessed simultaneously, the two nodes will have different sync states which will result in the software being confused and potentially have to rescan every time you start up one of the nodes. It may also have other issues.
    – Ava Chow
    Commented Dec 15, 2017 at 14:20
  • @AndrewChow Thanks for your comment. What about if i run bitcoin core in server 1 and access server 1's bitcore core in server 2 to run get balance and sendToAddress method. will this create any consistency issue. I am using amazon load balancer under this i have these two server. If user make request simultaneously will there is any chance of consistency issue. Is there is any synchronization mechanism implemented in bitcore core to handle situation like this.
    – Ajit Soman
    Commented Dec 15, 2017 at 17:22
  • 1
    Yes, that is correct.
    – Ava Chow
    Commented Dec 15, 2017 at 19:11
  • 1
    It should be able to handle all of that in a thread safe manner as Bitcoind has locking mechanisms to ensure consistency with concurrent operations. However note that with that many RPC calls, bitcoind may not respond to all of them in a timely manner (some may timeout because locks are held by an operation elsewhere).
    – Ava Chow
    Commented Dec 16, 2017 at 5:37

1 Answer 1


Just wait for the next Bitcoin Core release. They've already implemented -walletdir: https://github.com/bitcoin/bitcoin/commit/0530ba0eae147563921b162ed05347234d8b53c0


  • +1 for sharing this information. Could you please provide me suggestion based on the comment i have posted in question.
    – Ajit Soman
    Commented Dec 15, 2017 at 17:24
  • @AjitSoman Are you on Windows? You'll need to follow this steps if you're on Windows 10: github.com/bitcoin/bitcoin/blob/master/doc/… and continue with github.com/bitcoin/bitcoin/blob/master/doc/… or you can just install a Linux VM and do the instructions on the second document.
    – MCCCS
    Commented Dec 16, 2017 at 6:06
  • I have found solution for my problem. You can read comments on question
    – Ajit Soman
    Commented Dec 16, 2017 at 6:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.