Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update PrivateCloud.DiagnosticInfo.psm1 #130

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1916,7 +1916,7 @@ function Get-SddcDiagnosticInfo
# _C_ token will be replaced with node fqdn for cimsession/computername callouts
# _N_ token will be replaced with node non-fqdn
$CmdsToLog = 'Get-HotFix -ComputerName _C_',
'Get-NetAdapter -CimSession _C_',
'Get-NetAdapter -CimSession _C_ | Select-Object ifName, ifDesc, ifIndex, Status, MACAddress, LinkSpeed, PSComputerName, PnPDeviceID, DriverName, DriverVersion, MtuSize, Hidden, FullDuplex, Speed, NdisVersion',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the intend behind this changes. I do not want us to do specialized changes. This data collection needs to be generic enough so we can specialize data processing after log collection. So please refrain from doing it if you do not have strong reason for the same.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thats not the problem with this change.

The way these cmds-to-log are handled is that we take the native object output and do two things:

  1. take them through the default txt renderer -> .txt
  2. export-clixml them -> .xml

If there's a desire for another output form to be available by default, I'd suggest either fc or fl, i.e.

$cmdoutput | fc * > cmd.fc.txt
$cmdoutput | fl * > cmd.fc.txt

The problem is that there is a degree of personal preference to these, and rendering these 10x different ways is inefficient. However, there may be some merit to choosing one to make available to point-and-click open, rather than requiring import-clixml | <some preferred/programmatic rendering>.

The reason the default .txt render is useful is that thats the only way to access the cmdlet author's preference. This would be an and-another, not replacement of it.

'Get-NetAdapterAdvancedProperty -CimSession _C_',
'Get-NetAdapterBinding -CimSession _C_',
'Get-NetAdapterChecksumOffload -CimSession _C_',
Expand Down