Page 1 of 1

cifs mount problems

Posted: Tue Jan 07, 2020 6:31 pm
by scimmiettarossa
hi everyone
I have a very strange problem:
in my fstab there are a number of lines referring to smb servers, all with the same structure:

Code: Select all

//192.168.1.2/data2 /mntpoint2 cifs vers=2.0,noauto,credentials=/etc/.xxx,uid=1000,user 0 0
//192.168.1.3/data3 /mntpoint3 cifs vers=2.0,noauto,credentials=/etc/.xxx,uid=1000,user 0 0
//192.168.1.4/data4 /mntpoint4 cifs vers=2.0,noauto,credentials=/etc/.xxx,uid=1000,user 0 0
....
everything is working correctly: no one is automatically mounted at boot ("noauto" option), and everyone is mounted if I run mount with the "source" syntax:

Code: Select all

mount //192.168.1.2/data2
.. or with the "target" syntax:

Code: Select all

mount /mntpoint2

this is true for all the shares...except for one of them, where:

Code: Select all

 mount /mntpoint4 
is working... while:

Code: Select all

mount //192.168.1.4/data4
IS NOT WORKING and gives the following output:

Code: Select all

mount: //192.168.1.4/data4: No such file or directory 
if I mount it explicitly (i.e. with the "full syntax", without relying to fstab content), with:

Code: Select all

mount //192.168.1.4/data4 /mntpoint4 cifs vers=2.0,noauto,credentials=/etc/.xxx,uid=1000,user
, it works as well

It seems that, just for this share, the implicit "source" syntax ("mount <source>") fails, while the other syntaxes are working (both the "explicit" one and the "target" one)

I've tried almost everything found on the internet... no success

any idea?
thanks
rosanna

Re: cifs mount problems

Posted: Tue Jan 07, 2020 7:14 pm
by rene
I don't believe we'll be able to diagnose this from your report, given that it seems this would most likely involve a typo or e.g. non-printing character in /etc/fstab which we are not seeing. I'd suggest making sure from e.g. xxd /etc/fstab that everything looks alright also at the byte level but that's about it. Also; is the "not working" immediate or does it involve a timeout?

Re: cifs mount problems

Posted: Wed Jan 08, 2020 2:38 pm
by scimmiettarossa
updates:
  • I have double (triple) checked the syntax in fstab, even deleting the row at all and rewriting a couple of times, even copying and pasting the text from the (successful) command from the CLI... no luck
  • the fstab line MUST be correct, otherwise it should not work both with the implicit "mount --source <address>" syntax and the implicit "mount --target <address>" syntax... while in reality the "mount --target <address>" WORKS!!!
  • the other lines, related to other servers, have no problem
It seems to me that there is something strange/different in the smb server configuration on server 4, with respect of the same configuration on the other servers.. but I do not understand what.. "testparm" mgives no hints, /etc/samba/smb.conf are absolutely equivalent, same users etc

samba version on server 2: 3.6.3-31a.osstech : no issue
samba version on server 3: 4.4.16 Synology build : no issue
samba version on server 4: 4.2.14-Debian : the one with the problem



for the moment I bypassed the problem by invoking the mount with the --target syntax... but I would really like to understand what's wrong

Re: cifs mount problems

Posted: Fri Jan 24, 2020 8:21 am
by johnsageek
Have you tried disabling the firewall? I'm a new guy, but most of the issues with the smb config has to do with the firewall rules. Just my 2 cents worth. :)

Re: cifs mount problems

Posted: Sat Jan 25, 2020 9:57 am
by scimmiettarossa
Yes, I did... no luck :(