User Tools

Site Tools


file-server

Add Samba File Server

  • Use this command
apt install samba samba-common-bin
  • Add Shares by using
 nano /etc/samba/smb.conf
  • Add these AT THE BOTTOM!
## Share
 
[Share]
 
comment = needs username and password to access
path = /physicalpathyouwant/toshare
browseable = yes
guest ok = no
writable = yes
valid users = @samba
  • Add Username
sudo adduser 'user'
  • Add Password
sudo smbpasswd -a 'user
  • Create Samba Group
sudo groupadd samba
  • Add user to group
sudo gpasswd -a 'user'; samba
  • Then add read/write/execute permissions to the drives:
sudo setfacl -R -m "g:samba:rwx" /physical/shared/file
  • Restart Samba
sudo systemctl restart smbd nmbd
file-server.txt · Last modified: 2023/05/17 22:52 by 127.0.0.1