Samba doesn't manage well long share name

Peter Samuelson peter at
Sat Feb 5 09:26:40 GMT 2000

  [note: the lists replace To: line and delete CC: line]
  [so if replying from there, please manually set:]
  [  CC: 56711 at, gautier at  ]

> When you give a share a name longer than 14 chars, it is impossible
> to connect to this share.  For the client the ShareName is cut at 14
> but it seems that when it tries to connect the server doesn't know
> the short-cut name.

I think this is caused by implementing the old Windows sharing protocol
as opposed to one of the NT protocols.  As such it is most likely fixed
in the latest development versions of Samba.  (Not that these should be
Debian-packaged yet!)

The easy "fix" is really in testparm.  Patch appended.  You *do* always
run testparm after editing smb.conf, right?  (:

> This is important because it is not easy to detect, but i think the
> bug can be downgraded to normal if there is no easy fix (at least
> there is a workaround: don't use long names!)

I say: apply the following patch and downgrade bug to `wishlist'.


Index: source/utils/testparm.c
RCS file: /cvsroot/samba/source/utils/testparm.c,v
retrieving revision
diff -u -r1.22.2.12 testparm.c
--- testparm.c	1999/10/08 01:37:09
+++ testparm.c	2000/02/05 09:18:26
@@ -239,6 +239,10 @@
         printf("WARNING: You have some share names that are longer than 8 chars\n");
         printf("These may give errors while browsing or may not be accessible\nto some older clients\n");
+      } else if (strlen(lp_servicename(s)) > 14) {
+        printf("WARNING: You have some share names that are longer than 14 chars\n");
+        printf("These may not be accessible to some clients\n");
+        break;

More information about the samba mailing list