Ibm mq 无法将应用程序连接到队列管理器获取错误JMSWMQ2013

Ibm mq 无法将应用程序连接到队列管理器获取错误JMSWMQ2013,ibm-mq,Ibm Mq,我们使用的是websphere MQ版本9.0.0.1,基本上我们已经在linux机器上配置了主动/被动群集设置,所有队列管理器都在主动/被动节点上正常运行。我们已经在队列管理器中配置了通道队列, 当应用程序试图连接我的队列管理器时,我们遇到了错误 下面是在应用程序端获取的错误 The Security athuntication was not valid that supplied for QUEUEMANAGER 'xxxxx_OUTWARD'WITH CONNECTION 'CLIEN

我们使用的是websphere MQ版本9.0.0.1,基本上我们已经在linux机器上配置了主动/被动群集设置,所有队列管理器都在主动/被动节点上正常运行。我们已经在队列管理器中配置了通道队列, 当应用程序试图连接我的队列管理器时,我们遇到了错误

下面是在应用程序端获取的错误

The Security athuntication was not valid that supplied for  QUEUEMANAGER 'xxxxx_OUTWARD'WITH CONNECTION 'CLIENT' and HOST NAME 'xxxxx'PLEASE CHECK IF THE ERROR QUEUEMANAGER 'xxxxx_OUTWARD'WITH CONNECTION MODE 'CLIENT'AND HOST NAME'xxxxxx.
下面是我们在queuemanager级别的错误日志中发现的错误

----- cmqxrsrv.c : 2362 -------------------------------------------------------
04/27/2018 07:52:35 PM - Process(29498.16) User(mqm) Program(amqzlaa0)
                    Host(xxxxxxx) Installation(Installation2)
                    VRMF(9.0.0.1) QMgr(xxxxx_INWARD)

AMQ5534: User ID 'mqm' authentication failed

EXPLANATION:
The user ID and password supplied by the 'WebSphere MQ Client for Java' program
could not be authenticated. 
Additional information: 'N/A'.
ACTION:
Ensure that the correct user ID and password are provided by the application.
Ensure that the authentication repository is correctly configured. Look at
previous error messages for any additional information.
----- amqzfuca.c : 4486 -------------------------------------------------------
04/27/2018 07:52:35 PM - Process(29498.16) User(mqm) Program(amqzlaa0)
                    Host(JPRIPAYMENTMQ2) Installation(Installation2)
                    VRMF(9.0.0.1) QMgr(xxxxx_INWARD)

AMQ5542: The failed authentication check was caused by the queue manager
CONNAUTH CHCKCLNT(OPTIONAL) configuration.

EXPLANATION:
The user ID 'mqm' and its password were checked because the queue manager
connection authority (CONNAUTH) configuration refers to an authentication
information (AUTHINFO) object named 'SYSTEM.DEFAULT.AUTHINFO.IDPWOS' with
CHCKCLNT(OPTIONAL). 

This message accompanies a previous error to clarify the reason for the user ID
and password check.
ACTION:
Refer to the previous error for more information. 

Ensure that a password is specified by the client application and that the
password is correct for the user ID. The authentication configuration of the
queue manager connection determines the user ID repository. For example, the
local operating system user database or an LDAP server. 

If the CHCKCLNT setting is OPTIONAL, the authentication check can be avoided by
not passing a user ID across the channel. For example, by omitting the MQCSP
structure from the client MQCONNX API call. 

To avoid the authentication check, you can amend the authentication
configuration of the queue manager connection, but you should generally not
allow unauthenticated remote access.
-------------------------------------------------------------------------------
04/27/2018 07:52:36 PM - Process(18265.105) User(xxx) Program(amqrmppa)
                    Host(xxxxx) Installation(Installation2)
                    VRMF(9.0.0.1) QMgr(xxxxx_INWARD)

AMQ9557: Queue Manager User ID initialization failed for 'mqm'.

