17

TL;DR: What is the syntax to mount a CIFS share via SMB3 in /etc/fstab?

Previously, I had this working in my /etc/fstab:

//192.168.1.100/Movies /mnt/Media cifs credentials=/home/syn/.smbcred,uid=111,gid=1000,iocharset=utf8 0 0

But after some bug with the server, I now need to specify the SMB version when mounting. I am able to do this via mount:

sudo mount -t cifs //192.168.1.100/Movies /mnt/Media -o vers=3.0,user=plex,uid=111,gid=1000,pass=PASSWORD

But I cannot seem to specify the version in fstab and get it to work. Any ideas?

Similar thread here, but unanswered.

synthetiq
  • 173

2 Answers2

29

I had the same problem which was also due to an upgrade to one of my institute’s servers. I managed to mount the share by adding the vers=3.0 option to fstab without the -o argument.

//192.168.1.100/Movies /mnt/Media cifs vers=3.0,credentials=/home/syn/.smbcred,uid=111,gid=1000,iocharset=utf8 0 0
kmdouglass
  • 406
  • 5
  • 5
3

I ran into the same issue after installing Ubuntu 18.04. Package cifs-utils now uses SMB 2.1 or greater and I needed to use version 1.

In /etc/fstab add vers=n.n right after your credentials file like here:

//192.168.1.144/video /media/nas/ cifs auto,credentials=/.smbcredentials_3,vers=1.0,iocharset=utf8,sec=ntlm 0 0
Bobby
  • 31