Sometimes late in the day while working with Visual Studio 2010 I start to get this error while building a project. “Error 104 Metadata file ‘bla bla’ could not be opened — ‘Not enough storage is available to process this command. ‘ I clean, rebuild and still get the same error.

The most common fix for this is creating or increasing the IRPStackSize value in the Parameters Key within the LanManServer config. This process requires an edit of your current registry so please do this with caution and create a backup before fiddling around.

The IRPStackSize is a parameter that specifies the number of stack locations in I/O request packets (IRPs) that are used by the operating system. Each stack uses 36 bytes of memory for each receive buffer and you can increase the IRPStackSize, through the Windows registry for some transports, media access control (MAC) drivers, or for file system drivers. The default value of the IRPStackSize parameter is 15. On my Windows 7 PC, for whatever reason, it was set to 10. I set it to 20 and have not had an issue anymore.

To do this follow the steps below:

1. Click on Start > Run > regedit & press Enter
2. Find this key name HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\LanmanServer\Parameters
3. Locate IRPStackSize
4. If this value does not exist Righ Click on Parameters key and Click on New > Dword Value and type in IRPStackSize under the name.
5. The name of the value must be exactly (combination of uppercase and lowercase letters) the same as what I have above.
6. Right Click on the IRPStackSize and click on Modify
7. Select Decimal enter a value higher than 15(Maximum Value is 50 decimal) and Click Ok
8. You can close the registry editor and restart your computer.

What is IRPStackSize

In computer science, specifically the science of operating systems, there are various methods used when dealing with memory. IRPStackSize is parameter specifically used in Microsoft Operating Systems. The IRPStackSize defines the number of stack locations in the input/output (I/O) packets requested by the operating system during software management.

The operating system is the real brain that controls the fast processing central processing unit (CPU). When we are using resources on a personal computer, the central processing unit, does the actual work, but it’s the operating system that does the logical managerial operations to prevent crashes and other issues.

A large portion of the operating system’s tasks deals directly with memory management. Software resources are stored in secondary memory, and RAM is used for actually processing by the central processing unit.

When we are using an application on the computer the central processing unit pulls the resources or software from storage memory and puts it in RAM. RAM is the only memory the central processing unit (CPU) can work. The operating system is constantly managing resources by taking them in and out of RAM.

These memory requests are made by input and output requests, based on predefined algorithms. Memory in the computer is organized in stacks. Stacks are areas in memory, where all the data is located and the operating system uses algorithms to add to and take from these stacks. The operating system uses LIFO (Last In First Out) to manage data requests by the user via the central processing unit.

Last In First Out, is the method the central processing unit inputs memory and pulls it. The Last In First Out process is just as the name suggests. The stacks are stored in ques, and the central processing unit puts (push) stacks on top of each and the last stack, will be the first one pulled out (pop). Stacks are units of memory, and this memory is stored in units of stacks that are only 36 bytes in size. IRStackSize, stands for input/output stack size, and the default parameter is 15.

The IRStackSize is defined in the registry of the operating system and located under the LanManServer. The LanManServer is service in the operating system that can be accessed via the registry. LanManServer is a service within the workstation services part of the client components in the registry.

The registry is a location where data is stored in a tree structure or hierarchical database. The registry contains very important information that is necessary for the operating systems to perform correctly. The data in the registry is grouped in areas called keys. Each of the keys has sub areas with more data, and this data is grouped in what is called keys. There are five types of registry keys: HKEY (local machines), HKCC (current config), HKCR (classes root), HKCU (current user), and HKU (users). In Windows NT only you have and additional registry key, HKEY PERFORMANCE DATA. For Windows 95 to Windows 2000 only, HKEY DYN DATA.

The IRPStackSize error occurs when dealing with resources that require lots of memory, so the central processing unit has to move large amounts of data in and out of RAM and storage memory. The error is telling us the server’s configuration parameter irpstacksize is too small to perform the operation

requested. The issue is the server’s configuration parameter irpstacksize. In order to fix the issue, you have increased the size of the stacks, and this is done by manipulating the registry keys. One of the good things about the Windows operating system, is you have the freedom to manipulate things like the registry keys, however, this is freedom to do so is very dangerous. It’s important to back up the registry before tinkering around with the registry keys.

To back up the registry for Windows 7, 8, 8.1 or 10:

From the start menu, open the search box and type regedit.exe, and hit enter. This opens the registry, then go to File, and select export, select the location you want to save the exported registry file and click save. I would suggest exporting the registry to an external storage location, like a thumb drive.
To restore the registry:

Open the registry editor again, by typing regedit.exe in the search box, and hit enter, select file, then import, browse to the location we save the exported registry too and select it.

 

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.