[Top] [All Lists]

Re: quick question about filename length

To: xfs@xxxxxxxxxxx
Subject: Re: quick question about filename length
From: Martin Steigerwald <Martin@xxxxxxxxxxxx>
Date: Sat, 16 May 2009 23:42:19 +0200
Cc: Christoph Hellwig <hch@xxxxxxxxxxxxx>, Chris Walker <christopher.walker@xxxxxxxxx>, Eric Sandeen <sandeen@xxxxxxxxxxx>
In-reply-to: <20090516202511.GA28186@xxxxxxxxxxxxx>
References: <554e24be0905160915l49ff901bn41e4332349c555bc@xxxxxxxxxxxxxx> <554e24be0905161106x6a62b7bldc65325ac4102628@xxxxxxxxxxxxxx> <20090516202511.GA28186@xxxxxxxxxxxxx> (sfid-20090516_231832_172988_5C4BCCA0)
User-agent: KMail/1.9.9
Am Samstag 16 Mai 2009 schrieb Christoph Hellwig:
> On Sat, May 16, 2009 at 02:06:22PM -0400, Chris Walker wrote:
> > Thanks for you quick reply, Eric.
> >
> > I have a user who is having filenames (path+filename) cut off at 255
> > characters midway through a simulation -- but the problem must be
> > elsewhere
> XFS doesn't actually see the whole filename in normal operation (except
> for copying out the data out of symbolic links), as the resolution to
> individual components is done by the VFS.   Long file name should work
> just fine on Linux and do in my test.  Maybe some buffer is sized using
> incorrect in userspace?

And while a link name itself also can't be longer than about 256 
characters (I only tested 250 and 260), a link can point to a longer 
path ;-):

martin@shambhala:~/Zeit> mkdir -p 
$(ruby -e 'puts "1234567890"*25')/$(ruby -e 'puts "1234567890"*25')
martin@shambhala:~/Zeit> ln -s 
$(ruby -e 'puts "1234567890"*25')/$(ruby -e 'puts "1234567890"*25') 
martin@shambhala:~/Zeit> ls -l testlink
lrwxrwxrwx 1 martin martin 501 16. Mai 23:40 testlink -> 
martin@shambhala:~/Zeit> (df -hT . | grep -q xfs) && echo "Is XFS"

Martin 'Helios' Steigerwald - http://www.Lichtvoll.de
GPG: 03B0 0D6C 0040 0710 4AFA  B82F 991B EAAC A599 84C7

<Prev in Thread] Current Thread [Next in Thread>