Share via


New-SCADConnector

New-SCADConnector

Creates a Service Manager Active Directory connector.

Syntax

Parameter Set: Default
New-SCADConnector [-DisplayName] <String> [[-Description] <String> ] [[-QueryRoot] <String> ] [[-RunAsAccount] <ManagementPackSecureReference> ] -ADCredential <PSCredential> [-ComputerFilter <String> ] [-ComputerName <String[]> ] [-Credential <PSCredential> ] [-Enable <Boolean> ] [-ExpandGroups] [-PassThru] [-PrinterFilter <String> ] [-ScheduleDay <DaySchedule> ] [-ScheduleHour <Int32> ] [-SCSession <Connection[]> ] [-SyncNow] [-UserFilter <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Detailed Description

The New-SCADConnector cmdlet creates a Service Manager Active Directory connector.

The following parameters are only available if you have applied Service Manager 2012 R2 Update Rollup 6 or later.

-- ScheduleDay
-- ScheduleHour

Parameters

-ADCredential<PSCredential>

Specifies the credential to use when this cmdlet connects to the domain controller.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ComputerFilter<String>

Specifies a filter that selects the computers that the connector synchronizes. The filter must be specified as an Active Directory filter. For example, the following filter includes all computers which begin with win in the synchronization:

(name=win*)

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ComputerName<String[]>

Specifies the name of the computer on which the System Center Data Access service runs. The user account that is specified in the Credential parameter must have access rights to the specified computer.

Aliases

none

Required?

false

Position?

named

Default Value

localhost

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Credential<PSCredential>

Specifies the credentials that this cmdlet uses to connect to the server on which the System Center Data Access service runs. The specified user account must have access rights to that server.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Description<String>

Specifies a description for the connector.

Aliases

none

Required?

false

Position?

2

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DisplayName<String>

Specifies the display name property of the connector.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Enable<Boolean>

Indicates whether this cmdlet enables or disables the connector.

Aliases

none

Required?

false

Position?

named

Default Value

True

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ExpandGroups

Specifies that this cmdlet recursively includes members of the groups that are specified by the UserFilter parameter.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-PassThru

Indicates that this cmdlet returns the Active Directory connector that it creates. You can pass this object to other cmdlets.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-PrinterFilter<String>

Specifies a filter that this cmdlet uses to select the printers that the connector synchronizes.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-QueryRoot<String>

Specifies the Active Directory folder from which this cmdlet queries objects, such as LDAP://DC=scsm,DC=stbtest,DC=microsoft,DC=com.

Aliases

none

Required?

false

Position?

3

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RunAsAccount<ManagementPackSecureReference>

Specifies the RunAs account to use when using this connector.

Aliases

none

Required?

false

Position?

4

Default Value

Daily

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ScheduleDay<DaySchedule>

Specifies the day of the week on which the connector synchronizes. Valid values are:

-- Daily
-- Sunday
-- Monday
-- Tuesday
-- Wednesday
-- Thursday
-- Friday
-- Saturday

Aliases

none

Required?

false

Position?

named

Default Value

Daily

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ScheduleHour<Int32>

Specifies the hour at which the connector starts synchronization. The value must be a number from zero (0) to 23.

Aliases

none

Required?

false

Position?

named

Default Value

2

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SCSession<Connection[]>

Specifies an object that represents the session to a Service Manager management server.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SyncNow

Causes the Active Directory connector to start a synchronization cycle.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-UserFilter<String>

Specifies the filter that is used to select the users to by synchronized by the connector. You must specify the value in the form of an Active Directory filter. For example, the following value for this parameter includes in the synchronization users whose givenName starts with a:

(givenname=a*)

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Confirm

Prompts you for confirmation before running the cmdlet.

Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

  • None.

    You cannot pipe input to this cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

  • None.

    This cmdlet does not generate any output.

Examples

Example 1: Create a connector to the local domain

The first command gets a Run As account for Workflow Account by using the Get-SCSMRunAsAccount cmdlet. The command stores the result in the $RunAsAccount variable.

The second command prompts you for credentials by using the Get-Credential cmdlet, and then stores the credentials in the $Credential variable.

The final command creates an Active Directory connector to the local domain, which retrieves all computers, printers, users, and user groups. The connector is configured to synchronize every Sunday at 3:00 A.M.

PS C:\> $RunAsAccount = Get-SCSMRunAsAccount -DisplayName "Workflow Account"
PS C:\> $Credential = Get-Credential
PS C:\> New-SCADConnector -DisplayName "Contoso AD Connector" -Description "Contoso AD Connector" -QueryRoot "LDAP://DC=Contoso,DC=com" -RunAsAccount $RunAsAccount -ADCredential $Credential -Enable $False -ScheduleDay Sunday -ScheduleHour 3

Example 2: Create a connector to the local domain that includes a user filter

The first command gets a Run As account for Workflow Account, and then stores it in the $RunAsAccount variable.

The second command prompts you for credentials by using the Get-Credential cmdlet, and then stores the credentials in the $Credential variable.

The final command creates an Active Directory connector to the local domain which retrieves only the users that start with the letter E.

PS C:\> $RunAsAccount = Get-SCSMRunAsAccount -DisplayName "Workflow Account"
PS C:\> $Credential = Get-Credential
PS C:\> New-SCADConnector -DisplayName "Contoso AD Connector" -Description "Contoso users starting with E" -QueryRoot "LDAP://DC=Contoso,DC=com" -RunAsAccount $RunAsAccount -ADCredential $Credential -Enable $False -UserFilter "(givenname=E*)"

Get-Credential

Get-SCSMRunAsAccount

New-SCCMConnector

New-SCOMAlertConnector

New-SCOMConfigurationItemConnector

New-SCOrchestratorConnector

New-SCVMMConnector