Ad Widget

Collapse

Discovery Rule to get list of Web Sites and their Port Bindings

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • abel5405
    Member
    • Jan 2019
    • 47

    #1

    Discovery Rule to get list of Web Sites and their Port Bindings

    Greetings All,
    I'm using one of the templates for IIS that does a discovery of the Web Sites and their status and it appears to work great. I am how ever having an issue with trying to do a discovery of their ports and then have a Prototype Item created to check if the port is open. I can't seem to get the powershell command correctly to get a list of "WebSite", "PortNumber". Does anybody have a script or discovery rule that does this? Many thanks in advance for your help.

    v/r
    Chris
  • abel5405
    Member
    • Jan 2019
    • 47

    #2
    Re-visiting this question here, I found a script that gives me the information I am looking for but need help turning it into a discovery rule.

    Script:
    Import-Module WebAdministration
    Get-ChildItem -Path IIS:\Sites | findstr “http*"

    It gives me the following information without headers:
    "Name of the Web Site", "Site ID", "Site Status", "Port Binding"

    I am already using a script that get's "Site Name" and "Site Status" but would very much like to add "Site Port Binding" then create an item as to the port status and a trigger as to when the port is not available. Any help would be greatly appreciated!

    v/r
    Chris

    Comment

    Working...