Just looking for a bit of guidance. I’m trying to have PowerShell give me a list of rogue volumes (volumes not attached to any instance) but the example Amazon is giving isn’t working:
I get this:
"Get-EC2Volume : Cannot bind parameter ‘Filters’. Cannot convert the “System.Collections.Hashtable” value of type “Syste
m.Collections.Hashtable” to type “Amazon.EC2.Model.Filter”.
At line:1 char:23
OK, did a bit more digging. I suspect you’re using an older version of the AWS SDK (one of the v1.x versions.) The API changed a bit in v2, which you can download from AWS SDK for .NET
Assuming you do need to use v1 for some reason, try changing “Values” to “Value” in your hashtable. Either syntax (passing the hashtable directly to the -Filters parameter, or using New-Object first) will probably work.
Edit: Another v1 syntax which might help, if the hashtables don’t: