当他们到达远程服务器时,MSMQ消息消失 [英] MSMQ messages disappear when they get to remote server

查看:90
本文介绍了当他们到达远程服务器时,MSMQ消息消失的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须在同一域中的两台服务器 SenderServer (MS Server 2012)和 ReceiverServer (MS Server 2008 R2).

I have to create a MSMQ messaging mechanism between two servers in the same domain, SenderServer (MS Server 2012) and ReceiverServer (MS Server 2008 R2).

我在 ReceiverServer .\private$\receiver中创建了一个私有的事务队列,我向系统和管理员授予了接收(和查看)消息的权限.

I created a private, transactional queue in ReceiverServer .\private$\receiver, I gave receive (and peek) message rights to system and administrators.

然后,我创建了一个客户端应用程序,该应用程序使用以下代码创建消息并将消息转发到队列:

I then created a client application that creates and forwards messages to the queue by using the following code:

MessageQueue queue = new queue("FormatName:Direct=OS:ReceiverServer\private$\receiver");
Message message = new Message();
message.Body = "myMessage";

using (MessageQueueTransaction tx = new MessageQueueTransaction())
{
  tx.Begin();
  queue.Send(message, "myLabel", tx);
  tx.Commit();
}

在部署该应用程序之前,我已经在我的计算机(Windows 7)上对其进行了测试,该计算机正确创建了带有State:ConnectedConnection History:Connection is ready to transfer messages的传出队列Direct=OS:ReceiverServer\private$\receiver. 邮件已正确发送到 ReceiverServer 并放置在队列中.每个消息的 ReceiverServer End2End log记录两个事件:

Before deploying the application, I tested it from my machine (Windows 7) that correctly creates an outgoing queue Direct=OS:ReceiverServer\private$\receiver with State:Connected and Connection History:Connection is ready to transfer messages. The messages are correctly sent to the ReceiverServer and placed in the \private$\receiver queue. The End2End log of the ReceiverServer for every message logs two events:

  1. 消息通过网络发送(事件ID:4)
  2. 带有ID CN=msmq, CN=[mymachinename], CN=Computers, DC=[domain], DC=[other]的消息被放入队列ReceiverServer\private$\receiver(EventId:1)
  1. Message came over network (EventId: 4)
  2. Message with ID CN=msmq, CN=[mymachinename], CN=Computers, DC=[domain], DC=[other] was put into queue ReceiverServer\private$\receiver (EventId: 1)

然后,我使用相同的代码从 SenderServer 中使用了客户端应用程序.服务器使用State:ConnectedConnection History:Connection is ready to transfer messages正确创建了传出队列Direct=OS:ReceiverServer\private$\receiver,我可以看到消息正在排队并被发送,但是在远程 ReceiverServer 队列.\private$\receiver中没有收到消息.如果我查看 ReceiverServer End2End事件日志,我只会看到第一条消息(消息来自网络(事件ID:4)),但该消息未放入队列中

Then I used the client application from within the SenderServer using the same code. The server correctly creates an outgoing queue Direct=OS:ReceiverServer\private$\receiver with State:Connected and Connection History:Connection is ready to transfer messages, I can see the message queuing up and be sent but I do not receive them in the remote ReceiverServer queue .\private$\receiver. If I check the End2End event log of the ReceiverServer I just see the first message (Message came over network (EventId: 4)) but the message is not placed in the queue.

我关闭了两台计算机的防火墙,更改了队列的授权设置,并尝试了以下队列端点:

I turned off firewalls from both machines, changed the authorization settings for the queue and tried the following endpoint for the queues:

  • FormatName:Direct=OS:[IPv6 address]\private$\receiver
  • FormatName:Direct=TCP:ReceiverServer\private$\receiver
  • FormatName:Direct=TCP:[IPv6 address]\private$\receiver
  • FormatName:Direct=OS:[IPv6 address]\private$\receiver
  • FormatName:Direct=TCP:ReceiverServer\private$\receiver
  • FormatName:Direct=TCP:[IPv6 address]\private$\receiver

没有运气. Microsoft的故障排除过程和文档确实是通用且简单的,因此我决定在这里询问,因为对我而言这是一个死胡同.

With no luck. The troubleshooting process and the documentation from Microsoft are really general and simplistic, therefore I decided to ask here because for me is a dead end.

推荐答案

发件人域帐户需要对远程队列具有以下权限:发送,获取权限,获取属性

The sender domain account needs to have the following permissions on the remote queue: Send, Get Permissions, Get Properties

这些计算机是否在同一域中?否则,您可能需要将上述权限授予本地用户ANONYMOUS LOGON

Are these machines on the same domain? If not you may need to grant the above permissions to the local user called ANONYMOUS LOGON

这篇关于当他们到达远程服务器时,MSMQ消息消失的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