How to access MSMQ in C # behind a load balancer (F5)

My problem is that I cannot access the MSMQ hosted on a Windows Server 2012 box, which is behind the F5 load balancer. I am using load balancing in active / passive state to ensure availability.

I can access MSMQ just fine using the server name directly in the connection string, but can't when I use VIP F5.

The following works:

FormatName:DIRECT=OS:<servername>\Private$\myQueueName

      

However, it is not:

FormatName:DIRECT=OS:<F5 VIP>\Private$\myQueueName

      

I also tried to read the message queue using TCP to no avail:

FormatName:DIRECT=TCP:<servername>\Private$\myQueueName

      

+3


source to share


1 answer


There is no MSMQ load balancing. F5 also cannot achieve this for a direct queue to servers. Because MSMQ works with multiple ports for back and forth communication.

You can try the http variant of MSMQ. This can be network balancing and single port communication.



NserviceBus has Nservicebus.Gateway which simplifies this solution. You can also use Nservicebus Distributor to load balance workers. Nservicebus does not recommend using it for load balancing, it is recommended to use it only over wan networks.

Hope it helps.

+1


source







All Articles