1

我需要使用 AD id 和密码配置代理以连接到 SQL 数据库服务器。

我输入的设置命令如下:

  1. 首先我创建了 DSN

  2. 停止了经纪人

  3. 执行:

    mqsisetdbparams BROKERNAME -n SQL_ASDA_TMS -u UK\\sqltmsdb -p wmbdev 
    
  4. 开始经纪人

设置上述属性并重新启动代理后,我尝试使用 mqsicvp 命令验证连接,该命令最终失败,错误在 SQL Server 中记录为

用户 'UK\sqltmsdb' 登录失败。原因:尝试使用带有 SQL 服务器身份验证的 NT 帐户名。

在下面找到我的 DSN 详细信息:

;# UNIX to SQLServer stanza 
[SQL_ASDA_TMS] 
Driver=/opt/IBM/mqsi/7.0/ODBC/V6.0/lib/UKmsss24.so 
Description=DataDirect 6.0 SQL Server Wire Protocol 
Address=LABUKNTS5028.uk.wal-mart.com,14481 
AnsiNPW=Yes 
Database=TMS 
Trusted_Connection=Yes 
QuotedId=No 
ColumnSizeAsCharacter=1 
LoginTimeout=0

笔记:

  • Broker 在 linux 上运行。
  • Windows 应用程序能够使用该 AD Id 连接到 SQL Server
  • Broker 能够使用普通 SQL id 和密码连接到同一个 SQL 服务器,但使用 AD(活动目录)ID 失败

有人可以帮我告诉我要实施的任何事情是否可行吗?如果是的话,你能帮我解决这个问题吗?如果我在这里遗漏了什么?

4

1 回答 1

1

Windows authentication for your DB means, you don't need a user id and password to connect to the database if you are logged in to the windows machine with the corresponding user id.

"User id" in mqsisetdbparams is treated as a database user id and password and hence giving your Active directory's user id and password in the command will be wrong.

So, in short, an ODBC connection will not be possible from the broker to your database using windows authentication.

But, you always have the option of using the JDBC connection. This should work even with windows authentication as it doesn't mandate you to give user id and password.

You can use the JDBC connection via a java compute node in your message flow(reference).

Here you can find how to use windows authentication for a JDBC connection.

于 2013-10-08T13:23:08.640 回答