Working with the WMI Provider for Configuration Management
Consider the following before programming with the WMI Provider for Computer Management:
Binding
The WMI Provider for Configuration Management is a COM object model and it supports early and late binding. With late binding you can use script languages, such as VBScript, to manipulate the SQL Server services, network settings, and aliases programmatically.
For further information about programming WMI Provider implementations using scripting languages, see the Microsoft MSDN Web site.
Specifying a Connection String
Applications direct the WMI Provider for Configuration Management to an instance of SQL Server by connecting to a WMI namespace defined by the provider. The Windows WMI service maps this namespace to the provider DLL and loads it into memory. All instances of SQL Server 2005 are represented with a single WMI namespace. The namespace defaults to
\\.\root\Microsoft\SqlServer\ComputerManagement\instance_name
where instance_name
defaults to MSSQLSERVER
in a default installation of SQL Server.
Note: If you are connecting through Windows Firewall you will need to make sure your computers are configured appropriately. See the "Connecting Through Windows Firewall" article in the Windows Management Instrumentation documentation on Microsoft MSDN Web site.
Permissions and Server Authentication
To access the WMI Provider for Configuration Management, the client WMI management script must be running in the context of an administrator on the target computer. You need to be a member of the local Windows administrators group on the computer you want to manage.
The administrator can set group policies to control user access to WMI providers. For more information about setting group policies see "Group Policy and MMC" in the SQL Server Configuration Manager Help.
The WMI management script can be used to update the account under which SQL Server services run.
Security certificates are supported by the WMI Provider for Configuration Management. For more information about certificates, see Encryption Hierarchy.
See Also
Concepts
Other Resources
SQL Server Configuration Manager