Applies to: Exchange Server 2007
Topic Last Modified: 2007-06-05

Use the New-AutodiscoverVirtualDirectory cmdlet to create a new Autodiscover virtual directory on a computer that is running Microsoft Exchange Server 2007 that has the Client Access server role installed. If your organization has multiple e-mail domains and each requires its own Autodiscover site and corresponding virtual directory, use this cmdlet to create a new Autodiscover virtual directory under a new Web site.

Syntax

New-AutodiscoverVirtualDirectory [-ApplicationRoot <String>] [-AppPoolId <String>] [-BasicAuthentication <$true | $false>] [-DigestAuthentication <$true | $false>] [-DomainController <Fqdn>] [-ExternalUrl <Uri>] [-InternalUrl <Uri>] [-Path <String>] [-TemplateInstance <PSObject>] [-WebSiteName <String>] [-WindowsAuthentication <$true | $false>]

Parameters

Parameter Required Type Description

ApplicationRoot

Optional

System.String

This parameter sets the metabase path of the virtual directory. By default, this path is the same as the Web site in which the virtual directory is created.

AppPoolId

Optional

System.String

This parameter sets the pool of programs that can be used with the virtual directory.

BasicAuthentication

Optional

System.Boolean

This parameter specifies whether Basic authentication is enabled on the Autodiscover virtual directory.

DigestAuthentication

Optional

System.Boolean

This parameter specifies whether Digest authentication is enabled on the Autodiscover virtual directory.

DomainController

Optional

Microsoft.Exchange.Data.Fqdn

To specify the fully qualified domain name (FQDN) of the domain controller that writes this configuration change to the Active Directory directory service, include the DomainController parameter on the cmdlet.

ExternalUrl

Optional

System.Uri

This parameter specifies the URL that is used to connect to the virtual directory from outside the network firewall.

InternalUrl

Optional

System.Uri

This parameter specifies the URL that is used to connect to the virtual directory from inside the network firewall.

Path

Optional

System.String

This parameter sets the directory that contains the system files for the virtual directory.

TemplateInstance

Optional

System.Management.Automation.PSObject

When an existing object is supplied to this parameter, the cmdlet will use the configuration of that object to create an identical copy of the object on a local or target server.

WebSiteName

Optional

System.String

This parameter specifies the name of the Internet Information Services (IIS) Web site under which to create the virtual directory.

WindowsAuthentication

Optional

System.Boolean

This parameter specifies whether Integrated Windows authentication is enabled on the Autodiscover virtual directory.

Detailed Description

Use the New-AutodiscoverVirtualDirectory cmdlet to create a new Autodiscover virtual directory on an Exchange 2007 Client Access server. If your organization has multiple e-mail domains and each requires its own Autodiscover site and corresponding virtual directory, use this cmdlet to create a new Autodiscover virtual directory under a new Web site.

Note:
When you are creating a new Autodiscover virtual directory, we recommend that you enable Secure Sockets Layer (SSL) for the Autodiscover service.

To run the New-AutodiscoverVirtualDirectory cmdlet, the account you use must be delegated the following:

  • Exchange Server Administrator role and local Administrators group for the target server

For more information about permissions, delegating roles, and the rights that are required to administer Exchange Server 2007, see Permission Considerations.

Input Types

Return Types

Errors

Error Description

 

 

Exceptions

Exceptions Description

 

 

Example

The following code example creates a new virtual directory that is named autodiscover under the Web site "autodiscover.contoso.com", and requires that the user connect by using Windows Integrated authentication or Digest authentication over SSL.

Copy Code
New-AutoDiscoverVirtualDirectory -websitename "autodiscover.contoso.com" -WindowsAuthentication $true -DigestAuthentication $true