is anyone familiar with a way to get the Application pool that is associated with a process ID ? I am using Win32_Process to query the W3WP services and return the PID now
On Windows Server 2008 this has changed.
in systemroot\system32\inetsrv you find the appcmd.exe
using
appcmd list wp
you get a list of all the worker processes and which apppool they are serving.
You might need to run this in a shell with Administrator privileges.