MSMQ Messages Are Stuck In The Outgoing Queue

Viewed 33131

Although my question looks similar to some already found on SO, those post did not help me, so here it is:

Given:

  • Two machines on the same segment (naturally in the same domain, actually on the same desk)
  • Both machines are Windows 7 workstations
  • Both machines have disabled firewall
  • Both machines see each other (ping works)
  • There is a private non transactional message queue test on one of them.
  • The sender machine has HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSMQ\SimpleClient\@BinaryEnabled = 'Yes'
  • The queue owner sends a message from another machine
  • The message is stuck on the outgoing queue, never reaching the target.
  • When sent from the same machine (i.e. locally) the message arrives OK.

The message is sent using the following code:

var q = new MessageQueue(@"FormatName:Direct=OS:il-mark-lap\private$\test");
q.Send(string.Format("Test message sent at {0} from {1}", DateTime.Now, Environment.MachineName));

Where il-mark-lap is the address of the machine with the queue.

What on earth do I have to do to make the thing work?

Thanks a lot.

7 Answers

If a server suddenly refuses to receive messages (causing another server to have messages queue in the Outgoing queue), this may be because of the Journal messages size limit.

MSMQ will silently refuse messages if the server's journal queue backlog exceeds 1GB in size. This can be validated by looking at C:\Windows\System32\MSMQ\ and its subdirectories.

When journal queue messages are removed and the size no longer exceeds 1GB, it should immediately begin accepting messages again (without necessitating restarting the Message Queuing service).

Related