Providers

Choose a provider from the list on the left or search for a specific provider. Choose a provider from the list or search for a specific provider.
Cmdlets  About Help
 
 

WSMan

WSMan

microsoft.wsman.management.dll

Synopsis

Provides access to Web Services for Management (WS-Management) configuration information.

Detailed Description

The WS-Management provider for Windows PowerShell lets you add, change, clear, and delete WS-Management configuration data on local or remote computers. The WS-Management provider add the WSMan: drive to Windows PowerShell.

New in Windows PowerShell 3.0

Beginning in Windows PowerShell 3.0, the WS-Management provider has been updated to support new properties for session configurations, such as OutputBufferingMode. The session configurations appear as items in the Plugin directory of the WSMan: drive and the properties appear as items in each session configuration.

You can use commands in the WSMan: drive to change the values of the new properties. However, you cannot use the WSMan: drive in Windows PowerShell 2.0 to change properties that are introduced in Windows PowerShell 3.0. Although no error is generated, the commands are not effective To change these settings, use the WSMan drive in Windows PowerShell 3.0.

Organization of the WSMan: Drive

The WS-Management provider exposes a Windows PowerShell drive with a directory structure that corresponds to a logical grouping of WS-Management configuration settings. These groupings are known as containers.

-- Client
You can configure various aspects of the WS-Management client. The configuration information is stored in the registry.

-- Service
You can configure various aspects of the WS-Management service. The configuration information is stored in the registry.
Note: Service configuration is sometimes referred to as Server configuration.

-- Shell
You can configure various aspects of the WS-Management shell, such as the setting to allow remote shell access (AllowRemoteShellAccess) and the maximum number of concurrent users allowed (MaxConcurrentUsers).

-- Listener
You can create and configure a listener. A listener is a management service that implements the WS-Management protocol to send and to receive messages.

-- Plugin
Plug-ins are loaded and used by the WS-Management service to provide various functions, such as event forwarding, configuration, and WMI access. Windows PowerShell session configurations, such as Microsoft.PowerShell, are plug-ins and appear in the Plugin directory.

-- ClientCertificate
You can create and configure a client certificate. A client certificate is used when the WS-Management client is configured to use certificate authentication.

Directory Hierarchy of the WS-Management Provider
---------------
The directory hierarchy of the WS-Management provider for the local computer is as follows:

WSMan:\localhost
--- Client
--- Service
--- Shell
--- Listener
------ <Specific_Listener>
--- Plugin
------ Event Forwarding Plugin
--------- InitializationParameters
--------- Resources
------------ Security
------ Microsoft.Powershell
--------- InitializationParameters
--------- Resources
------------ Security
------ WMI Provider
--------- InitializationParameters
--------- Resources
------------ Security
--- ClientCertificate

The directory hierarchy of the WS-Management provider for a remote computer is the same as a local computer. However, in order to access the configuration settings of a remote computer, you need to make a connection to the remote computer using Connect-WSMan. Once a connection is made to a remote computer, the name of the remote computer shows up in the provider.

WSMan:\<Remote_Computer_Name>
--- Client
--- Service
--- Shell
--- Listener
------ <Specific_Listener>
--- Plugin
------ Event Forwarding Plugin
--------- InitializationParameters
--------- Resources
------------ Security
------ Microsoft.Powershell
--------- InitializationParameters
--------- Resources
------------ Security
------ WMI Provider
--------- InitializationParameters
--------- Resources
------------ Security
--- ClientCertificate


Custom Provider Help
--------------------
The Listener, Plugin (IntitializationParameters, Resources, Security) and ClientCertificate provider paths provide specific New-Item support. Type "get-help New-Item" in the relevant path for custom help.

Notes

Tasks

Navigating the WSMan: Drive

-------------------------- EXAMPLE 1 --------------------------
This command uses the Set-Location cmdlet to change the current location to the WSMan: drive.

Set-Location WSMan:

-------------------------- EXAMPLE 2 --------------------------
This command uses the Set-Location command to change the current location to the root location in the Localhost store location. Use a backslash (\) or forward slash (/) to indicate a level of the WSMan: drive.

Set-Location -Path Localhost

If you are not in the WSMan: drive, begin the path with the drive name.

-------------------------- EXAMPLE 3 --------------------------
This command uses the Set-Location command to change the current location to the root location in the remote system store location. Use a backslash (\) or forward slash (/) to indicate a level of the WSMan: drive.

Set-Location -Path WSMan:\SERVER01

If you are not in the WSMan: drive, begin the path with the drive name. The above command assume that a connection to the remote system already exists. If a connection has not been made to the remote system, then a connection could be make immediately prior to navigating to the root location in the remote system store location. For example: WSMan-Connect SERVER01 Set-Location -Path WSMan:\SERVER01

-------------------------- EXAMPLE 4 --------------------------
This command uses the Set-Location command to change the current location to the Client location in the Localhost store location. Use a backslash (\) or forward slash (/) to indicate a level of the WSMan: drive.

Set-Location -Path Localhost\Client

If you are not in the WSMan: drive, begin the path with the drive name.

Displaying the Contents of the WSMan: Drive

-------------------------- EXAMPLE 1 --------------------------
This command uses the Get-Childitem cmdlet to display the WS-Management stores in the Localhost store location.

get-childitem -path WSMan:\Localhost

If you are in the WSMan: drive, you can omit the drive name.

-------------------------- EXAMPLE 2 --------------------------
This command uses the Get-Childitem cmdlet to display the WS-Management stores in the remote computer (SERVER01) store location.

get-childitem -path WSMan:\SERVER01

If you are in the WSMan: drive, you can omit the drive name. The above command assume that a connection to the remote system already exists. If a connection has not been made to the remote system, then a connection could be make immediately displaying the properties and containers in the remote system store location. For example: WSMan-Connect SERVER01 get-childitem -path WSMan:\SERVER01

-------------------------- EXAMPLE 3 --------------------------
This command uses the Get-Childitem cmdlet to display the current WS-Management connections.

get-childitem -path WSMan:\

If you are in the WSMan: drive, you can omit the drive name.

-------------------------- EXAMPLE 4 --------------------------
This command uses the Get-Item cmdlet to get the properties and containers in the current store.

Get-Childitem

The above command returns a list of properties and containers. For example: PS WSMan:\localhost> get-childitem WSManConfig: Microsoft.WSMan.Management\WSMan::localhost Name Value Type ---- ----- ---- MaxEnvelopeSizekb 150 System.String MaxTimeoutms 60000 System.String MaxBatchItems 32000 System.String MaxProviderRequests 4294967295 System.String Client Container Service Container Shell Container Listener Container Plugin Container ClientCertificate Container