MicrosoftDocs / windows-powershell-docs

This repo is used to contribute to Windows 10, Windows Server 2016, and MDOP PowerShell module documentation.
Creative Commons Attribution 4.0 International
445 stars 599 forks source link

Is it me or does this not work on all the advertised input object types??? #434

Closed GrabASalad closed 5 years ago

GrabASalad commented 6 years ago

From the above i would expect that for each of the input objects, cluster, group, network, interface and so on, get-clusterparameter would return some data however it only seems to work for Resources and Resource types.

To try this for yourself execute the following powershell... Write-Output "##### Get Cluster Tests #####" Get-Cluster Write-Output "##### Get Cluster Parameter Tests #####" Get-Cluster | Get-ClusterParameter Write-Output "##### Get Cluster Group Tests #####" get-cluster | Get-Clustergroup Write-Output "##### Get Cluster Group Parameter Tests #####" get-cluster | Get-Clustergroup | Get-ClusterParameter Write-Output "##### Get Cluster Network Tests #####" get-cluster | Get-ClusterNetwork Write-Output "##### Get Cluster Network Parameter Tests #####" get-cluster | Get-ClusterNetwork | Get-ClusterParameter Write-Output "##### Get Cluster Network interface Tests #####" get-cluster | Get-ClusterNetworkInterface Write-Output "##### Get Cluster Network interface Parameter Tests #####" get-cluster | Get-ClusterNetworkInterface | Get-ClusterParameter Write-Output "##### Get Cluster Node Tests #####" get-cluster | Get-ClusterNode Write-Output "##### Get Cluster Node Parameter Tests #####" get-cluster | Get-ClusterNode | Get-ClusterParameter Write-Output "##### Get Cluster resource Tests #####" get-cluster | Get-ClusterResource Write-Output "##### Get Cluster resource Parameter Tests #####" get-cluster | Get-ClusterResource | Get-ClusterParameter | ft -groupby object Write-Output "##### Get Cluster resource Type Tests #####" get-cluster | Get-ClusterResourceType Write-Output "##### Get Cluster resource type Parameter Tests #####" get-cluster | Get-ClusterResourceType | Get-ClusterParameter -ErrorAction ignore | ft -groupby object Write-Output "##### Get Cluster Shared Volume Tests #####" get-cluster | Get-ClusterSharedVolume Write-Output "##### Get Cluster Shared Volume Parameter Tests #####" get-cluster | Get-ClusterSharedVolume | Get-ClusterParameter

My results from my sandpit environment...

Get Cluster Tests

Name


clustest

Get Cluster Parameter Tests
Get Cluster Group Tests

Available Storage
Cluster Group
TESTCLUSTER

Get Cluster Group Parameter Tests
Get Cluster Network Tests

Cluster Network 1
Cluster Network 2

Get Cluster Network Parameter Tests
Get Cluster Network interface Tests

clustest1 - Production
clustest2 - Production
clustest1 - Heartbeat
clustest2 - Heartbeat

Get Cluster Network interface Parameter Tests
Get Cluster Node Tests

clustest1
clustest2

Get Cluster Node Parameter Tests
Get Cluster resource Tests

Cluster Disk 1
Cluster IP Address
Cluster Name
IP Address 192.168.1.44
SQL Server (MSSQLSERVER)
SQL Server Agent (MSSQLSERVER)
testcluster

Get Cluster resource Parameter Tests

ClusterObject Name IsReadOnly ParameterType Value


