Author Posts

May 18, 2015 at 2:19 pm

Hello team,

I need to get all the share drives from a list of 283 servers running:

18 servers – windows server 2003
218 servers – windows server 2008
46 servers – windows server 2012

I will use get-wmiobject -class win32_share to get the information or get-ciminstance -classname win32_share, then exporting it to a .txt file.

There are some servers I don't have access and when I get an error message the command stops, any idea how can I implement this process more efficiently.

Maybe an script, I new to PowerShell with very basic level of knowledge.

Thank you!

May 18, 2015 at 2:38 pm

Sure. You can make a single Get-WmiObject call, and just add -AsJob. It'll run each computer individually.

May 19, 2015 at 9:54 am

Thank you Don, that was a big help