Fix mount error(95): solved! Operation not supported SMB

15 Jan 2022 | Fix mount error(95): solved! Operation not supported SMB |

Mounts SMB/CIFS shares with Linux

It’s common practice to mount Windows file shares on Linux  using the SMB (Samba) implementation on Linux.  the command is fairly straight forward.

# Install the required libraries if you  haven't done that yet
sudo apt update
sudo apt install cifs-utils

#Next mount the folder you want 
sudo mount -t cifs -o username=user_name //server_name_or_ip/share_name /mnt/share_name

The command above would:

  • mount a server with the server_name or ip in the //server_name/share_name
  • to a local /mnt/share_name folder
  • so once the mount is complete you can access the shares contents by accessing the /mnt/share_name folder locally.

There are all sorts of options using this command , and when the share is created on the server , things like file access and permissions can be set.  You can find a more complete description here on how to access and setup windows shares in Linux

The issue with Samba/Cifs mounts (on Synology and other SMB servers) error 95

Apparently there has been a change to the SMB (Samba) protocol . SMB1 was the default, which may not be sufficient because of  upgraded  security requirement tof SMB2 . So try setting the version to SMB2 with ver=2.0  Or ver=3.0  , more specifically in my case, Synology updated their SMB server and increased the security  , and for those of us that do not keep up to date with the changes may find that our once working mount commands, are not failing with a message such as ..

mount error(95): Operation not supported

This obscure message with its “operation not supported” doesn’t shed light on the true cause of the issue. Online  documentation is  I was able to find online such as this Samba.Org mount.cifs document doesn’t really help much either.  The trick is you can try dmesg to give you  a more precise message.

mount error(95): Operation not supported 
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) and kernel log messages (dmesg)

You can try dmesg to give you  a more precise message

CIFS: VFS: Use of the less secure dialect ver=1.0 is not 
recommended unless required for access to very old servers
CIFS: VFS: cifs_mount failed w/return code = -95

So if you  haven’t a version set in your configuration (Your connection string) it will assume your client uses SMB1 as default, which may not be sufficient if the server you’re trying to connect to has upgraded there requirement to SMB2 . So try setting the version to SMB2 with ver=2.0  to see if it resolves the issue, as it did in my case,

So my Old error connection string

sudo mount -t cifs -o username=user_name //server_name/share_name /mnt/share_name

Revised  working connection string. use vers=2.0  as part of your -0 witch attributes.

sudo mount -t cifs -o vers=2.0,username=user_name,password=password //server_name/share_name /mnt/share_name

Anyways this was just a quick post as it was a pain in the ass as to why all of a sudden my mounts to my Synology began failing.. hope it helps.

If you found this post useful , leave a comment below!