Skip to main content
loading
Samba shared folder settings

Sometimes you need to edit shared folders in the SMB protocol. In Samba, you can find configuration file smb.conf under /etc/samba.

Connect via SSH to your linux machine and type:

sudo nano /etc/samba/smb.conf

Add a shared folder at the end of the file. Here, for example, we add the openhabian user's home folder and the library folder for Arduino sketches.

[home]
 comment=opt folder
 path=/home/openhabian
 writeable=yes
 only guest=no
 public=no
 create mask=0664
 directory mask=0775
 veto files = /Thumbs.db/.DS_Store/._.DS_Store/.apdisk/._*/
 delete veto files = yes

[lib]
 comment=opt folder
 path=/usr/share/arduino/libraries
 writeable=yes
 only guest=no
 public=no
 create mask=0664
 directory mask=0775
 veto files = /Thumbs.db/.DS_Store/._.DS_Store/.apdisk/._*/
 delete veto files = yes

 

Save the changes by pressing Right CTRL+O and press Enter to confirm. To exit the nano editor, press the Right CTRL+X combination.

Restart the samba service using the command:

sudo service smbd restart

Now your folders should be visible on the network via the SMB protocol.

 

Tags

Add new comment

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.