File permissions over Linux - Linux share using samba

Colin Law clanlaw at gmail.com
Tue May 9 16:40:37 UTC 2023


I am using Samba running on Pi OS (Buster) to share folders to Ubuntu
and Windows.
In the Pi /etc/samba/smb.conf I have

[usbhdd]
  comment = USB Disc Drive
  path = /media/usbhdd
  browsable = yes
  read only = no
  create mask = 775
  guest ok = no

In Ubuntu I am mounting it using

mount -t cifs -o
credentials=/path/to/.credentials,user,rw,uid=1000,gid=1000
//servername.local/usbhdd /media/server_usbhdd

Everything works fine, except for the fact that, viewed from ubuntu,
all the files have permissions 0755 whereas on the pi some of them
have, for example 0644.
If I add vers=1.0 at the start of the options string then the
permissions are correct on Ubuntu, but I quite correctly get a warning
saying I should not be using an old version.
I have googled and experimented but don't fully understand the
complexity of the options in samba so any help with this would be much
appreciated.

Colin Law




More information about the ubuntu-users mailing list