Get the Installed Path for a program on Win Svr

This topic contains 5 replies, has 3 voices, and was last updated by  postanote 4 months, 1 week ago.

  • Author
    Posts
  • #89597

    Clive Richardson
    Participant

    I've been testing out various solutions using Powershell to list installed program information, which is fine more most information such as version info, etc but the key piece of info I'm looking for is the InstalledLocation/InstalledDir. It seems that in most cases, this particular property is simply not available for most programs. Given a program name (displayname), can someone suggest a way to reliably/efficiently get a program's installation directory/path (remote to other servers)?

    Thanks in advance

  • #89600

    Simon B
    Participant
    • #89602

      Clive Richardson
      Participant

      Thank you Simon. Under the covers, that solution still uses Get-ChildItem, which is what I've been using. The problem is that many of the third-party installers don't set the InstallPath property. So, nice procedure but doesn't fix my issue.

    • #89657

      postanote
      Participant

      I have a few ITIL level questions (as these lead to a lot of places to look):

      1 – Are you saying, these 3rdP installers do not even register themselves in the Add Remove Programs and do not provide an uninstall path? If so, then, how would you uninstall them?
      2 – Do you have a ITIL/CMDB SOP, that list the allowed to be installed applications, aka whitelist?
      3 – How do these apps get distributed / installed?
      4 – Do, you have a ITIL/CMDB SOP, the scan's and records the systems environment variables and subdirs of those?
      ProgramData C:\ProgramData
      ProgramFiles C:\Program Files
      ProgramFiles(x86) C:\Program Files (x86)
      ProgramW6432 C:\Program Files
      5 – Do, you have a ITIL/CMDB SOP, the scan's the systems registry for all uninstall strings?
      6 – What about AV scan polices, does your ITIL/CMDB policy define scan locations? (I ask this, because if the AV is scanning, then it should have a log of what it scanned and the result of that scan.)

  • #89603

    Simon B
    Participant

    maybe a combo of a wmi query and a registry query needed.

  • #89609

    Simon B
    Participant

    Not used it but this looks interesting a installer module for powershell

    https://psmsi.codeplex.com/

You must be logged in to reply to this topic.