When you send a message to a queue, Microsoft Message
Queuing does not accept the message that you are sending. Instead, Message
Queuing generates an "insufficient resources" error message. You receive this
error message in the application that is using Microsoft Message Queuing 2.0 to
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
Additionally, the following message is logged in the
MQ_ERROR_INSUFFICIENT_RESOURCES There are insufficient resources to perform the
Event ID: 2085
Description: Unable to create
message file C:\WINNT\System32\msmq\STORAGE\l0000009.mq. There is insufficient
disk space or memory.
In a Microsoft COM+ Queued Component (QC)
application, the following message may be logged in the Application
Event Type: Error
Event Source: COM+
Category: QC Recorder
Event ID: 4216
Description: An unexpected error
was returned by the MSMQ API function indicated. The following error message
was retrieved from MSMQ.
MQSendMessage: There are insufficient resources to
perform the operation.
Server Application ID:
Server Application Name: Logger
Error Code = 0xc00e0027
COM+ Services Internals Information:
.\channelmanager.cpp, Line: 366
This issue occurs when the following
conditions are true:
- 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
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
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.
This problem occurs for one or more of the following
- 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.
The method that you use to resolve this problem depends on
the current status of the Message Queuing service. Before you can resolve this
problem, you must stop the services or applications that are writing to the
If Message Queuing is running
Determine 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
- 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
After you have determined which queues have accumulated
messages, you must determine why the messages have accumulated. There are
several possible reasons why messages might accumulate in the queues. These
reasons include the following:
- 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.
When you have identified the queues where messages have
accumulated, you can delete the accumulated messages.
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
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
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
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"
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.
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
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
- 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
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
- 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
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 problem
On 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
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
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.
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"
For more information,
click the following article number to view the article in the Microsoft
How to set up computer quotas and queue quotas in Microsoft Message Queuing
For more information about the Message Queuing resource,
visit the following Microsoft Web site:
Article ID: 899613 - Last Review: February 17, 2006 - Revision: 4.0
- Microsoft Message Queue Server 2.0