Export (0) Print
Expand All
Expand Minimize

Suspend-CMAlert

Updated: February 7, 2014

Applies To: System Center 2012 R2 Configuration Manager

Suspend-CMAlert

Suspends monitoring alerts.

Syntax

Parameter Set: SearchByIdMandatory
Suspend-CMAlert -Id <String> -SkipUntil <DateTime> [-Comment <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: SearchByNameMandatory
Suspend-CMAlert -Name <String> -SkipUntil <DateTime> [-Comment <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: SearchByValueMandatory
Suspend-CMAlert -InputObject <IResultObject> -SkipUntil <DateTime> [-Comment <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]




Detailed Description

The Suspend-CMAlert cmdlet suspends monitoring of an alert until a specified date. At that time, Microsoft System Center 2012 Configuration Manager updates the state of the alert. You can suspend an alert only when it is enabled. If you do not specify the SkipUntil parameter, the alert is suspended indefinitely.

Parameters

-Comment<String>

Specifies a comment to add to the alert. You can use the comment to record the explanation for suspending the alert.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-Id<String>

Specifies an alert identifier. You can obtain the identifier of an alert by using the Get-Alert cmdlet.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-InputObject<IResultObject>

Specifies a CMAlert object. To obtain a CMAlert object, use the Get-CMAlert cmdlet.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-Name<String>

Specifies the name of an alert. You can obtain the name of an alert by using Get-CMAlert.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-SkipUntil<DateTime>

Specifies a specific date and time to start evaluation of the alert. Enter a DateTime object or a string that can be converted to a time, such as April 19, 2012 15:00, 12/31/2013 9:00 PM, or 3am. To obtain a DateTime object, use the Get-Date cmdlet. For more information, type Get-Help Get-Date.

If you do not specify an element of the DateTime object, such as seconds, that element of the job trigger is not changed. If the original job trigger did not include a DateTime object and you omit an element, the job trigger is created with the corresponding element from the current date and time.

DateTime objects, and strings that are converted to DateTime objects, are automatically adjusted to be compatible with the date and time formats selected for the local computer in Region and Language in Control Panel.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-Confirm

Prompts you for confirmation before executing the command.


Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WhatIf

Describes what would happen if you executed the command without actually executing the command.


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.

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: Suspend an alert by using ID

This command suspends an alert that has the Id 16777219 until the time specified by SkipUntil, and adds a comment to the alert.


PS C:\> Suspend-CMAlert -Id "16777219" -Comments "Postponing alert evaluation" -SkipUntil "Wednesday, August 20, 2012 4:03:17 PM"

Example 2: Suspend an alert by using alert object variable

The first command gets the alert object that has the Id 16777221 and stores the object in the $AlertObj variable.

The second command suspends the alert stored in $AlertObj until the time specified by SkipUntil, and adds a comment to the alert.


PS C:\> $AlertObj = Get-CMAlert -Id "16777221"
PS C:\> Suspend-CMAlert -InputObject $ AlertObj -Comments "Postponing alert evaluation" -SkipUntil "4/8/2012 8:04:39 PM"

Related topics

 
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft