Quick question about setting up a new node

Hey all,

So I’ve been working my way through the installation guide and have come to the point where you do the Docker Run command as below:

docker run -d --restart unless-stopped --stop-timeout 300
-p 28967:28967
-p 127.0.0.1:14002:14002
-e WALLET=“0xXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX”
-e EMAIL="user@example.com"
-e ADDRESS=“domain.ddns.net:28967
-e STORAGE=“2TB”
–mount type=bind,source="",destination=/app/identity
–mount type=bind,source="",destination=/app/config
–name storagenode storjlabs/storagenode:beta

My question is with regards to the STORAGE value, I have attached an 8TB USB disk to the pc which is running Ubuntu server 18.04 and if I run df -h i get the following:

Filesystem Size Used Avail Use% Mounted on
udev 1.9G 0 1.9G 0% /dev
tmpfs 391M 1.2M 390M 1% /run
/dev/sda2 110G 6.7G 98G 7% /
tmpfs 2.0G 0 2.0G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 2.0G 0 2.0G 0% /sys/fs/cgroup
/dev/loop1 90M 90M 0 100% /snap/core/8268
/dev/loop0 94M 94M 0 100% /snap/core/9066
/dev/sdb1 7.3T 93M 6.9T 1% /media/8TB

So do I put 8TB, 7.3TB or 6.9TB?

Also as this drive has just been formatted why has the storage dropped to 6.9TB from 7.3TB; it’s literally empty apart from a Lost+Found folder which is only 16 K?

Thanks for any help

What file system? If ext2/3/4, then it reserves 5% of disk space for root. It’s pretty much an outdated practice except for the root file system and can be dealt with using tune2fs.

8TB drives in fact have 7.3 TB … i dont wanna start the explication process you can search that on google … you have 6.9 because linux lets some unused space on every drive for root backups … you can win that space by formating the hard drive … here is a script i customized that u can use , just add to a file … HARD in my case that script chmod +x HARD and use it … in your chase ./HARD b1 will format and prepare your drive (carefull this will erase everything on /dev/sdb1 ) you will see your full 7.2-7.3 TB after …

I`m here for any linux related questions !!!

root@SERVER1:~# cat HARD
fdisk -l /dev/sd$1
mkfs.ext4 /dev/sd$1
tune2fs -O ^has_journal /dev/sd$1
fsck /dev/sd$1
tune2fs -m 0 /dev/sd$1
root@SERVER1:~#

Remember to keep 10% for overhead. So having 6.9TB free space would mean your node should have 6.3TB assigned for STORAGE.

That’s included in the free space. Reserved for root means reserved for root, not unavailable: if free space drops under 5% only root can use that space.

The storage amount which is not available is used by the file system for superblocks backups, journal, etc.

I would never remove the journal on a file system, specially if used for a service like Storj: in my opinion file system integrity is more important than a bunch of additional MBs.

Thanks for the help guys that’s helped a lot :slightly_smiling_face:

1 Like

its your opinion and it’s wrong … because you didn’t read all … if you go up you will see he attached an external drive … had nothing to do with file system, the OS is installed on another drive probably SSD as it should … but anyway … opinions are always welcome …

Cheers !

glad it helped ! Cheers

I didn’t mention the OS, if you can tell me where I mentioned the OS I would be graceful.
Moreover: how you can say that an external drive has nothing to do with file system???

Here you’re missing the source directory. And I would recommend not to use the mount point and rather create a sub directory on the external disk. This way the storagenode will not start without the disk being mounted, which would lead to a quick disqualification otherwise. And if possible you should use internal disks directly connected to a SATA port.

Is this a static mount in /etc/fstab?