EXPLANATION:
The call to initialize the User ID 'mqm' failed with CompCode 2 and Reason
2035. If an MQCSP block was used, the User ID in the MQCSP block was 'mqm'.
ACTION:
Correct the error and try again.
----- cmqxrsrv.c : 2362 -------------------------------------------------------
在此之后,我使用下面的命令在队列管理器级别和队列级别为“mqm”用户提供了权限,但我们仍然面临相同的错误

setmqaut -m queue manager name -t qmgr -p mqm +connect & 
setmqaut -m queue manager name -n queue name -t queue -p mqm user name +all
谁能帮助解决这个问题

@莫拉格·休森:- 如何在队列管理器级别关闭用户标识和密码

@莫拉格·休森:- 关闭用户id和密码的任何命令请共享该命令以解决此问题

@JoshMC:-如果我关闭了它,这是一种很好的做法,或者是否有其他选项可以从队列管理器/应用程序端解决此问题

@大家好,我被告知应用程序在不提及任何用户id和密码的情况下放置消息。之后,我的应用程序可以访问所有队列管理器。
问题解决了。感谢所有人帮助解决此问题。

首先,除MQAdmins和在“mqm”帐户下运行的MQ服务外,任何应用程序都不应使用“mqm”帐户。常规业务应用程序永远不应使用“mqm”帐户。这是一个很大的安全风险,不符合IBM的MQ最佳实践

其次,“mqm”帐户已经拥有了所有内容的完全权限

setmqaut -m queue manager name -t qmgr -p mqm +connect & 
setmqaut -m queue manager name -n queue name -t queue -p mqm +all
您正在尝试将权限授予已具有完全权限的用户ID

第三,通过执行这些命令,您可能会弄乱队列管理器

第四,错误消息与授权无关,但正如JoshMc指出的,它与身份验证有关。setmqaut命令用于授权(即权限)


第五,在运行队列管理器(或使用MS AD)的服务器上创建用户ID和密码,并在应用程序连接到队列管理器时提供这些凭据。注意:您需要使用setmqaut命令来授予新的用户ID权限,以访问队列管理器和队列。

队列管理器错误消息会准确地告诉您问题所在。首先它说:-

AMQ5534: User ID 'mqm' authentication failed

EXPLANATION:
The user ID and password supplied by the 'WebSphere MQ Client for Java' program
could not be authenticated. 
因此,试图通过客户端连接的Java应用程序发送了“mqm”作为用户id,或者是错误的密码(或者可能根本没有密码)

队列管理器正在检查密码。第二条错误消息告诉您为什么要检查它

AMQ5542: The failed authentication check was caused by the queue manager
CONNAUTH CHCKCLNT(OPTIONAL) configuration.

EXPLANATION:
The user ID 'mqm' and its password were checked because the queue manager
connection authority (CONNAUTH) configuration refers to an authentication
information (AUTHINFO) object named 'SYSTEM.DEFAULT.AUTHINFO.IDPWOS' with
CHCKCLNT(OPTIONAL). 
默认情况下,队列管理器上存在第二条错误消息中描述的配置

你有两个选择

  • 在Java应用程序上发送与“mqm”用户id匹配的正确密码
  • 选择关闭队列管理器上的用户id和密码检查

  • 错误很明显,您有chkclnt可选。使用此设置,如果发送密码,则密码必须有效,并且能够根据qmgr connauth属性中指定的authinfo对象的配置方式进行验证。您试图实现的目标是什么?如果你关闭它,那么任何有权访问你的网络的人都将拥有完全的管理员权限。Morag给出了两个选项,最好的一个是发送正确的密码,并确保mq配置为进行身份验证。Roger也提出了很好的建议,为什么要以mqm的形式运行应用程序?它是一个管理工具吗?如果不是,则不需要使用mqm authority运行。我们是否可以编辑位于以下安装路径中的MQIVP.java文件:/opt/mqm/samp/wmqjava/samples/如果是,那么我应该在第===>行中添加用户名和密码用户=null;私有字符串密码=null;