Syntax
Get-ErrorReport [-ProblemDescription] <String> [-ProblemScriptTimeoutSeconds] <Double> [[-Destination] <DirectoryInfo>] [-ProblemScript] <ScriptBlock> [-DontIncludeServerLogs] [<CommonParameters>]Related Commands
Online versionDetailed Description
This cmdlet collects debugging information in order to identify a problem in the work environment. The cmdlet runs a script that reproduces the problem and captures any relevant information in a single .zip file. Then, you can send the .zip file to the PowerCLI support for analysis.Parameters
Return Type
Zero or more FileInfo objectsNotes
Examples
-------------- Example 1 --------------
$script = { Connect-VIServer 10.23.34.36 $vapp = Get-VApp Get-VM VM -Location $vapp } $script | Get-ErrorReport -ProblemScriptTimeoutSeconds 10 -ProblemDescription "No VM is returned. There are several VMs in this vApp. The vApp is in a DRS-enabled cluster. All VMs part of the vApp are expected to be returned." -Destination 'D:\bug reports'
Saves the script that reproduces the error into a variable and passes the script to Get-ErrorReport. The command provides a problem description, a destination for storing the error report, and a time period after which the script is considered non-responding.