< Back
Wait-NsxControllerJob
Post
NAME Wait-NsxControllerJob
SYNOPSIS
Wait for the specified controller job until it succeeds or fails.
SYNTAX
Wait-NsxControllerJob [-JobId] <String> [[-WaitTimeout] <Int32>] [-FailOnTimeout] [[-Connection] <PSObject>]
[<CommonParameters>]
DESCRIPTION
Attempt to wait for the specified controller deployment succeeds or fails.
Wait-NsxControllerJob defaults to timeout at 300 seconds, when the user
is prompted to continuing waiting of fail. If immediate failure upon
timeout is desirable (eg within script), then the $failOnTimeout switch can
be set.
PARAMETERS
-JobId <String>
Job Id string as returned from the api
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-WaitTimeout <Int32>
Seconds to wait before declaring a timeout. Timeout defaults to 800 seconds, which is longer than the NSX
internal timeout and rollback of a failed controller deployment of around 720 seconds.
Required? false
Position? 2
Default value 800
Accept pipeline input? false
Accept wildcard characters? false
-FailOnTimeout [<SwitchParameter>]
Do we prompt user an allow them to reset the timeout timer, or throw on timeout
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
-Connection <PSObject>
PowerNSX Connection object
Required? false
Position? 3
Default value $defaultNSXConnection
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Wait-NsxControllerJob -Jobid jobdata-1234
Wait for controller job jobdata-1234 up to 300 seconds to complete
successfully or fail. If 300 seconds elapse, then prompt for action.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Wait-NsxControllerJob -Jobid jobdata-1234 -TimeOut 400 -FailOnTimeOut
Wait for controller job jobdata-1234 up to 40 seconds to complete
successfully or fail. If 400 seconds elapse, then throw an error.
RELATED LINKS
SYNOPSIS
Wait for the specified controller job until it succeeds or fails.
SYNTAX
Wait-NsxControllerJob [-JobId] <String> [[-WaitTimeout] <Int32>] [-FailOnTimeout] [[-Connection] <PSObject>]
[<CommonParameters>]
DESCRIPTION
Attempt to wait for the specified controller deployment succeeds or fails.
Wait-NsxControllerJob defaults to timeout at 300 seconds, when the user
is prompted to continuing waiting of fail. If immediate failure upon
timeout is desirable (eg within script), then the $failOnTimeout switch can
be set.
PARAMETERS
-JobId <String>
Job Id string as returned from the api
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-WaitTimeout <Int32>
Seconds to wait before declaring a timeout. Timeout defaults to 800 seconds, which is longer than the NSX
internal timeout and rollback of a failed controller deployment of around 720 seconds.
Required? false
Position? 2
Default value 800
Accept pipeline input? false
Accept wildcard characters? false
-FailOnTimeout [<SwitchParameter>]
Do we prompt user an allow them to reset the timeout timer, or throw on timeout
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
-Connection <PSObject>
PowerNSX Connection object
Required? false
Position? 3
Default value $defaultNSXConnection
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Wait-NsxControllerJob -Jobid jobdata-1234
Wait for controller job jobdata-1234 up to 300 seconds to complete
successfully or fail. If 300 seconds elapse, then prompt for action.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Wait-NsxControllerJob -Jobid jobdata-1234 -TimeOut 400 -FailOnTimeOut
Wait for controller job jobdata-1234 up to 40 seconds to complete
successfully or fail. If 400 seconds elapse, then throw an error.
RELATED LINKS