LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Cifs "mount error 5 = Input/output error" but smbfs works! (https://www.linuxquestions.org/questions/linux-networking-3/cifs-mount-error-5-%3D-input-output-error-but-smbfs-works-456897/)

CapnDuck 01-22-2014 08:28 PM

Fixed!
 
Thank you! 'sec=ntlm' fixed my problem as well. Funny that it was working up until yesterday...

Ubuntu 12.04 / Windows 2008 R2

mennojonker 03-16-2014 05:54 PM

This worked for me as well! (sec=ntlm) Just added that after my credentials in my fstab and no more errors! Thanks a lot!!!

Fedora 14 Amahi HDA / Maxtor Shared Storage

VonZippySays 12-29-2014 01:19 PM

Amazzzziing!!!! FIXXED!!!!
 
Quote:

Originally Posted by thewinelake (Post 5042181)
I also had this problem when trying to connect from an Ubuntu 12.04 to an old BreezyBadger server.

The solution in my case was to add an option of "sec=ntlm"

eg: mount -t cifs -o username=user,password=opensesame,sec=ntlm //myserver.com/myshare /mnt/myserver

Just adding it here, as this thread seems to have a high Google weighting!

You have no clue how many forums and guides I went threw that I almost gave up until I figured I would just check different error codes and just so happened to read every response to this forum up until the last one.
sec=ntlm did it for my smb share coming from my Netgear 6300 router.
Thanks a Ton!!

VonZippySays 12-29-2014 01:22 PM

Fixed with sec=ntlm option
 
Quote:

Originally Posted by humbletech99 (Post 2301329)
I can't mount cifs share, but smbfs works fine with same credentials.
Code:

mount -t cifs //hostname/backup /mnt/hostname/backup/
Password:
mount error 5 = Input/output error
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)

The username and password I'm using are correct since I can mount via smbfs this way.

I haven't had much luck on the web, saw some things about matching hostname/ip resolution but my resolution is fine and matching.

Any ideas?

Fixed with sec=ntlm option
---------------------------------
Off Topic
Is there anyways to delete posts ? didn't mean to double post!

Rickkkk 12-30-2014 12:07 AM

Thank You !!!
 
.... another Hallelujah ... sec=ntlm fixed this for me as well. In my case, I had been trying to mount a USB drive attached to my router. This did the trick !

Cheers,

Rick

ryzch 02-19-2015 04:43 PM

Quote:

Originally Posted by Lenard (Post 2301435)
I normally do something along the lines of;

Code:

mount -t cifs //<IP_address_here>/<Share_here> /the/mountpoint -o,user=myusername%mypassword
Example;
mount -t cifs //192.168.1.100/Laserfiche /mnt/Desktop -o,user=lenard%letmein

or (keeping the same example in mind);

Code:

mount -t cifs //192.168.1.100/Laserfiche /mnt/Desktop -o credentials=/path/to/the/credentials.txt_file -rw
Example (cifs) credentials.txt_file;

username=myusername
password=mypassword

Which a little different from the smbfs credentials file format, notice the no spaces for cifs vs smbfs;

Example (smbfs) credentials.txt_file;

username = myusername
password = mypassword

This worked for me 6 years later... thanks amigo!

bsphil 03-06-2015 10:37 AM

FYI, I had this issue as well the last several days and none of the previously mentioned fixes did anything to address the problem. All Linux servers that were already connected to my Windows Server 2008 R2 network share were still fine. All Windows clients were fine. All newly connecting or reconnecting Linux servers would fail, despite having worked for over a year prior.

The solution ended up being a staticly configured DNS server that was recently decomissioned. Note, this was a bad configuration on the Windows Server hosting the share, not the Linux servers. Once I fixed the DNS issue, the old settings worked flawlessly.

tl;dr: Check DNS settings on the server hosting the share!

moodah 06-08-2015 07:04 PM

Quote:

root@lubuntu-ws:~# mount --verbose -t cifs -o username=data,sec=ntlm //10.0.0.107/raid_1 /media/alpha/raid_1
Password for data@//10.0.0.107/raid_1:
mount.cifs kernel mount options: ip=10.0.0.107,unc=\\10.0.0.107\raid_1,sec=ntlm,user=data,pass=********
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
root@lubuntu-ws:~#
root@lubuntu-ws:~# mount --verbose -t cifs -o username=data,sec=ntlm //alpha/raid_1 /media/alpha/raid_1
Password for data@//alpha/raid_1:
mount.cifs kernel mount options: ip=10.0.0.107,unc=\\alpha\raid_1,sec=ntlm,user=data,pass=********
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
None of the mentioned fixes work for me either and I'm still stuck.

I'm connecting to windows 8.1 share that has sharing without passwords enabled, folder sharing to 'everyone' full permissions.
The windows 8.1 local security policy has been changed to allow connections less than 128 bit / no minimum etc.

No combination is working.

flizardman 09-06-2015 08:10 AM

This broke in my 14.04 upgrade
sec=ntlm fixed the issue

amplatfus 04-12-2016 01:03 PM

Mine too also. Thanks for sharing!

squeeze69 10-04-2016 08:15 AM

Hi, my 2 cents.

if you use the "/etc/hosts" (if you don't have a DNS setup) with the server name.

i.e.

192.168.1.2 cifshost

be SURE to have the EXACT name in the table... sigh.

if the host is named: CIFS-HOST-SOMEWHERE
there must be something like this:

192.168.1.2 CIFS-HOST-SOMEWHERE

or else... the error 5 is there for you.

ReinaldoGomes 03-13-2017 08:45 AM

Quote:

Originally Posted by Pastorino (Post 4624110)
Hi everyone,

I know this is a very old thread, but I just had the same problem today, and I found out the reason.

I was trying to mount with CIFS and the result was:

Code:

~]# mount /mnt/backup/
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

and the fstab was:

Code:

//bkpsrv/share    /mnt/backup  cifs    credentials=XXX,uid=YYY 0 0
The whole problem was with the "bkpsrv", because the real hostname is "backupserver", but to shorten commands, I created the entry at /etc/hosts as "bkpsrv".

When I changed /etc/hosts and /etc/fstab to "backupserver", it mounted just fine.

Cheers,

Juliano

I would like to add that in my case this was the issue. The machine's hostname was not the same as its DNS name.

Gaznapiro 06-01-2017 05:59 AM

Solved
 
Adding sec=ntlm problem solved!!!! after upgrade Debian to Jessie
Thank you thewinelake

ckeilah 08-19-2017 05:06 AM

still not working on one share
 
I can mount several shares just fine, but one refuses to mount. They're all using the same settings and permissions on the Mac (El Cap), the same mount command on raspberry pi running jessie. I have to use this command to get a mount to work:

Code:

sudo mount.cifs //<machine.name.or.IP>/drive8 /drive8 -o user=guest,password,nounix,sec=ntlmssp,noperm,noserverino
7 of 9 shares will mount, but two mount points just return this stupid useless error code. :-(

yes, I've turned it ALL off & on again.

ReinaldoGomes 08-21-2017 11:18 AM

Have you tried using the IP instead of the DNS name?


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