Edit

Share via


Get-ClusterDiagnosticInfo

Gets diagnostics for a cluster a cluster that contains VMs and produces a zip file containing the data.

Syntax

Write

Get-ClusterDiagnosticInfo
    [[-WriteToPath] <String>]
    [[-Cluster] <String>]
    [[-ZipPrefix] <String>]
    [-HoursOfEvents <Int32>]
    [-IncludeEvents]
    [<CommonParameters>]

Read

Get-ClusterDiagnosticInfo
    -ReadFromPath <String>
    [<CommonParameters>]

Description

The Get-ClusterDiagnosticInfo cmdlet gets diagnostics for a cluster that contains virtual machines and produces a zip file containing the data.

Examples

Example 1: Write diagnostic info to the specified path

Get-ClusterDiagnosticInfo -WriteToPath "C:\Users\MyUser\HealthTest\"

This command gets and writes the cluster Diagnostics to the folder C:\Users\MyUser\HealthTest\.

Parameters

-Cluster

Specifies the name of the cluster the cmdlet gets.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

Write
Position:1
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-HoursOfEvents

Specifies the number of hours in the past that this cmdlet gathers system event logs.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

Write
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-IncludeEvents

Indicates that this cmdlet gathers system event logs.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

Write
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ReadFromPath

Specifies the path to read from when examining previously collected log files.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

Read
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-WriteToPath

Specifies the path to create the ZIP file that contains all of the logs.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

Write
Position:0
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ZipPrefix

Specifies the name to prepend to the ZIP file that is produced.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

Write
Position:2
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.