Share via


Get-CrmServer

Retrieves details for one or all Dynamics 365 servers in a deployment.

Syntax

Default (Default)

Get-CrmServer
    [[-Name] <String>]
    [-Timeout <Int32>]
    [-Diag]
    [-Credential <PSCredential>]
    [-DwsServerUrl <String>]

Description

The Get-CrmServer cmdlet retrieves details for one or all Dynamics 365 servers in a deployment. If no parameters are provided, the cmdlet retrieves details for all servers in the deployment. If the Name parameter is specified, the cmdlet retrieves details for the specified server.

Examples

Example 1

PS C:\> Get-CrmServer

Retrieves information for all Dynamics 365 servers in a deployment.

Example 2

PS C:\> Get-CrmServer -Name contosoweb

Retrieves information for the Dynamics 365 server named contosoweb.

Parameters

-Credential

Expects a variable that contains the user credentials used for signing in to Dynamics 365 on-premises organization. To establish this variable, run the PowerShell command $Cred = Get-Credential.

Parameter properties

Type:PSCredential
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

-Diag

Turns on stack traces for error reports returned from Dynamics 365 service calls. Enabling this emits a detailed error message, including a stack trace, when an error is encountered by the Dynamics 365 PowerShell command.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-DwsServerUrl

The URL of the Deployment Web Service. This should be in the format: https://<serverurl>, for example, https://contoso.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

-Name

Specifies the name of the Dynamics 365 server to retrieve. You can find the name of all Dynamics 365 servers in the deployment by running the Get-CrmServer cmdlet with no parameters.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:0
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-Timeout

For internal use only.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

Inputs

System.String

System.Int32

System.Management.Automation.SwitchParameter

System.Management.Automation.PSCredential

Outputs

Microsoft.Xrm.Sdk.Deployment.Server