Moving 8.3 filenames into VFS - WAS Re: meeting with SUGJ

John E. Malmberg malmberg at Encompasserve.org
Thu Jul 19 17:25:05 GMT 2001


On Thu, 19 Jul 2001, Christopher R. Hertel wrote:
> Jerry wrote:
> :
> > Just as a reminder, I'm moving the retreival of 8.3 filename into
> > the VFS.  The setting of short name should be done upon creation or at
> > least handled by the VFS module.
> 
> Yes. yes. yes!  :-)
> 
> It needs to be in the VFS layer because, if it is, then someone can store
> the mangled names in the (VFS) filesystem instead of a tbd database.  (Or 
> perhaps they still use tdb, but it's hidden by the VFS layer.)

If mangled name is stored as an attribute to a file on a file
system and only SAMBA knows about that attribute, how do you make sure
that the mangled name is maintained?

Local operating system utilities that rename or move the file will not
know to update the mangled name.

This can cause many problems, but the most frequent that I would expect
is having multiple files with identical mangled names, or possibly files
with a real name that conflicts with the mangled name of a different file.

The only mangled name that I can associate with a file and know it to be
unique is one based on it's inode.  And that is very user unfriendly!
Of course if base 38 encoding is used on the least signficant 16 bits, it
might be unique enough, and certainly a fast calculation.

Any persistent storage of a mangled name on a host platform that the
operating system does not have built in support for it will have this
problem.

A database like a TDB has the problem where it is not updated by native
host actions on the filesystem.

Storing the mangled name as an attribute on a file will elimate only the
problem with orphaned names.

On host operating systems that support placing additional attributes on a
file, the user supplied ones are treated opaquely, and by default copied
when the file is copied.

If you have a file "foobartry1.txt" with mangled name of "foobar~1.txt",
and a locally logged in user copies it to "foobartry2.txt", the new file
will also have the mangled name of "foobar~1.txt".

> I have heard rumors of people (mainly server platform vendors) working on
> VFS layers to either add feature support or interface with their own
> special-purpose filesystems.  Adding a mangled name mapping to their own
> VFS layer should be easy, particularly if Jerry provides a working
> example.

If it can be done, and overcomes the problems I have listed above, I am
very interested.
 
-John
wb8tyw at qsl.network
Personal Opinion Only





More information about the samba-technical mailing list