Tôi đang gặp lỗi Powershell như thế này:
PS C:\mydirectory> $Error[0]
Get-WmiObject :
At line:143 char:13
+ $Disk = Get-WmiObject MSCluster_Disk -ComputerName $Resource.OwnerNode -Auth ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [Get-WmiObject], COMException
+ FullyQualifiedErrorId : GetWMICOMException,Microsoft.PowerShell.Commands.GetWmiObjectCommand
Có cách nào để tôi có thể tránh lệnh gây ra lỗi (nghĩa là $Disk = Get-WmiObject MSCluster_Disk ...
) bị cắt ngắn trong thông báo lỗi không?