[Advanced] Basic SAMBA shares (and Xubuntu 20.04 bugs/issues)

By charm, 23 November, 2020

Here's my /etc/samba/smb.conf file:

#======================= Global Settings =======================

[global]
   workgroup = MEDIA
   client min protocol = NT1
   server min protocol = NT1
   server string = %h server (Samba, Ubuntu)
   security = user
   map to guest = bad user
   name resolve order = bcast host
   log file = /var/log/samba/log.%m
   max log size = 1000
   logging = file

#======================= Share Definitions =======================

[Media]
    comment = KODI media
    path = /mnt/media
    read only = yes
    browseable = yes
    public = yes
    force user = smbuser
    force group = smbgroup

I also created the group smbgroup

sudo groupadd --system smbgroup

And the user smbuser

sudo useradd --system --no-create-home --group smbgroup -s /bin/false smbuser

Next I changed the permissions on my /mnt/media to be the smbuser and smbgroup.

sudo chown -R smbuser:smbgroup /mnt/media

You might be wondering about the client min protocol and server min protocol lines under the [global] configuration section. These lines are there because there is currently a bug in the implementation that browses as an earlier version of SMB, but the server wants a later version.

 

Tags