Cluster Disk 1 DiskIdType False UInt32 0 Cluster Disk 1 DiskSignature False UInt32 0x8BE60DB9 Cluster Disk 1 DiskIdGuid False String
Cluster Disk 1 DiskRunChkDsk False UInt32 0 Cluster Disk 1 DiskUniqueIds False ByteArray {16, 0, 0, 0...} Cluster Disk 1 DiskVolumeInfo False ByteArray {1, 0, 0, 0...} Cluster Disk 1 DiskArbInterval False UInt32 3 Cluster Disk 1 DiskPath False String
Cluster Disk 1 DiskReload False UInt32 0 Cluster Disk 1 MaintenanceMode False UInt32 0 Cluster Disk 1 MaxIoLatency False UInt32 1000 Cluster Disk 1 CsvEnforceWriteThrough False UInt32 0 Cluster Disk 1 EnableBlockCache False UInt32 1 Cluster Disk 1 SnapshotDiffSize False UInt32 0 Cluster Disk 1 PoolId True String
Cluster Disk 1 VirtualDiskId True String
Cluster Disk 1 VirtualDiskName True String
Cluster Disk 1 VirtualDiskDescription True String
Cluster Disk 1 VirtualDiskHealth True UInt32 0 Cluster Disk 1 VirtualDiskState True UInt32 0 Cluster Disk 1 VirtualDiskProvisioning True UInt32 0 Cluster Disk 1 VirtualDiskResiliencyType True UInt32 0 Cluster Disk 1 VirtualDiskResiliencyColumns True UInt32 0 Cluster Disk 1 VirtualDiskResiliencyInter... True UInt32 0 Cluster IP Address Network False String Cluster Network 1 Cluster IP Address Address False String 192.168.1.109 Cluster IP Address SubnetMask False String 255.255.255.0 Cluster IP Address EnableNetBIOS False UInt32 2 Cluster IP Address OverrideAddressMatch False UInt32 0 Cluster IP Address EnableDhcp False UInt32 1 Cluster IP Address ProbePort False UInt32 0 Cluster IP Address ProbeFailureThreshold False UInt32 0 Cluster IP Address LeaseObtainedTime True DateTime 26/10/2018 07:01:04 Cluster IP Address LeaseExpiresTime True DateTime 26/10/2018 13:01:04 Cluster IP Address DhcpServer True String 192.168.1.200 Cluster IP Address DhcpAddress True String 192.168.1.109 Cluster IP Address DhcpSubnetMask True String 255.255.255.0 Cluster Name Name False String CLUSTEST Cluster Name DnsName False String clustest Cluster Name Aliases False String
Cluster Name RemapPipeNames False UInt32 0 Cluster Name HostRecordTTL False UInt32 1200 Cluster Name RegisterAllProvidersIP False UInt32 0 Cluster Name PublishPTRRecords False UInt32 0 Cluster Name ResourceData True ByteArray {1, 0, 0, 0...} Cluster Name StatusNetBIOS True UInt32 0 Cluster Name StatusDNS True UInt32 0 Cluster Name StatusKerberos True UInt32 0 Cluster Name CreatingDC True String ...nbyITDC01.allonbyit.local Cluster Name LastDNSUpdateTime True DateTime 25/10/2018 22:54:41 Cluster Name ObjectGUID True String ...da17fb44986e3f4b22b14458f Cluster Name DnsSuffix True String allonbyit.local Cluster Name ADAware True UInt32 1 IP Address 192.168.1.44 Network False String Cluster Network 1 IP Address 192.168.1.44 Address False String 192.168.1.44 IP Address 192.168.1.44 SubnetMask False String 255.255.255.0 IP Address 192.168.1.44 EnableNetBIOS False UInt32 1 IP Address 192.168.1.44 OverrideAddressMatch False UInt32 0 IP Address 192.168.1.44 EnableDhcp False UInt32 0 IP Address 192.168.1.44 ProbePort False UInt32 0 IP Address 192.168.1.44 ProbeFailureThreshold False UInt32 0 IP Address 192.168.1.44 LeaseObtainedTime True DateTime 01/01/0001 00:00:00 IP Address 192.168.1.44 LeaseExpiresTime True DateTime 01/01/0001 00:00:00 IP Address 192.168.1.44 DhcpServer True String 255.255.255.255 IP Address 192.168.1.44 DhcpAddress True String 0.0.0.0 IP Address 192.168.1.44 DhcpSubnetMask True String 255.0.0.0 SQL Server (MSSQLSERVER) VirtualServerName False String TESTCLUSTER SQL Server (MSSQLSERVER) InstanceName False String MSSQLSERVER SQL Server (MSSQLSERVER) VerboseLogging False UInt32 0 SQL Server (MSSQLSERVER) SqlDumperDumpFlags False UInt32 0 SQL Server (MSSQLSERVER) SqlDumperDumpPath False String
SQL Server (MSSQLSERVER) SqlDumperDumpTimeOut False UInt32 0 SQL Server (MSSQLSERVER) SqlPreStartupActionsFlags False UInt32 0 SQL Server (MSSQLSERVER) FailureConditionLevel False UInt32 3 SQL Server (MSSQLSERVER) HealthCheckTimeout False UInt32 60000 SQL Server Agent (MSSQLSER... VirtualServerName False String testcluster SQL Server Agent (MSSQLSER... InstanceName False String MSSQLSERVER testcluster Name False String TESTCLUSTER testcluster DnsName False String testcluster testcluster Aliases False String
testcluster RemapPipeNames False UInt32 0 testcluster HostRecordTTL False UInt32 1200 testcluster RegisterAllProvidersIP False UInt32 0 testcluster PublishPTRRecords False UInt32 1 testcluster ResourceData True ByteArray {1, 0, 0, 0...} testcluster StatusNetBIOS True UInt32 0 testcluster StatusDNS True UInt32 0 testcluster StatusKerberos True UInt32 0 testcluster CreatingDC True String ...nbyITDC02.allonbyit.local testcluster LastDNSUpdateTime True DateTime 25/10/2018 13:31:49 testcluster ObjectGUID True String ...eb6bf834888c18bd792fd80f3 testcluster DnsSuffix True String allonbyit.local testcluster ADAware True UInt32 1

Get Cluster resource Type Tests

Name DisplayName


DFS Replicated Folder DFS Replicated Folder
DHCP Service DHCP Service
Disjoint IPv4 Address Disjoint IPv4 Address
Disjoint IPv6 Address Disjoint IPv6 Address
Distributed File System Distributed File System
Distributed Network Name Distributed Network Name
Distributed Transaction Coordinator Distributed Transaction Coordinator
File Server File Server
File Share Witness File Share Quorum Witness
Generic Application Generic Application
Generic Script Generic Script
Generic Service Generic Service
IP Address IP Address
IPv6 Address IPv6 Address
IPv6 Tunnel Address IPv6 Tunnel Address
iSCSI Target Server iSCSI Target Server
Microsoft iSNS iSNS Cluster Resource
MSMQ (Resource Type Unavailable)
MSMQTriggers (Resource Type Unavailable)
Nat Network Address Translator
Network File System Network File System
Network Name Network Name
Physical Disk Physical Disk
Provider Address Hyper-V Network Virtualization Provider Address
Scale Out File Server Scale Out File Server
SQL Server SQL Server
SQL Server Agent SQL Server Agent
Storage Pool Storage Pool
Task Scheduler Task Scheduler
Virtual Machine Virtual Machine
Virtual Machine Configuration Virtual Machine Configuration
Virtual Machine Replication Broker Virtual Machine Replication Broker
WINS Service WINS Service

Get Cluster resource type Parameter Tests

ClusterObject Name IsReadOnly ParameterType Value


Distributed Network Name DeleteVcoOnResCleanup False UInt32 0 Distributed Transaction Co... ClusterDefaultResource False String
Distributed Transaction Co... ClusterDefaultVirtualServer False String
Network Name DeleteVcoOnResCleanup False UInt32 0 Physical Disk SnapshotAgeLimit False UInt32 7 Virtual Machine MigrationExcludeNetworks False String
Virtual Machine MigrationNetworkOrder False String
Virtual Machine MoveTypeThreshold False UInt32 1000 Virtual Machine ReportNetworkFailure False UInt32 1

Get Cluster Shared Volume Tests
Get Cluster Shared Volume Parameter Tests

Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

o0nj commented 5 years ago

@officedocsbot unassign @e0i @officedocsbot unassign @yogkumgit

yogkumgit commented 5 years ago

@officedocsbot assign @yogkumgit

get-itips commented 5 years ago

Hello @GrabASalad Thanks for your feedback. We appreciate it. Piping a cmdlet into another not always returns results on every scenario, on the other hand, if the cmdlet would not accept certain input object, for example Microsoft.FailoverClusters.PowerShell.ClusterNetwork, it would otherwise throw an error, not an empty result. So it seems that in this specific scenario that you showed, there are no parameters to inform by the cmdlet. Hope this information helps you. Thank you

yogkumgit commented 5 years ago

@get-itips Thank you very much for the contribution and sharing this explanation. @GrabASalad Hope this comment is helpful for you. Thanks for taking out some time to open the issue. Appreciate and encourage you to do the same in future also.

yogkumgit commented 5 years ago

@officedocsbot close