Does Get-stat not work in the latest (12/26) release?
It seems like I used to be able to do something like this in the previous version...
Get-Stat -Entity $myVM -Start (get-date).AddDays(-30) -CPU -Finish (get-date)
To get the last 30 days of data, but now it seems that no matter what I do, it only gives me the last hour's worth of stats. It is almost as if it was getting stats from Virtual Center before, and now it only get's stats directly from the host.
Does anyone else have this problem? Or better yet, a solution.
After further experimentation it works better when I set the -MaxSamples option to a large number and the IntervalMins to a larger number e.g.
get-stat $vm -start (get-date).AddDays(-30) -CPU -stat -cpu.usage.average -IntervalMins 60
I thought it was supposed to default to the smallest interval possible for the data period selected.