POSIX filesystems usually support 255 bytes in filenames.
That means 255 ascii characters or ~85 Japanese/Chinese characters encoded
in UTF-8. Chinese characters take usually 3 bytes, sometimes even 4 bytes.
Win* servers (NTFS) support 255 UTF-16 characters, i.e. 2*255 bytes, which
means 255 ascii characters or 255 Japanese/Chinese characters.
That means Samba effectively supports filenames which are signifficantly
smaller than Win NT servers.
Did anyone think about how to solve this problem? Some other languages
(Greek...) who also have lots of multybyte characters are also affected by
Maybe one could save just a short version of such long files and save the
full version somewhere else? Somewhere else might be extended attributes
or better an external database. Both not very nice but any other, better
A database similar to the one for the 8.3 filenames might help here.
we can't really fix this in 3.0 dur to the proliferation of
static char's. Marking as 'Later"
is this already in cosideration for samba4 now?
This bug also manifests itself when using smbclient to mount a WinXP share on a
linux system, when using the "unicode,codepage=unicode" options. Any filename
on WinXP that is longer than 128 characters will be abruptly truncated when it
is represented on the linux system. When programs on the linux system try to
access the file by it's truncated name, the file system says the file does not
exist. I found this problem when using rsync to backup shares from a WinXP
system to a linux system. I assume that this bug exists because smbclient is
only allocating 256 bytes for the filename, and when multibyte encoding is used
(ie: unicode), you only can encode 128 unicode characters in 256 bytes.... This
effectively means that when using unicode with smbclient, the maximum length of
a filename on a WinXP share that you can access is 127 characters.
I doubt this will get fixed in Samba 3. Wait until Samba 4
has its own category in bugzilla.
originally reported against 3.0.0beta3. CLeaning out
non-production release versions.