Mac OS X bug: Empty folders when browsing Samba shares on Windows 2003 Server

First bug report of 2011, and it’s one for Apple. Here’s the write-up…

I’m using a MBP running OS X 10.6.6 and a Windows 2003 R2 SP2 file server. The Windows 2003 server is in a domain (“neurope”), and my MBP is configured to log on to the AD domain. All working fine (internet access, remote desktop, etc).

If I open a share on the server (Finder > Go > Connect to Server… > smb://server – or the IP address), and provide my domain credentials (domainusername + password), the shared folder appears as it should.

However, on opening a subfolder of that share, the subfolder appears to be empty – despite containing files and folders. Note that I have correct permissions to read and write.

Opening a subfolder that appears empty generates these lines in the log…

08/01/2011 12:11:08 kernel 0 smb_maperr32: no direct map for 32 bit server error (0xc0000279)

08/01/2011 12:11:08 kernel 0 smbfs_smb_lookup: smbfs_smb_qpathinfo error = 5

Browsing the same folder from smbclient at the command line gives the correct results…

ssl-97635efd02b:/ Dave$ smbclient -U domain\username \\server\share

Password: [hidden]

Domain=[domain] OS=[Windows Server 2003 R2 3790 Service Pack 2] Server=[Windows Server 2003 R2 5.2]

smb: > cd users

smb: users> ls David*

  David.Nicoll                        D        0  Thu Jan  6 12:07:32 2011

38399 blocks of size 16777216. 770 blocks available

Browsing from a Windows XP or Windows 7 machine works fine.

I’ve searched around for some answers, and while it seems this is affecting a handful of people (mostly Macs in Windows domains), I’ve not found a workaround. If the situation changes, I’ll post an update here.