SAMBA server beginner help wanted!

Have some feedback, questions, suggestions, or just fancy a chat? Pop it in here.
Post Reply
Snoevit
Posts: 2
Joined: Fri Dec 29, 2017 2:19 pm
Location: Sweden

SAMBA server beginner help wanted!

Post by Snoevit »

Hi!
Im a total newbie of all this and want some help. :P
Im trying to set up an Samba server with 2 shares, 1 for each user. (so far so good, i think).

After creating two new
  • sudo useradd -M name
with 'passwd' i install samba.
In
  • /etc/samba/smb.conf
i add
  • [share1]
    comment = share1
    path = /mnt/usb1
    browseable = yes
    create mask = 0775
    directory mask = 0775
    valid users = name1
    writeable = yes
and again for name2 / share2.

[Global/Public] Is still untouched.

After that i do
  • smbpasswd -a name1
And
  • chmod 770 -R /mnt/usb1
    chown -R name1:dietpi /mnt/usb1
I do the same thing for name2 to /mnt/usb2.

Is this safe enough? No guest access, need correct passwd to access each share?

STEP TWO:
Step two of all this is to use 'dietpi-sync' to sync BOTH of this shares to another unit ( Rpi or similar )
But for security reasons i wounder if it is a good way to use a third user, e.g dietpi for the sync process?

How do i do that?
  • valid users = name1, dietpi
with
  • chown -R dietpi:dietpi /mnt/usb1
?
Is there a better way to do this? Or am i way off in my thinking?
User avatar
WarHawk
Posts: 634
Joined: Thu Jul 20, 2017 8:55 am

Re: SAMBA server beginner help wanted!

Post by WarHawk »

Here is a walkthru...it might help

https://pimylifeup.com/raspberry-pi-nas/

Anyone more experienced want to chime in?
Snoevit
Posts: 2
Joined: Fri Dec 29, 2017 2:19 pm
Location: Sweden

Re: SAMBA server beginner help wanted!

Post by Snoevit »

WarHawk wrote:Here is a walkthru...it might help

https://pimylifeup.com/raspberry-pi-nas/

Anyone more experienced want to chime in?
Ah, thank you! :) Will have a look!
owenwong0929
Posts: 2
Joined: Mon Dec 23, 2019 9:52 am

Re: SAMBA server beginner help wanted!

Post by owenwong0929 »

I am also very interested in this topic, has the author made it?
owenwong0929
Posts: 2
Joined: Mon Dec 23, 2019 9:52 am

Re: SAMBA server beginner help wanted!

Post by owenwong0929 »

I have found an article that introduces how to make a NAS box by Raspberry pi. It is very convenient and small.
https://www.sunfounder.com/blog/diy-nas-kit/
Post Reply