How to allow remote SMB/CIFS access to /home/pi on the Raspberry Pi

First, install samba using

install_samba.sh
sudo apt -y install samba

then appendthe following to /etc/samba/smb.conf

smb.conf
[pi]
   comment = pi
   path = /home/pi
   writeable = yes
   browseable = yes
   public = yes
   create mask = 0644
   directory mask = 0755
   force user = pi

and finally restart samba:

example.sh
sudo systemctl restart smbd

Now your /home/pi will be accessible via SMB (including write access).


Check out similar posts by category: Linux, Raspberry Pi