Sharing

Simple Samba: smb.conf

Here’s a very simplified smb.conf for Samba which you can try if you are having problems with Samba in your home network. Edit the smb.conf as follows (adjust this to suit your Linux environment and editor):

sudo gedit /etc/samba/smb.conf

Replace the contents of that file with the code below.

Note: there are two shared items at the bottom that you will want to omit or change to your use. The first (storage) is a shared hard drive. The second is a shared folder (/home/user/Videos). Modify these to suit your needs.

[global]
workgroup = home
server string = %h server (Samba, Ubuntu)
dns proxy = no
local master = yes
log file = /var/log/samba/log.%m
map to guest = bad user
max log size = 1000
name resolve order = bcast host lmhosts wins
obey pam restrictions = yes
os level = 33
pam password change = yes
panic action = /usr/share/samba/panic-action %d
passdb backend = tdbsam
passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
security = share
syslog = 0
unix password sync = yes
usershare allow guests = yes
usershare max shares = 100
usershare owner only = False
cups options = raw
printing = cups
printcap name = cups
printcap cache time = 750
use client driver = yes
;guest ok = no
;guest account = nobody

[printers]
comment = All Printers
browseable = no
path = /var/spool/samba
printable = yes
;guest ok = no
;read only = yes
create mask = 0700

[print$]
comment = Printer Drivers
path = /var/lib/samba/printers
;browseable = yes
;read only = yes
;guest ok = no

[storage]
comment = storage
path = /media/storage
writeable = yes
browseable = yes
force user = frank
force group = frank
read only = no
guest ok = yes
create mask = 0777
directory mask = 0777

[Videos]
path = /home/frank/Videos
writeable = yes
browseable = yes
guest ok = yes
force user = frank
force group = frank
By practic on April 30, 2014 | | A comment?