Export (0) Print
Expand All
Expand Minimize

Get-SCSMUser

Updated: November 1, 2013

Applies To: System Center 2012 - Service Manager, System Center 2012 R2 Service Manager, System Center 2012 SP1 - Service Manager

Get-SCSMUser

Retrieves users that are defined in Service Manager.

Syntax

Parameter Set: FromDisplayName
Get-SCSMUser [[-DisplayName] <String[]> ] [-ComputerName <String[]> ] [-Credential <PSCredential> ] [-SCSession <Connection[]> ] [ <CommonParameters>]

Parameter Set: FromId
Get-SCSMUser [-Id] <Guid[]> [-ComputerName <String[]> ] [-Credential <PSCredential> ] [-SCSession <Connection[]> ] [ <CommonParameters>]

Parameter Set: FromName
Get-SCSMUser [-Name] <String[]> [-ComputerName <String[]> ] [-Credential <PSCredential> ] [-SCSession <Connection[]> ] [ <CommonParameters>]




Detailed Description

The Get-SCSMUser cmdlet retrieves users that are defined in Service Manager. Depending on the configuration of the system, the users can be a collection of Windows Active Directory users, and users that are defined in other operating systems, such as UNIX.

Parameters

-ComputerName<String[]>

Specifies the name of the computer on which Service Manager management server runs.


Aliases

none

Required?

false

Position?

named

Default Value

localhost

Accept Pipeline Input?

true (ByValue)

Accept Wildcard Characters?

false

-Credential<PSCredential>

Specifies the credential to use when you are connecting to the Service Manager management server.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

true (ByValue)

Accept Wildcard Characters?

false

-DisplayName<String[]>

Specifies the DisplayName of the user to retrieve. This can be a regular expression.


Aliases

none

Required?

false

Position?

1

Default Value

none

Accept Pipeline Input?

true (ByValue)

Accept Wildcard Characters?

false

-Id<Guid[]>

Specifies the ID of the user to retrieve.


Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

true (ByValue)

Accept Wildcard Characters?

false

-Name<String[]>

Specifies the name of the user to retrieve. This can be a regular expression


Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

true (ByValue)

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?

true (ByValue)

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters.

Inputs

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

  • System.String

    You can pipe a name to the DisplayName parameter of the Get-SCSMUser cmdlet.


  • System.Guid

    You can pipe a GUID to the Id parameter of the Get-SCSMUser cmdlet.


Outputs

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

  • Microsoft.AD.User

    The User object provides the information about the Service Manager User. This object can be used in conjunction with the Set-SCSMUser cmdlet to add a user to a user role.


  • Microsoft.AD.Group
  • System.Domain.User

Examples

-------------------------- EXAMPLE 1 --------------------------

This command retrieves User objects that are available in Service Manager.


PS C:\>Get-SCSMUser
The properties displayed are FirstName, LastName, Domain, and UserName
FirstName LastName Domain UserName
---------- --------- ------- ---------
Joe User SMInternal Joe.User

-------------------------- EXAMPLE 2 --------------------------

This command sets a Domain property for all users. This uses the Update-SCSMClassInstance cmdlet.


PS C:\>Get-SCSMUser |%{ $_.Domain = "NewDomain"; $_ }|Update-SCSMClassInstance
 
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft