Applies to: Exchange Server 2013

Topic Last Modified: 2012-07-27

Use the New-PowerShellVirtualDirectory cmdlet to create a Windows PowerShell virtual directory in Internet Information Services (IIS).

For information about the parameter sets in the Syntax section below, see Syntax.

Syntax

New-PowerShellVirtualDirectory -Name <String> [-AppPoolId <String>] [-BasicAuthentication <$true | $false>] [-CertificateAuthentication <$true | $false>] [-Confirm [<SwitchParameter>]] [-DomainController <Fqdn>] [-ExternalUrl <Uri>] [-InternalUrl <Uri>] [-LimitMaximumMemory <$true | $false>] [-Path <String>] [-RequireSSL <$true | $false>] [-Role <ClientAccess | Mailbox>] [-Server <ServerIdParameter>] [-WebSiteName <String>] [-WhatIf [<SwitchParameter>]] [-WindowsAuthentication <$true | $false>]

Examples

EXAMPLE 1

This example creates a Windows PowerShell virtual directory and configures it to accept only certificate authentication.

Copy Code
New-PowerShellVirtualDirectory -Name "Contoso Certificates Required" -BasicAuthentication $false -WindowsAuthentication $false -CertificateAuthentication $true

Detailed Description

Although it's possible to create a Windows PowerShell virtual directory, we recommend that you only do so at the request of Microsoft Customer Service and Support.

You need to be assigned permissions before you can run this cmdlet. Although all parameters for this cmdlet are listed in this topic, you may not have access to some parameters if they're not included in the permissions assigned to you. To see what permissions you need, see the "PowerShell virtual directories" entry in the Exchange and Shell Infrastructure Permissions topic.

Parameters

Parameter Required Type Description

Name

Required

System.String

The Name parameter specifies the name of the new Windows PowerShell virtual directory. The name you provide will have the name of the website it's created under appended to it. If the name you provide contains spaces, enclose the name in quotation marks (").

AppPoolId

Optional

System.String

The AppPoolId parameter specifies the pool of programs that can be used with the Windows PowerShell virtual directory.

BasicAuthentication

Optional

System.Boolean

The BasicAuthentication parameter specifies whether Basic authentication is enabled on the Windows PowerShell virtual directory. The valid values are $true and $false. The default value is $true.

CertificateAuthentication

Optional

System.Boolean

The CertificateAuthentication parameter specifies whether certificate authentication is enabled on the Windows PowerShell virtual directory. The valid values are $true and $false. The default value is $false.

Confirm

Optional

System.Management.Automation.SwitchParameter

The Confirm switch causes the command to pause processing and requires you to acknowledge what the command will do before processing continues. You don't have to specify a value with the Confirm switch.

DomainController

Optional

Microsoft.Exchange.Data.Fqdn

The DomainController parameter specifies the fully qualified domain name (FQDN) of the domain controller that writes this configuration change to Active Directory.

ExternalUrl

Optional

System.Uri

The ExternalUrl parameter specifies the external URL that the Windows PowerShell virtual directory points to.

InternalUrl

Optional

System.Uri

The InternalUrl parameter specifies the internal URL that the Windows PowerShell virtual directory points to.

LimitMaximumMemory

Optional

System.Boolean

The LimitMaximumMemory parameter specifies whether to limit the amount of memory used by the application pool in the Windows PowerShell virtual directory. If this parameter is set to $true, the amount of memory made available to the application pool is limited to 70 percent of the total physical memory in the server. If this parameter is set to $false, the amount of memory isn't limited. The default value is $false.

Path

Optional

System.String

The Path parameter specifies the directory that contains the system files for the Windows PowerShell virtual directory.

RequireSSL

Optional

System.Boolean

The RequireSSL parameter specifies whether the Windows PowerShell virtual directory should require that the client connection be made using Secure Sockets Layer (SSL). The valid values are $true and $false. The default value is $true.

Role

Optional

Microsoft.Exchange.Management.SystemConfigurationTasks.VirtualDirectoryRole

The Role parameter species the configuration that should be used when the virtual directory is created. The following are the values that can be used with this parameter:

  • FrontEnd   Configure the virtual directory for use on a Client Access server.

  • BackEnd   Configure the virtual directory for use on a Mailbox server.

Server

Optional

Microsoft.Exchange.Configuration.Tasks.ServerIdParameter

The Server parameter specifies the Exchange server name on which the new Windows PowerShell virtual directory should be created.

WebSiteName

Optional

System.String

The WebSiteName parameter specifies the name of the IIS website under which the Windows PowerShell virtual directory is created.

WhatIf

Optional

System.Management.Automation.SwitchParameter

The WhatIf switch instructs the command to simulate the actions that it would take on the object. By using the WhatIf switch, you can view what changes would occur without having to apply any of those changes. You don't have to specify a value with the WhatIf switch.

WindowsAuthentication

Optional

System.Boolean

The WindowsAuthentication parameter specifies whether Integrated Windows authentication is enabled on the Windows PowerShell virtual directory. The valid values are $true and $false. The default value is $true.

Input Types

To see the input types that this cmdlet accepts, see Cmdlet Input and Output Types. If the Input Type field for a cmdlet is blank, the cmdlet doesn’t accept input data.

Return Types

To see the return types, which are also known as output types, that this cmdlet accepts, see Cmdlet Input and Output Types. If the Output Type field is blank, the cmdlet doesn’t return data.