[Solved] SMB Share working for Mint 18 but not Mint 19.

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
TomForge
Level 2
Level 2
Posts: 51
Joined: Mon Aug 21, 2017 2:23 pm

[Solved] SMB Share working for Mint 18 but not Mint 19.

Post by TomForge »

SOLUTION AT END

I updated one of my computers from LM18 to LM19. I copied the #Network Shares section of my old LM18 /etc/fstab file to my LM19 /etc/fstab. Now I get mount error 22.

I know things are working on the server (192.168.1.99) end because my 2 remaining LM18 machines are connecting just fine and the locations are mounting automatically.

I am just having trouble with the new LM19 install.

Determined the user id (uid) and group id (gid) of the account.

> id tom

> sudo mkdir /forge

> sudo cp -a fstab fstab-backup

The following line added to the end of the fstab:

> # Network Shares

> //192.168.1.99/forge /forge cifs uid=1000,gid=1000,credentials=/home/tom/.credentials,iocharset=utf8,sec=ntlm 0 0

Add the following lines to /home/tom/.credentials

> username=tom
> password=******

Finally ran:

> sudo chmod 600 /home/[user|tom]/.credentials

> sudo mount -a

I read a stack overflow thread that may be helpful but I don't understand what actually to do:

It read:

"maybe this helps with this, mount error(22): Invalid argument... possible error is the argument/s (mode) on mount command. check your logs on the errors encountered.

> tail -f /var/log/kern.log

then remove the invalid argument"

So this is the info I get when I run the tail command:

Aug 23 10:15:27 MJOLNIR kernel: [ 1831.476864] No dialect specified on mount. Default has changed to a more secure dialect, SMB2.1 or later (e.g. SMB3), from CIFS (SMB1). To use the less secure SMB1 dialect to access old servers which do not support SMB3 (or SMB2.1) specify vers=1.0 on mount.
Aug 23 10:15:27 MJOLNIR kernel: [ 1831.492575] CIFS VFS: Unable to select appropriate authentication method!
Aug 23 10:15:27 MJOLNIR kernel: [ 1831.492580] CIFS VFS: Send error in SessSetup = -22
Aug 23 10:15:27 MJOLNIR kernel: [ 1831.492605] CIFS VFS: cifs_mount failed w/return code = -22

SOLUTION:

So change the entry in the /etc/fstab file to read:

> //192.168.1.99/forge /forge cifs uid=1000,gid=1000,credentials=/home/tom/.credentials,iocharset=utf8,vers=1.0,sec=ntlm 0 0

The argument that needed to be ADDED not REMOVED is underlined.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
deepakdeshp
Level 20
Level 20
Posts: 12341
Joined: Sun Aug 09, 2015 10:00 am

Re: [Solved] SMB Share working for Mint 18 but not Mint 19.

Post by deepakdeshp »

Thanks for sharing the solution.
If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak

Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Locked

Return to “Networking”