Bug 125247

Summary: 'smbclient -L' not listing long-share-names
Product: Red Hat Enterprise Linux 3 Reporter: Stuat J. Browne <stuart>
Component: sambaAssignee: Simo Sorce <ssorce>
Status: CLOSED WONTFIX QA Contact: David Lawrence <dkl>
Severity: low Docs Contact:
Priority: medium    
Version: 3.0CC: matseitz, samba-bugs-list
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-10-19 19:24:51 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Stuat J. Browne 2004-06-04 02:07:29 UTC
Description of problem:

Setting up a share with a name longer than 12 characters does not 
show up, or shows a truncated name, when listing shares using 
the 'smbclient -L <machinename>' command.

Samba can successfully create such a long share, and smbclient can 
successfully connect to a long-named share, but it cannot list them.

Version-Release number of selected component (if applicable):

samba-client-3.0.2-6.3E

How reproducible:

Every Time

Steps to Reproduce:

1.  Create a share with longer-than-12-characters in it's name on a 
Win 2K/XP machine.
1(alt). Create a share with longer-than-12-characters in it's name on 
a Samba server.
2.  Run the command: 'smbclient -N -L <machinename>', or 'smbclient -
L <machinename> -U <user>%<pass>'
    
  
Actual results:

Created a share on my local Windows XP machine 
called 'AReallyLongShareNameGoesHere', and successfully able to view 
and use the share from Windows.  Also able to *use* the share from 
smbclient.

Executing the command:

smbclient -N -L STUART

lists all available shares except the one listed above.

Output was:

[root@notes samba-3.0.2]# smbclient -N -L STUART
Domain=[STUART] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]

        Sharename      Type      Comment
        ---------      ----      -------
        PUBLIC         Disk      Documents 'n stuff - Backup
        rlj_stu        Printer   RLP Test
        IPC$           IPC       Remote IPC
        Documents      Disk      Documents 'Stuart' - backup
        print$         Disk      Printer Drivers
        CDROM          Disk      
        stuff          Disk      
        ADMIN$         Disk      Remote Admin
        C$             Disk      Default share
Domain=[STUART] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]

        Server               Comment
        ---------            -------

        Workgroup            Master
        ---------            -------
[root@notes samba-3.0.2]#

When creating a share on a Samba server, the output is as follows 
(showing a truncated share-name):

[root@notes samba-3.0.2]# smbclient -N -L localhost
Anonymous login successful
Domain=[PROMED] OS=[Unix] Server=[Samba 3.0.2-6.3E]

        Sharename      Type      Comment
        ---------      ----      -------
        netlogon       Disk      Network Logon Service
        bluesky        Disk      
        media          Disk      File Dump of different media
        publications   Disk      Pro medicus Publications
        development    Disk      Development Share
        myob           Disk      MYOB Data store
        due            Disk      Due Dilligence Share
        hpjetsuite     Disk      HP JetSuite Phonebook data
        quotes         Disk      Client Quotes
        mks            Disk      MKS Tool Kit/Sandboxes
        tech           Disk      Pro Medicus Tech Intranet
        cygwin         Disk      CygWin: Windows based Unix 
environment
        cdimages       Disk      CD Images stored on Notes
        AReallyLongSh  Disk      smb test
        IPC$           IPC       IPC Service (Pro Medicus File Server 
(Samba))
        ADMIN$         IPC       IPC Service (Pro Medicus File Server 
(Samba))
Anonymous login successful
Domain=[PROMED] OS=[Unix] Server=[Samba 3.0.2-6.3E]

        Server               Comment
        ---------            -------

Expected results:

In previous builds of Samba (2.2.6) these long shares were listed 
correctly.

Additional info:

We 'smbclient' to list shares on given user PC's in order to do minor 
backups of local data.  In older releases of samba, this all worked 
ok.

Upon upgrading our server to RHES3, and thus RH3, this functionality 
has been reduced, forcing us to re-name a number of user shares to 
shorter names.

Comment 1 Matt Seitz 2004-11-18 21:53:24 UTC
This is a known Samba bug, with a known workaround:

https://bugzilla.samba.org/show_bug.cgi?id=1629

Comment 2 Stuat J. Browne 2004-11-18 22:03:25 UTC
Actually as the 2nd post there lists, it's only a partial fix.  There 
is still issues using the 'net rpc share -S <machine>' method.

Comment 3 RHEL Program Management 2007-10-19 19:24:51 UTC
This bug is filed against RHEL 3, which is in maintenance phase.
During the maintenance phase, only security errata and select mission
critical bug fixes will be released for enterprise products. Since
this bug does not meet that criteria, it is now being closed.
 
For more information of the RHEL errata support policy, please visit:
http://www.redhat.com/security/updates/errata/
 
If you feel this bug is indeed mission critical, please contact your
support representative. You may be asked to provide detailed
information on how this bug is affecting you.