[TriLUG] CIFS: 'file name too long' on a file name that is not long

Brian via TriLUG trilug at trilug.org
Thu Oct 26 14:00:30 EDT 2017


I wouldn't know if this is what's going on in your case, but Windows has 
a maximum total path length as well as a maximum filename length; the 
former can easily be exceeded by deep folder structures if the folders 
also have long-ish names.

Depending on whether the accessing process is using ANSI or Unicode 
strings, that maximum length can be as short as 260 characters.

Dunno if that's apropos for your situation...

-B


On 10/26/2017 01:36 PM, Jack Hill via TriLUG wrote:
> Ahoy TriLUG:
>
> I have run across a strange behavior with my Debian Stretch CIFS client.
> For the past few weeks (I don't know what changed), I've been getting
> 'file name too long' while trying to read files. I also can't create new
> files, although I can modify existing ones. Here is an example session:
>
> jackhill at repository-ingest-01:~$ file .bash_profile
> .bash_profile: cannot open `.bash_profile' (File name too long)
> jackhill at repository-ingest-01:~$ file .bashrc
> .bashrc: ASCII text
> jackhill at repository-ingest-01:~$ file functional-review-matrix.txt
> functional-review-matrix.txt: ASCII text, with no line terminators
>
> The CIFS volume is mounted by autofs using sec=krb5
>
> jackhill at repository-ingest-01:~$ findmnt|grep winhomes
> └─/winhomes                           /etc/auto.winhomes autofs
> rw,relatime,fd=12,pgrp=560,timeout=300,minproto=5,maxproto=5,indirect,pipe_ino=15846
>
>    └─/winhomes/jackhill
> //homedir.win.duke.edu/users/j/jackhill[/j/jackhill] cifs
> rw,relatime,vers=3.0,sec=krb5,cache=strict,multiuser,uid=0,noforceuid,gid=0,noforcegid,addr=152.3.99.22,file_mode=0755,dir_>mode=0755,nounix,serverino,mapposix,mfsymlinks,noperm,rsize=1048576,wsize=1048576,echo_interval=60,actimeo=1
>
>
> Interestingly, if I mount it by hand using sec=ntlmv2 and type in my
> password everything works correctly.
>
> If I enable debug messages per
> <https://wiki.samba.org/index.php/LinuxCIFS_troubleshooting>, I see the
> following messages:
>
> [ 2396.965524] Status code returned 0xc00000bb STATUS_NOT_SUPPORTED
> [ 2396.969129] Status code returned 0xc0000003 STATUS_INVALID_INFO_CLASS
>
> I see the same or similar problem on multiple different fileservers.
>
> Has anyone seen this before, know what might be wrong, or know what I
> should try next?
>
> Thanks,
> Jack



More information about the TriLUG mailing list