Get-DPMJob

Get-DPMJob

Gets current and previous jobs on a DPM server.

Syntax

Parameter Set: GetJobsDPM
Get-DPMJob [[-DPMServerName] <String> ] [[-Type] <DPMJobType[]> ] [[-Status] <JobStatusType[]> ] [[-From] <DateTime> ] [[-To] <DateTime> ] [[-Newest]] [[-AdhocJobs]] [-AllJobsInInterval] [-NoLimitOnJobCount] [ <CommonParameters>]

Parameter Set: GetJobsDS
Get-DPMJob [-Datasource] <Datasource[]> [[-Type] <DPMJobType[]> ] [[-Status] <JobStatusType[]> ] [[-From] <DateTime> ] [[-To] <DateTime> ] [[-Newest]] [[-AdhocJobs]] [-AllJobsInInterval] [-NoLimitOnJobCount] [ <CommonParameters>]

Parameter Set: GetJobsDSName
Get-DPMJob [-DatasourceName] <String[]> [[-DPMServerName] <String> ] [[-Type] <DPMJobType[]> ] [[-Status] <JobStatusType[]> ] [[-From] <DateTime> ] [[-To] <DateTime> ] [[-Newest]] [[-AdhocJobs]] [-AllJobsInInterval] [-NoLimitOnJobCount] [ <CommonParameters>]

Parameter Set: GetJobsPG
Get-DPMJob [-ProtectionGroup] <ProtectionGroup[]> [[-Type] <DPMJobType[]> ] [[-Status] <JobStatusType[]> ] [[-From] <DateTime> ] [[-To] <DateTime> ] [[-Newest]] [[-AdhocJobs]] [-AllJobsInInterval] [-NoLimitOnJobCount] [ <CommonParameters>]

Parameter Set: GetJobsPS
Get-DPMJob [-ProductionServer] <ProductionServer[]> [[-Type] <DPMJobType[]> ] [[-Status] <JobStatusType[]> ] [[-From] <DateTime> ] [[-To] <DateTime> ] [[-Newest]] [[-AdhocJobs]] [-AllJobsInInterval] [-NoLimitOnJobCount] [ <CommonParameters>]

Parameter Set: GetJobsPSName
Get-DPMJob [-ProductionServerName] <String[]> [[-DPMServerName] <String> ] [[-Type] <DPMJobType[]> ] [[-Status] <JobStatusType[]> ] [[-From] <DateTime> ] [[-To] <DateTime> ] [[-Newest]] [[-AdhocJobs]] [-AllJobsInInterval] [-NoLimitOnJobCount] [ <CommonParameters>]

Parameter Set: UpdateJobsDPM
Get-DPMJob [-Job] <Job[]> [ <CommonParameters>]

Detailed Description

The Get-DPMJob cmdlet gets current and previous jobs on a System Center 2012 – Data Protection Manager (DPM) server.

Parameters

-AdhocJobs

Indicates that this cmdlet retrieves only ad hoc jobs, not scheduled jobs.

Aliases

none

Required?

false

Position?

7

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-AllJobsInInterval

Displays all jobs.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Datasource<Datasource[]>

Specifies an array of data source objects for which this cmdlet gets jobs. A data source can be a file system share or volume for the Windows operating system, Microsoft SQL Server database, Microsoft Exchange Server storage group, Microsoft SharePoint farm, Microsoft Virtual Machine, DPM database, or system state that is a member of a protection group.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-DatasourceName<String[]>

Specifies an array of names of data sources.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-DPMServerName<String>

Specifies the name of a DPM server. This cmdlet gets jobs that run on the server that this parameter specifies.

Aliases

ComputerName,CN

Required?

false

Position?

1

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-From<DateTime>

Specifies the starting time in a range. The cmdlet retrieves jobs that fall into this range. Use the To parameter to specify the ending time in the range.

Aliases

none

Required?

false

Position?

4

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Job<Job[]>

Specifies an array of jobs that this cmdlet gets.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-Newest

Indicates that this cmdlet gets only the last job that ran on the filter objects.

Aliases

none

Required?

false

Position?

6

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-NoLimitOnJobCount

Indicates there is no limit on the job count to get.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ProductionServer<ProductionServer[]>

Specifies an array of computers on which DPM protection agents are installed.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-ProductionServerName<String[]>

Specifies an array names of computers on which DPM protection agents are installed.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-ProtectionGroup<ProtectionGroup[]>

Specifies an array of protection groups for which this cmdlet gets jobs. To obtain a ProtectionGroup object, use the Get-DPMProtectionGroup cmdlet.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-Status<JobStatusType[]>

Specifies an array of job status types.

Aliases

none

Required?

false

Position?

4

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-To<DateTime>

Specifies the ending time in a range. The cmdlet retrieves jobs that fall into this range. Use the From parameter to specify the starting time in the range.

Aliases

none

Required?

false

Position?

5

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Type<DPMJobType[]>

Specifies an array of DPM job types. Valid values are:

-- Recovery
-- InitialReplication
-- Validation
-- ShadowCopy
-- Replication
-- MediaErase
-- DriveCleaning
-- DetailedInventory
-- Verification
-- DatasetCopy
-- ArchiveFromSC
-- RecoveryTape
-- LibraryRescan
-- DumpMedia
-- MediaRecatalog
-- OnlineRecatalog
-- FastInventory
-- CopyDataFromVolume
-- StagingAreaRestore
-- SharePointImportAndExport
-- SharePointCatalog
-- CloudBackup
-- CloudToStagingAreaRestore
-- StagingAreaToPsRecovery
-- StagingAreaToPsRestore

Aliases

JobCategory,JobType

Required?

false

Position?

2

Default Value

none

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.

Outputs

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

Examples

Example 1: Retrieve recent jobs

This command returns the latest jobs run on the DPM server named Contoso-DPMServer.

PS C:\> Get-DPMJob -DPMServerName "Contoso-DPMServer" -Newest

Example 2: Retrieve recent jobs for a protection group

The first command uses the Get-ProtectionGroup cmdlet to retrieve the protection group, and then stores the group in the $PGroup variable.

The second command uses the Get-DPMJob cmdlet to retrieve the recent jobs for the protection group in $PGroup.

PS C:\> $PGroup = Get-DPMProtectionGroup -DPMServerName "Contoso-DPMServer"
PS C:\> Get-DPMJob -ProtectionGroup $PGroup

Get-DPMProtectionGroup

Restart-DPMJob

Stop-DPMJob