Archive for Outlook

Finding messages stuck in outboxes

Sometimes you encounter problems with the transport queues or with mailflow that are difficult to track down. Maybe your mail.queue file is ballooning in size even though you’ve replaced it with a fresh one. Maybe outbound mail isn’t going out as quickly as it used to.

One diagnostic in this situation is to determine whether any of the mailboxes have messages sitting in the Outbox. Sometimes large messages in the outbox can create loops if they are too large but you’ve removed all max-send-size limits. Sometimes the message in the Outbox is corrupted and is continually resubmitted to queuing.

The following script will look at all the mailboxes for messages in the Outbox and will compile a report of the mailboxes with items in their outboxes. Once you have the report, you can look at certain mailboxes with OWA and delete any problem items you find.

Get-Mailbox -ResultSize Unlimited | Get-MailboxFolderStatistics | Where-Object {$_.Name -eq "Outbox" -and $_.ItemsInFolder -gt '0' } | Select-Object Identity, FolderType, ItemsinFolder, FolderSize | Export-CSV "C:\Outbox.csv"

Outlook 2013 Import NK2 file

This one isn’t PowerShell related, but it’s a common enough issue relating to Exchange that I wanted to post it anyway.

There are many posts showing up in a Google search that incorrectly report the path that Outlook looks at to import the NK2 file from.  The correct path is:


Once you move the NK2 file from the old machine to the new machine, from the run window (start -> run or Windows key + R) type in “outlook.exe /importnk2″ without the quotes and it will import the file and rename it to .old