首页 > 解决方案 > 有没有办法使用 saltStack 创建 SQL Server xp_cmdshell_proxy_account

问题描述

我一直在尝试使用 saltStack 在 SQL Server Management Studio (SSMS) 中创建代理凭据。

master和minion之间已经建立了通信。但是凭据没有在 minion 服务器上更新。

root@host:/home/ubuntu# salt minion mssql.tsql_query "EXEC sp_xp_cmdshell_proxy_account 'test1','test123';"
minion:
    |_
      - Could not run the query
    |_
      - Statement not executed or executed statement has no resultset

其他命令工作正常。

root@host:/home/ubuntu# salt minion mssql.tsql_query 'SELECT @@version as version' as_dict=True
minion:
    |_
      ----------
      version:
          Microsoft SQL Server 2014 - 12.0.2000.8 (X64) 
            Feb 20 2014 20:04:26 
            Copyright (c) Microsoft Corporation
            Express Edition (64-bit) on Windows NT 6.3 <X64> (Build 9600: ) (Hypervisor)

我没有找到任何使用tsql_query模块运行 salt 的教程或链接。

标签: ssmssalt-stack

解决方案


推荐阅读