Author

Topic: Linux - I can't install blockchain on external HDD (Read 161 times)

legendary
Activity: 3290
Merit: 16489
Thick-Skinned Gang Leader and Golden Feather 2021
Maybe I have used the words "external" and "partition" wrong. I'm not a techie person.
"External" just means: outside of your computer.

In the /media folder I found the disks. Linux is so different from Windows.
I like the Linux approach much more. You could for instance mount the second disk as /home/username/.bitcoin/blocks, which makes it a dedicated blockchain disk.
hero member
Activity: 504
Merit: 1065
Crypto Swap Exchange
iwantmyhomepaidwithbtc2 was right. In the /media folder I found the disks. Linux is so different from Windows. I didn't know that.
I also moved the chainstate folder from HDD to SDD and created a symlink. Now it's downloading twice faster.
I'm grateful to everyone who help me on this topic.
Cheers!

I'm glad to hear that everything's okay now! You did the right thing moving chainstate.

If you want to learn more about the Unix file system, this article is cool : https://www.geeksforgeeks.org/unix-file-system/
jr. member
Activity: 43
Merit: 25
iwantmyhomepaidwithbtc2 was right. In the /media folder I found the disks. Linux is so different from Windows. I didn't know that.
I also moved the chainstate folder from HDD to SDD and created a symlink. Now it's downloading twice faster.
I'm grateful to everyone who help me on this topic.
Cheers!
jr. member
Activity: 43
Merit: 25
Maybe I have used the words "external" and "partition" wrong. I'm not a techie person.
I've read all of your replies, I appreciate your efforts to help me.
I will try all of them today or tomorrow morning, and will tell you how it went. Wish me luck.
If anyone has other ideas, please let them here.
Thank you brothers!
legendary
Activity: 3290
Merit: 16489
Thick-Skinned Gang Leader and Golden Feather 2021
I also did the trick with symlink for chainstate on ssd.
I meant the other way around: chainstate can just stay in your normal home directory. That way, all your wallets end up in your home directory too (which makes it easier to add to your standard backups).

Quote
My 1TB HDD is already formatted and I plan to use it just for Bitcoin Core. My hdd's and ssd are connected through SATA, not USB.
Does that mean they're internal instead of external? I assumed it's USB because of the topic title, and I don't think external SATA is very common.

Quote
the linux btc core installer sees only the partition where the os is installed.
In Linux, applications don't deal with "partitions". You just mount the partition, for instance in /home2, set up the permissions, and tell Bitcoin Core to save it's data in /home2/username/bitcoin.
Or better: Tell Bitcoin Core to install in your normal home directory, then quit it, move blocks from ~/.bitcoin to /home2/username/bitcoin/blocks, create a symlink for blocks in your .bitcoin directory, and restart Bitcoin Core.
legendary
Activity: 1932
Merit: 1273


Can you make sure the three drives beside "Computer" are mounted? Try to browse around within the drives, and see if you can access your HDD first. The screenshot you gave seems to indicate it hasn't yet mounted.



After you make sure it's mounted. Continue to this current step. On the Choose Data Directory window, click "/" to see if there are lists of folders.

If there is none, that might indicate Bitcoin Core somehow can not access the folders. And I don't know any clue what causes it.

If it's listed, continue to look at the "mnt" folder, see if your mounted drive exists there and locate which folder you want to use for the data directory. If there is no mnt folder, try to look at "media" as others suggest.

jr. member
Activity: 43
Merit: 25
Yes, Software Store. Maybe, there is a configuration file, but I had not chosen a directory for blockchain to install before.

LoyceV, you misunderstood my problem. I want to run a full node, not a pruned one. I know how to install each one. I ran a full node in the past, I know how to install and configure it. I also did the trick with symlink for chainstate on ssd. My 1TB HDD is already formatted and I plan to use it just for Bitcoin Core. My hdd's and ssd are connected through SATA, not USB.

My problem is that, unlike windows btc core installer, where I could choose any partition I wanted, the linux btc core installer sees only the partition where the os is installed.
legendary
Activity: 3290
Merit: 16489
Thick-Skinned Gang Leader and Golden Feather 2021
This is my first time using Linux.
First things first: what are you trying to do? I wouldn't recommend installing Bitcoin Core on an exteral drive, if the USB cable gets disconnected, chances are your blockchain gets corrupted. Your screenshots show "prune to 2 GB", if you choose that, you can just as well use your internal SSD.
But if you do insist on using an external drive, there's a huge performance improvement if you keep chainstate on your SSD. My blocks directory is a symlink to my (internal) HDD, and if you insist on using an external drive, I recommend to do the same.
What filesystem do you have on your external drive? If you're not planning on using it without Linux, I recommend formatting it with a decent filesystem that supports permissions. For instance, ext4 will do.

I know this doesn't answer your questions directly, but it's probably good to take a step back first and get the basics right. Linux is great, but there can be a steep learning curve.
jr. member
Activity: 43
Merit: 25
Thank you for your answer Smiley I will try when I'll be home.

I tried 3 ways to install it. From snap, bitcoin.org, and default linux store.
For the first two I get the same result. For the last, it skips the window where I can choose the directory, and it's downloading the blockchain in the default directory.
hero member
Activity: 504
Merit: 1065
Crypto Swap Exchange
https://ibb.co/3RL6kvp - This is what is displayed.
https://ibb.co/Xxpk01H

I don't have /media (or at least I don't see it). In the "Look in" window is just "Computer" (where linux is installed).
And in the left windows is "Computer" and User (/home/user). Dragos in my case.
The HDD's are not displayed.

I don't know commands in linux, like lsblk, that's why I asked a step-by-step solution. Because I'm new in linux.
Thanks.

You just need to open a Terminal and type :
Code:
lsblk

This command will show you the exact path to find your external HDD.

More information here :

lsblk  lists  information  about  all available or the specified block devices.  The lsblk  command reads the sysfs filesystem and udev db to gather information.
The command prints all block devices (except RAM disks) in a tree-like format by  default.
Use lsblk --help to get a list of all available columns.


On your first screenshot, if you click on   /   

You will get a list of folders.

Inside this list you have a folder named media.

This folder is where you can find your HDD, USB sticks etc..

So from your Screenshot number 1, I would click on /
media
Dragos
name of your HDD (which can easily find with the help of lsblk mentioned above
jr. member
Activity: 43
Merit: 25
https://ibb.co/3RL6kvp - This is what is displayed.
https://ibb.co/Xxpk01H

I don't have /media (or at least I don't see it). In the "Look in" window is just "Computer" (where linux is installed).
And in the left windows is "Computer" and User (/home/user). Dragos in my case.
The HDD's are not displayed.

I don't know commands in linux, like lsblk, that's why I asked a step-by-step solution. Because I'm new in linux.
Thanks.
hero member
Activity: 504
Merit: 1065
Crypto Swap Exchange
Don't you see your external HDD in /media when you are selecting a folder in Bitcoin Core?
Otherwise you can use lsblk to try to find the exact path.

If you copy paste or write the exact path in Bitcoin Core, it should be fine normally.

jr. member
Activity: 43
Merit: 25
Hello everyone.

I tried to find a solution, but I didn't find a step-by-step one.

I'm using Linux (Zorin - based on Ubuntu) on a 256 GB SSD. I want to install the blockchain on a separate 1 TB HDD. ( I have 2 HDD's)
The problem is that although I can access the HDD's from the OS, they are not seen when I want to install the blockchain.

How can I solve the problem? Step-by-step, please. Not just "Give permission to the app" or something like this. This is my first time using Linux.

Thank you!

Jump to: