So - I'm using PowerCLI 5.8 release 1, and I'm writing a simple script - but not getting the correct feedback...
a single vCenter (5.5 appliance, build 1750787), multiple Hosts, but I've cleaved off 2 hosts for a proof-of-concept/test cluster (the cluster is named POC).
$POC1=Get-Cluster POC | Get-VMhost
foreach ($esx in $POC1) {Get-VMHostNetworkAdapter - Physical -Name vmnic1}
The issue I keep running into is that while line-1 runs perfectly, showing me the 2 hosts in the POC cluster, However line-2 shows me all vmnic1's from ALL hosts connected to the vCenter. I know I'm missing something - probably simple. I can't find anything in the syntax. the only thing I can think of would be the $esx is wrong. I've tried $VMHost, and a few others, but all with the same result. what am I missing? (aside from a few marbles).