LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 10-18-2017, 09:38 PM   #31
k9dog
LQ Newbie
 
Registered: Oct 2017
Posts: 5

Rep: Reputation: Disabled

Aaand it shows it's ugly head again! This time you might find it's because your kernel rose above 4.13.
There is solutions that are as QaD as DOS. The reason is Linus force moved cifs to SMB3 from SMB1. Before you do an easy solution (downgrading or adding an option to use SMB1) you should take note of the problems SMB1 can cause, If your machine is behind a firewall you will probably keep the net safe enough. I took an easy solution for now, but will resolve issues eventually.

Last edited by k9dog; 10-18-2017 at 09:49 PM.
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 10-19-2017, 07:28 AM   #32
Rickkkk
Senior Member
 
Registered: Dec 2014
Location: Montreal, Quebec and Dartmouth, Nova Scotia CANADA
Distribution: Arch, AntiX, ArtiX
Posts: 1,364

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
Quote:
Originally Posted by k9dog View Post
Aaand it shows it's ugly head again! This time you might find it's because your kernel rose above 4.13.
There is solutions that are as QaD as DOS. The reason is Linus force moved cifs to SMB3 from SMB1. Before you do an easy solution (downgrading or adding an option to use SMB1) you should take note of the problems SMB1 can cause, If your machine is behind a firewall you will probably keep the net safe enough. I took an easy solution for now, but will resolve issues eventually.
In order to continue to connect to cifs shares on a Windows 2003 Server in my home LAN, I had to add "vers=1.0" to my fstab entries.

Cheers.
 
Old 10-20-2017, 10:55 AM   #33
jim-j
LQ Newbie
 
Registered: Nov 2003
Location: Sioux Falls SD USA
Distribution: CentOS 7
Posts: 27

Rep: Reputation: 15
CentOS 7.4 with updated 4.4 kernel needs SMB 2.1

With CentOS 7.4 using its stock kernel "kernel-3.10.0-693.2.2.el7" I could successfully mount a Windows 10 Pro version 1703 share with a command like this:
Code:
mount -t cifs //127.1.2.3/myshare /mnt/mymount -o user=william,pass=gates,vers=3.0 -rw
After upgrading my kernel to "kernel-lt-4.4.93-1.el7.elrepo.x86_64" the mount command above gave this error:
Code:
mount error(5): Input/output error
Like others here reported I could connect with smbclient like this:
Code:
smbclient //127.1.2.3/myshare -U william%gates -m SMB3
By running 'dmesg' I was able to see another error message that appeared before the unhelpful "mount error(5): Input/output error" message. The these two messages always appeared in pairs:
Code:
[root@novell bill]# dmesg
[ 7658.616374] CIFS VFS: validate protocol negotiate failed: -11
[ 7658.616563] CIFS VFS: cifs_mount failed w/return code = -5
Googling for the first error message (CIFS VFS: validate protocol negotiate failed: -11) lead me to this bug report:
https://bugzilla.redhat.com/show_bug.cgi?id=1502606
which had the workaround. Using version 2.1 instead of 3.0 solved the problem. This is the mount command that now works for me:
Code:
mount -t cifs //127.1.2.3/myshare /mnt/mymount -o user=william,pass=gates,vers=2.1 -rw
As an added bonus SMB version 2.1 also works with the stock kernel-3.10.0-693.2.2.el7.

Last edited by jim-j; 10-20-2017 at 11:37 AM.
 
Old 03-21-2018, 07:43 PM   #34
vigidr
LQ Newbie
 
Registered: Mar 2018
Posts: 1

Rep: Reputation: Disabled
Three things

Hi all,

I've just experienced the same and would like to share my solution.
  1. sec=ntlm was to be set
  2. FQDN was required suddenly (and is the best practice in any case, anyway.)
    Example: In /etc/fstab file i had to change the entry //somehostname/share to //somehostname.domain.local/share.
  3. Domain entry was to be added to credential file:
    username=usr
    domain=domain.local
    password=somepass
After those changes it worked fine again.

Last edited by vigidr; 03-21-2018 at 07:43 PM. Reason: Title
 
1 members found this post helpful.
Old 05-27-2018, 10:19 AM   #35
jamboneau
LQ Newbie
 
Registered: May 2018
Posts: 1

Rep: Reputation: Disabled
I had Ubuntu 16.04 with kernel 4.10 and mounting was working fine.
Since kernel moved to 4.13, nothing is mounting and have the error described (mount error(5): Input/output error) likely to be linked to this explanation


I made it work by adding vers=3.0 option where I got inspiration from jim-j comment

from:
Code:
//nas/share /mnt/share cifs user=myuser,password=mypwd,rw,file_mode=0777,dir_mode=0777 0 0
to

Code:
//nas/share /mnt/share cifs user=myuser,password=mypwd,rw,vers=3.0,file_mode=0777,dir_mode=0777 0 0

Last edited by jamboneau; 05-27-2018 at 10:24 AM.
 
1 members found this post helpful.
Old 09-05-2018, 08:06 PM   #36
catkin
LQ 5k Club
 
Registered: Dec 2008
Location: Tamil Nadu, India
Distribution: Debian
Posts: 8,578
Blog Entries: 31

Rep: Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208
I just fixed a "mount error(5): Input/output error" by changing in smb.conf:
Code:
force group = @<redacted>
to
Code:
force group = <redacted>
  • Server: Debian Stretch (samba 4.5.12)
  • Client: Debian Stretch
 
1 members found this post helpful.
Old 12-18-2019, 02:59 AM   #37
Hugo.router
LQ Newbie
 
Registered: Jan 2017
Posts: 2

Rep: Reputation: Disabled
the missiong comma

I found this thread having struggled to find a solution to the "mount error = 5" for cifs smb.

Having tried some of the suggestions given above [without success], I finally found another solution.
In my case the list of 'valid users' in smb.conf needed to be separated by commas

valid users = joe jane @sambashare didn't work and returned the error =5
valid users = joe, jane, @sambashare did work
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
"/usr/bin/ls: reading directory .: Input/output error" DiZi Slackware 15 07-13-2008 10:03 AM
"Input/output error" on files at end of CD mfeat Linux - Software 2 11-23-2005 02:01 PM
problems with smbfs mount-point in /etc/fstab - "mount -a" works, but not at boottime MarkSide Linux - Software 4 11-20-2005 03:30 PM
open office "input/output error" saving to smb share PK2K Linux - Software 6 03-09-2005 01:30 AM
Mandrake 10 "mount smbfs" the win2000 folder from vmware error wuyeguo Mandriva 1 03-19-2004 06:20 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:21 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration