美文网首页IT技术篇
访问SQL Server WMI对象

访问SQL Server WMI对象

作者: 8d5885e2f1d5 | 来源:发表于2019-08-16 16:22 被阅读0次

    访问SQL Server WMI对象

    1. 使用Powershell访问

    get-wmiobject -list -namespace "root\Microsoft\SqlServer"

    get-wmiobject -list -namespace "root\Microsoft\SqlServer\ServerEvents\MSSQLSERVER"

    get-wmiobject -namespace "root\Microsoft\SqlServer\ComputerManagement10" -query "Select * From SqlService"

    2. 使用wbemtest.exe访问

    在开始、运行,输入wbemtest.exe

    输入空间名: 

    root\Microsoft\SqlServer\ComputerManagement10

    郑州同济医院:http://yyk.39.net/zz3/zonghe/1d426.html/

    遇到的问题:

    在访问wbemtest.exe时,会遇到权限问题,如下:

    在开始、运行,输入wmimgmt.msc

    右键WMI Control(local),点击Properties

    切换到Security窗口,展开到需要访问的目录,授予DX\xucy访问权限。

    相关文章

      网友评论

        本文标题:访问SQL Server WMI对象

        本文链接:https://www.haomeiwen.com/subject/sqjqsctx.html