Create a directory:
mkdir /tmp/shared
Mount the directory in samba server:
sudo mount -t cifs -o user=smb //192.168.31.21/shared /tmp/shared
Password for smb@//192.168.31.21/shared: ***
It is mounted, and can list all files in it:
ls /tmp/shared
The file can't be saved after editing it - error:
Failed to save the document
permission denied
How to mount the shared directory in samba server with writable permission?
Do you have set writeable = yes
in your /etc/samba/smb.conf
To allow all users to access and write:
[share]
path = /shared
browseable = yes
read only = no
writeable = yes
browseable = yes
public = yes
create mask = 0644
directory mask = 0755
Depending on your distro /etc/init.d/samba restart
or systemctl restart smb