OS X and smb mount failure (error code -41)

Thursday, 23. November 2006

I’ve suddenly started having an issue with a couple of shares on a Windows XP Pro machine and being able to mount them with the Mac. I’ve been actively using these shares for well over a year in exactly the same fashion and it just kind of stopped, I have no idea if there’s any action performed that would have caused this.

Basically, what I got from my Mac when I attempted to mount one of these problematic share is a “connecting to server sorry the operation could not be completed because an unexpected error occurred (error code -41)”. When attempting to mount the share via command line the process hung. In searching I found the following error on my XP machine Event Logs.

Product: Windows Operating System
Event ID: 2011
Source: Srv
Version: 5.2
Symbolic Name: EVENT_SRV_IRP_STACK_SIZE
Message: The server’s configuration parameter “irpstacksize” is too small for the server to use a local device. Please increase the value of this parameter.

The times seemed to match my mount attempts. Recall that this only occured on some of my shares, two out of 10+ on the machine. Further research gave the following from Microsoft.

Explanation
The server is configured with too many file system filter drivers (for example, Quota and anti-virus) and/or too many devices, or the irpstacksize parameter is set to less than the default of 15 stack frames. The irpstacksize represents the number of kernel modules that can store information in the input/output (I/O) Request Packet (IRP). The IRP is used to track I/O requests in the kernel.

User Action
The irpstacksize parameter can be increased by changing the registry value.

To change the registry value

Using Regedit, open the following registry key:
HKLM\System\CurrentControlSet\Services\LanmanServer\Parameters\IRPStackSize
In the Value data box, type 15.

I didn’t have this key so I created it. Microsoft recommended increasing the binary value of this key by a value of 5 until the error stopped. Not wanting to waste time I set an initial value of 20, restarted the Server service and was immediately able to mount my problematic shares.

wtf? I certainly don’t get…

Post to Twitter

Tags: .

5 Responses to “OS X and smb mount failure (error code -41)”



  1. Alistair Chatwin Says:

    You have a small Syntax error. The vaue is a DWORD and it needs to be case sensitive “IRPStackSize”. Other than that you nailed the issue. There are so many people out their with bullshit fixes for the problem and yours is the only one that actually worked. There is a Microsoft Knowledge base entry that gets the syntax right http://support.microsoft.com/kb/285089/

    Once again thanks for the help.



  2. Fred Says:

    Thanks a lot!
    The same as u SMB had worked for years and suddenly i got the same Error-41.
    I had spent hours on that trying to connect from Tiger to Windows XP Home.

    This solution really worked imediately!



  3. timo Says:

    Syntax error (registry key cast) acknowledged and corrected! Thanks to Alistair.



  4. prog Says:

    Works on Vista!



  5. ClearlyPro Says:

    When I tried to log on to ours pc, a message saying “there are not sufficient resources to load” my account with the default something-or-other popped up. The message had a timer that was going to close the message, and then when it closed it would not log me on. I couldn’t turn it off normally so I cut the power. When I turned it back on I logged on fine?
    I read here Windows Error but couldnt make sense?

     

Leave a Reply

 
Theme Tweaker by Unreal