Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Retrieving dll path of a running process

I have an application that uses a .dll file, there are 2 different locations for the file and I need to find out which one it is using on over 200 machines.

I am very new to power shell and have tried Get-Process method but it does not supply the information I need, is there another way to retrieve this in power shell?

like image 339
nGX Avatar asked Jan 27 '12 22:01

nGX


1 Answers

This article gives one approach using a WMI provider call. You could use the provided Function at the end. If your just looking for something quick and dirty this would work.

Digging in a little more, This might be what you want:

$modules = Get-Process | Where { $_.ProcessName -eq "process.name" } | Select Modules
$modules.Modules

Replace process.name with your process name

like image 195
GrayWizardx Avatar answered Oct 08 '22 23:10

GrayWizardx