When this problem occurs, the following information may appear in the stack trace of a Microsoft .NET Framework service or application:
Message: Insufficient resources to perform operation.
TargetSite: Void SendInternal(System.Object, System.Messaging.MessageQueueTransaction, System.Messaging.MessageQueueTransactionType)
- You try to send a message in Message Queuing.
- The allocated memory that is currently being used to run the service and to store messages has reached 2 gigabytes (GB). By default, Microsoft Windows 2000 allocates 2 GB of addressable memory to a process.
After the Message Queuing service loads, the default amount of allocated memory that is available to Message Queuing 2.0 to store messages is between 1.6 GB and 1.8 GB.
Note If you use the 3GB switch, the allocated memory will be between 2 GB and 2.5 GB.
Message storage files are memory-mapped files. Therefore, you can see whether the limit has been exceeded by checking the size of the MSMQ Storage folder. This folder is typically located in the %WinDir%\System32\MSMQ Storage folder. However, the storage folder can be configured for another location. To see whether the storage folder has been configured for another location, look in the Message Files Folder field on
Storage tab in the MSMQ tool in Control Panel.
- The application that reads and processes the messages that arrive in the queues is experiencing difficulties. However, messages continue to arrive in the queues at a faster rate than the rate at which the application can read and process the messages.
- Journaling is enabled in the queues. However, the data that causes messages to accumulate has not been deleted.
- Deadlettering is enabled in the queues. Additionally, the amount of allocated memory that is available to store deadlettered messages has been reached or exceeded.
- Messages have accumulated in the outgoing queue because the destination queue is unavailable.
If Message Queuing is runningDetermine which queues have accumulated messages. To do this, use one of the following methods:
- Manually examine the queues by using the Message Queuing interface. The Message Queuing interface is located in the Computer Management console.
- In Performance Monitor, set all the counters on the MSMQ QUEUE performance object. Then, select Report view. In
Report view, you can see the number of messages in each queue.
- The messages that are in the outgoing message queue cannot reach their destinations. If the messages cannot reach their destinations, make sure that the destination computer is available to receive messages. If these messages are outdated or have no value, clear the queue.
- The application that should be receiving messages has stopped or has entered an error condition. If one of these conditions is true, resolve the problem in that application.
- The messages in the dead letter queues or in the journal queues have been retained. These messages have not been removed or processed. If these messages have been retained, determine the purpose for retaining these messages. The option to journal messages is frequently used for testing. When testing is completed, this option may be unintentionally left enabled. If the messages are deadlettered, the messages have not been processed or delivered within a specified time. If deadlettering or journaling is turned on, a process should be reading these messages out of the queue.
If Message Queuing is not running and you cannot manually start itNote Before you make any changes to the files in the MSMQ Storage folder, we recommend that you back up the current Message Queuing environment by using MQbkup.exe. This step is very important if you need help from Product Support Services.
Note Because Message Queuing has entered an unstable state, you may not be able to recover all the messages. If you experience difficulties restoring messages by using the following steps, and the data is very important, contact Product Support Services for help.
To back up the Message Queuing configuration by using MQbkup.exe, follow these steps.
Note Before you run MQbkup.exe, select a folder to which you will back up the Message Queuing files. This folder must be located on a disk that has at least 2.5 GB of available space.
- Open a Command Prompt window.
- Change the directory to %WinDir%\System32.
- Run the following command: MQbkup.exe -b Drive:\Folder to Put Backup Files
- Note the location of the folder to which you backed up the Message Queuing files.
Start the server by using the 3GB switchNote The 3GB switch is only an option for Microsoft Windows 2000 Advanced Server. For Microsoft Windows 2000 Server and for Microsoft Windows 2000 Professional, go to the "To manually recover your messages" section.
By default, Windows 2000 allocates 2 GB of addressable memory to each process. This problem occurs because Message Queuing uses the whole allocation. This behavior prevents the service from correctly restarting. If you use the 3GB switch, Windows 2000 Advanced Server allocates 3 GB of addressable memory to each process. This configuration gives Message Queuing sufficient addressable memory to load the service and the message storage files after you restart the server. This switch increases Message Queuing storage to between 2 GB and 2.5 GB.
Warning This configuration may affect other resources on the server. We recommend that you remove the 3GB switch after you have completed troubleshooting. This configuration is not intended to permanently resolve the problem. However, you can use this configuration to access Message Queuing so that you can perform the steps in the "If Message Queuing is running" section.
For information about how to configure Windows to run by using the 3GB switch, see the "Enabling application memory tuning support in your applications" topic in the Windows 2000 Help file.
To manually recover your messagesNote Follow these steps only if Message Queuing is in a non-running state.
Important Because Message Queuing is in an unstable state and will not start, you may not be able to recover all the messages.
Warning This process may cause an application to receive transactional messages in a different order from the order in which the messages originally arrived.
- Create a temporary folder to hold your message storage files. Do not put this folder in the MSMQ folder.
- Select only the files that have the .mq file name extension.
Warning Some files that are located in the MSMQ Storage folder are critical for Message Queuing to correctly run. Make sure that you select only the files that have the .mq file name extension.
- Move the selected files to the folder that you created in step 1.
- Make sure that the Message Queuing Data Access Driver is not started. To do this, run the following command at a command prompt: Net Stop MQAC /y
- Start the Message Queuing service. To do this, run the following command at the command prompt: Net Start MSMQNote If the data in the messages is not important, and you only want to bring Message Queuing back online, you can stop here.
- After you have verified that the service will now start, stop the service. To do this, run the following command at the command prompt: Net Stop MQAC /yThis command stops both the Message Queuing service and the Data Access driver.
- In the folder to which you moved the message storage files in step 5, notice that some file names have a pNumber.mq format and some file names have an lNumber.mq format. These files are stored as pairs. Each p file has a corresponding l file.
Notice the dates that the files were modified. Select the oldest p file and the corresponding l file. Move these files to the original MSMQ Storage folder.
- Run the command in step 5 to start the Message Queuing service. If the service starts, follow the steps in the "If Message Queuing is running" section to determine in which queues the messages are accumulating and how to handle the messages.
- After you have removed the accumulating messages from the queues, repeat steps 6 through 8 until you have returned all message files to the MSMQ Storage folder and you have removed all accumulating messages from the queues.
Note Do not move more than 1.6 GB of data back into the MSMQ Storage folder at the same time. If you do this, the service may not start.
Steps to reproduce the problemOn a computer that is running Microsoft Windows 2000 Server, send messages to a local queue until the application that you are using to send the messages receives a 0x00e0027 exception error.
Message Queuing 2.0 stores messages in memory-mapped files. On a computer that is running Windows 2000 Server, the default amount of allocated memory that is available to Message Queuing 2.0 is 2 GB. After the components of Message Queuing 2.0 are loaded onto the computer, the amount of allocated memory that is available to Message Queuing 2.0 is reduced to between approximately 1.6 GB and 1.8 GB.
If you enable the 3GB switch in the Boot.ini file, the amount of allocated memory that is available to Message Queuing 2.0 increases to 3 GB. After the components of Message Queuing 2.0 are loaded onto the computer, the amount of allocated memory that is available to Message Queuing 2.0 is reduced to 2.7 GB.
However, the additional allocated memory also takes approximately 1 GB of allocated memory from the kernel. This behavior may affect system performance and may affect applications that perform file I/O.
We do not recommend that you use the 3GB switch only to increase the amount of allocated memory that is available to Message Queuing 2.0. Instead, we recommend that you set up a computer quota to prevent the problem that is mentioned in the "Symptoms" section.
For more information, click the following article number to view the article in the Microsoft Knowledge Base:
ID do Artigo: 899613 - Última Revisão: 20 de jun de 2014 - Revisão: 1