0

So my current project is to have a full node bitcoin core on my pi4 currently following this guide: Bitcoin node guide

In this guide they reference an external hdd for the blockchain as currently the bitcoin blockchain is about 350GB. Since I have got a storageserver(nas) at home i'm going to use that as external hdd so to say.

In my nas I have got 1 Main storage array consisting of 4x10TB drives in raidz with zfs. This main storage array is called archive.

I have 1 user that has full permissions meaning chmod 777.

In this archive folder I created A BtcNode folder added a bitcoin user and made the samba configuration.<- this part seems to be working

The samba configuration for archive and bitcoin are as follows:

main archive config:

[archive]
 comment = achive
 path = /archive
 browsable = yes
 guest ok = yes
 read only = no
 writable = yes
 create mask = 777

bitcoin config:

[BtcNode]
 comment = BtcNode
 path = /archive/BtcNode
 browsable = yes 
 guest ok = no
 read only = no
 writable = yes
 create mask = 0775
 directory mask = 0775 
 valid users = storageserver, bitcoin

So in this configuration my bitcoin folder shoud only be allowed to storageserver which is my main user having 777 permissions and bitcoin which has 775 permissions.

Second part: my pi running lite version of pi os all configured and updates.

I have setup automount in fstab to my btcnode folder in my nas <- this works to as i can see files when it mounted.

the automount works, however the /mnt/BtcNode folder has root root permissions whereas this means i don't have the right permissions to write in this folder aka nas folder not with my bitcoin user on the pi nor with the pi user on the pi. I have created the bitcoin user on the pi for running the bitcoin core client as descripted in the guide.

I tried doing sudo chown -R bitcoin:bitcoin /mnt/BtcNode gave me no errors however doing ls -)l gave me still root root permission.

I assume this has to be something with pi and nas since that folder is mounted.

fstab:

//192.168.0.168/BtcNode /mnt/BtcNode cifs uid=0,credentials=/home/pi/.smb,iocharset=utf8,noperm 0 0

Question: Does someone have an idea on how to change the permission so bitcoin user is the owner and has 775 permissions so only the bitcoin user has write and read permission and no one else since this is not necesarry?

  • Could I ask you to tidy the text up a bit? I tried editing but it goes all over. Please break into paragraphs and clearly show the fstab lines, the full samba config and try to collect the questions to one place so we can see what you need. A description of what you have will help as you dropped Pi / Windows / Blockchain / VMs (and possibly a NAS / SAN) at random times and I've no idea how it all connects... Voting for clarity via close. – user115418 Nov 23 '20 at 16:23
  • ow yeah sorry i'll try to edit some stuff – Technology Researcher Nov 23 '20 at 16:43
  • Recall that in Samba, there are two sets of permissions, and you need to create a samba password for the user. – Seamus Nov 23 '20 at 21:11
  • i did that doo, i have created a samba password for the bitcoin user using smbdpassword – Technology Researcher Nov 24 '20 at 11:08

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.