Anonymous/Guest Folder Sharing - Ubuntu MATE on RPi4-B 8GB

Hello everyone,

I decided to give it a chance to UBUNTU MATE 20.04 on RaspberryPi 4 B with 8GB RAM

On other PCs and laptops I basically work with Mint.

Things with ubuntu-MATE went way smoother initially than with standard Ubuntu with Unity up until I tried Folder Sharing.

Installed normally Caja-share, cifs-utils, and did as per available tutorials

Normal Folder Sharing worked straight away and there was no problem there. I was immediately able to connect through Ethernet connection to my folder.

Still I have a folder with Classical music that I share with my colleagues and I wanted to make it available for everyone without a logon name or password with only read and execute permissions, without write/delete.

On Ubuntu 21.04 and 20.10 that was simple, I just checked Share this Folder and Allow Guest Access, so I did the same in MATE but the Folder is only available if I use my own credentials, but not as a Guest.

Any idea how to make this last thing work.

Some additional data

Folder is on the USB External HDD mounted with following options in fstab

permissions,x-gvfs-show,uid=1000,gid=1000

Type of Disk is: ntfs-3g

All of these settings work fine for me in Linux Mint (Not available for RPi) and Ubuntu with Unity. Of course in Unity I had to use option Folder Sharing from Settings, not right-mouse click in Files.

I was comparing /var/lib/samba/usershares files both on Ubuntu-MATE and Ubuntu-Unity and they look pretty much the same

Maybe I need to go through samba.conf to make guest folder share?

Well, to enable guest access to a shared folder I had to do following

  1. to take ownership both user and group of the /media/ folder where my USB external HDD is mounted (I did this earlier on some other Linux Distros as well)

     sudo chown <username> /media/<username>
     sudo chgrp <username> /media/<username>
    
  2. Then on this same folder I applied chmod 775, meaning that guest access won't entail a possibility to delete or change something

     sudo chmod 775 /media/<username>
    
  3. Prior to this this folder was mounted as drwxr-x---+ root root
    Now it was drwxrwxr-x+ <username> <username>

I assume that guest share was masked for all subfolders recursively.

  1. Then I did not try using caja-share right-mouse click option but instead went for smb.conf as per this instruction

https://computingforgeeks.com/install-and-configure-samba-server-share-on-debian-ubuntu/

Create mode and Directory mode were only downgraded to 775 and I did not occupy with the tutorial part beginning with Configure secure samba share and thereafter.

Maybe right-mouse click might have worked as well?

At the end I removed the old rule for the folder in /var/lib/samba/usershares/

Now sharing of the folder works both for guest users without a possibility of changing something, and I can have a full access with my own credentials.