Exchange 2010 Queues export, resubmit messages

This post is also available in: Polish

Sometimes in your Microsoft Exchange environment you can experience a problem with HUB or Edge Transport servers, when often messages stuck in Queues.

When you resolve problem with any Exchange server, sometimes it takes few minutes for Exchange to resubmit all emails, time depends on how many messages are in queues.

Until messages have one of the below status, we can manually resubmit them to the Exchange Submission Queue if queue hasn’t Suspended state:

  • mailbox Delivery queues or Remote delivery queues with status Retry
  • emails in Unreachable queue
  • emails in Poison queue


To manually resubmit messages in queues, you can use the following methods:

  • use the Retry-Queue cmdlet with parameter -Resubmit
  • export messages from queue to .eml message files and resubmit them by placing in the Replay directory. For Exchange 2010 default location:
    C:\Program Files\Microsoft\Exchange Server\V14\TransportRoles\Replay
  • open Queue Viewer or Resume-Message cmdlet to resubmit messages in poison message queue.


Exchange 2010 export message copy from Queue:


To export message from queue to .eml file you can use cmdlet Export-Message. After this operation you can put .eml file in to Exchange 2010 Replay Directory .


Below example will export message from queue with InternalMessageID 1234. Queue is located in ExHub01 transport server:

Export-Message ExHub01\\1234 -Path "d:\message_export\msg.eml"


If you want to export all messages from queue and move them to other Exchange 2010 Hub Transport server you can use below example:

$array = @(Get-Message -Queue "QueueName" -ResultSize unlimited)
$array | ForEach-Object {$i++; Export-Message $_.Identity | AssembleMessage -Path ("c:\Export_messages\"+ $i +".eml")}


After this operations we have all messages exported to directory C:\Export_messages, now we can move them to next Hub Transport server to Transport Pickup directory (default location for Exchange 2010: C:\Program Files\Microsoft\Exchange Server\V14\TransportRoles\Pickup). More informations about Exchange 2010 Transport Pickup Directory


Exchange 2010 resubmit all messages in delivery queue:

Below example will resubmit all messages in Exchange delivery queue 74536 of the ExHub01:

Retry-Queue “ExHub01\74536” -Resubmit $True


to resubmit all messages in all delivery queues  with statsu Retry on server ExHub01 use:

Retry-Queue –Server “ExHub01” -Filter {Status -eq "Retry"} -Resubmit $True


Resubmit all messages in the Unreachable queue use:

Retry-Queue “ExHub01\Unreachable” -Resubmit $True


To force retry for all queues with messages for specified domain ( and have status Retry use:

Retry-Queue –Server “ExHub01” -Filter {NextHopDomain -eq “” -and Status -eq “Retry”}


Exchange 2010 Poison Queues:

To resubmit all messages in Poison Queues, you can’t use Retry-Queue with -Resubmit parameter.

Before you will resubmit those messages, you should review them because those messages can be dangerous for Exchange system and can couse server failure. They can cause Exchange server crash while processing them.

When you are sure that those messages are safe use Exchange Management Console to resume messages in Poison Queue:

Open Queue Viewer, click Queues Tab, select Poison Queue and select View Messages, next select messages from the list, right-click and select Resume.


Print Friendly
Tagged , , , , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>