1

I always installed bitcoin from the tar.gz but now tried the snap but it uses a different data folder, so I removed the blocks, chainstate and indexes and replaced them with the same old symlink to my external drive I had used with 0.18.1 but no matter what I do, I get

2021-02-02T22:03:42Z init message: Loading block index...
2021-02-02T22:03:42Z Switching active chainstate to Chainstate [ibd] @ height -1 (null)
2021-02-02T22:03:42Z Opening LevelDB in /home/leo/snap/bitcoin-core/common/.bitcoin/blocks/index
2021-02-02T22:03:42Z Fatal LevelDB error: IO error: /home/leo/snap/bitcoin-core/common/.bitcoin/blocks/index/LOCK: Permission denied

but the permissions on that file are the exact same as on the file bitcoin-core creates in the default folder. I also tried to move the default folder around and symlink it back to blocks but I get the same error.

I read that snap has tight restrictions on file access but don't see how or where that restrictions come into play. My main drive does not have 400GB available and I need indexing, not pruning. Is snap just not for me or can I store the blocks on my other drive after all?

2
  • 1
    Snap is restrictive like this by design. A symlink will not work. You will need to mount your drive somewhere in /home/leo, /media/leo, or /mnt, and then configure bitcoind/Bitcoin Core to use that directory as its datadir.
    – Jivan Pal
    Feb 12 at 13:38
  • Want to turn this into an acceptable answer? Something like "close bitcoin-core, edit file ???/bitcoin.conf adding datadir=/path/to/your/external/drive/folder, make sure your ??? folders with all the data are under that folder, start bitcoin-core".
    – Giszmo
    Feb 15 at 13:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.