Code Yarns ‍👨‍💻
Tech BlogPersonal Blog

How to share directory using SMB

📅 2014-Jul-07 ⬩ ✍️ Ashwin Nanjappa ⬩ 📚 Archive

This post shows the basic steps to share a directory over the network using SMB on the commandline. If you prefer a GUI program, see the post about using Samba Server Configuration tool.

$ sudo apt install samba
$ sudo smbpasswd -a joe
$ sudo chown joe /path/to/share
$ sudo chown :joe /path/to/share
$ sudo vim /etc/samba/smb.conf
[joe-share]
    path = /path/to/share
    available = yes
    valid users = joe
    read only = no
    browseable = yes
    public = yes
    writable = yes
$ sudo service smbd restart

or

$ sudo service samba restart

Tried with: Ubuntu 14.04