CRLF / LF conversion, all over again
i.viarheichyk at sam-solutions.net
Thu Feb 21 04:03:01 GMT 2002
On Thu, Feb 21, 2002 at 11:56:51AM +0100, Timothee Besset wrote:
> - file size? not a problem, if the client is win32 it is served with CRLF
> converted files from the unix server, and sees the correct size
This will require to read all the file to get it's size. Not a problem,
if not trying to get listing of directory containing hundreds files.
> - 5k at the end of 600Mb file .. text files are typically small. Odds are,
> if it's 600Mb, it's binary. (at least in my case I don't have text files
> that go above 100kb).
Ok. Let it be 100k. Reading 5k an the end on 100k file requires to read
all 100k. Notice that there is no difference between binary and text
files for many programs, e.g. text editor can read text file by 4k
binary blocks. Imagine how slower will be reading of a file in this
> What do you mean by 'write a VFS module'? My understanding is that if the
> server does CRLF conversion, obviously it will have to cache the CRLF and
> LF versions, and synchronise when one of the clients changes something (as
> I said, I know nothing the precise problems in smbd).
You can write own extension, caled VFS module, which will read file as
you want and where you want.
More information about the samba-technical