I've a PS script which I use to keep track of my VMWare ESX servers. I need to run it as a service so that I'm not permanently logged on. Unfortunately, the script runs more slowly if I use a runspace inside a service rather than just running the script through the powershell console. It's taking 2-5 minutes to make calls to the VMWare web service instead of a second or so.
Is there some sort of magic I should be using when I invoke the runspace?