3 Replies Latest reply on May 30, 2014 3:43 PM by Aurora Hermida

    ADDM query that shows information about a network device

      Share This:

      HI,

       

      I need to create a query that shows the following information about a network device: ssylocation, managment IP address, sysname, sysobjectid and syslocation. I have two that show me part of the information I need.

       

      One query is:

       

      SEARCH NetworkDevice

         WHERE

      #InferredElement:Inference:Primary:DeviceInfo.syslocation AND

      #InferredElement:Inference:Primary:DeviceInfo.sysobjectid

         SHOW

      type AS 'TYPE',

      name AS 'HOSTNAME',

      #InferredElement:Inference:Primary:DeviceInfo.sysname AS 'FQDN',

      #InferredElement:Inference:Primary:DeviceInfo.sysobjectid AS 'SYSOID',

      serial AS 'SERIALID',

      #InferredElement:Inference:Primary:DeviceInfo.syslocation AS 'SYSLOC',

      #InferredElement:Inference:Associate:DiscoveryAccess.endpoint AS 'IP_ADMIN'

       

      And the other query is:

       

      SEARCH NetworkDevice TRAVERSE InferredElement:::DiscoveryAccess ORDER BY discovery_endtime PROCESS WITH WHERE (end_state = 'GoodAccess') SHOW endpoint


      What I need is a single query that show me all the information together.

      I really appreciate any help.


      Thanks in advance

      Best Regards

        • 1. Re: ADDM query that shows information about a network device

          Hi Aurora,

           

          This query might help you to get expected result.

           

          SEARCH NetworkDevice

          WHERE

          #InferredElement:Inference:Primary:DeviceInfo.syslocation

          AND

          #InferredElement:Inference:Primary:DeviceInfo.sysobjectid

          SHOW type AS 'TYPE', name AS 'HOSTNAME',

          #InferredElement:Inference:Primary:DeviceInfo.sysname AS 'FQDN',

          #InferredElement:Inference:Primary:DeviceInfo.sysobjectid AS 'SYSOID',

          serial AS 'SERIALID',

          #InferredElement:Inference:Primary:DeviceInfo.syslocation AS 'SYSLOC',

          #InferredElement:Inference:Associate:DiscoveryAccess.endpoint AS 'IP_ADMIN' PROCESS WITH FLAGS(no_segment)

          WHERE (NODECOUNT(TRAVERSE InferredElement:Inference:Associate:DiscoveryAccess WHERE end_state = 'GoodAccess'))

          SHOW type, name,

          #InferredElement:Inference:Primary:DeviceInfo.sysname AS 'FQDN',

          #InferredElement:Inference:Primary:DeviceInfo.sysobjectid AS 'SYSOID', serial,

          #InferredElement:Inference:Primary:DeviceInfo.syslocation AS 'SYSLOC',

          #InferredElement:Inference:Associate:DiscoveryAccess.endpoint AS 'IP_ADMIN',

          #InferredElement:Inference:Associate:DiscoveryAccess.endpoint AS 'Endpoint'

          Regards,

          Sourabh

          1 of 1 people found this helpful
          • 2. Re: ADDM query that shows information about a network device
            Andrew Waters

            That is not a great query, you build a show list then chuck it away. It also does not merge things together - you can get DAs which do not have good access in the results.

             

            What are you actually trying to report upon?

            • 3. Re: ADDM query that shows information about a network device

              Hi,

              Thanks for all the replies and the help.

              This is the query I was looking for:

               

              SEARCH NetworkDevice

              TRAVERSE InferredElement:Inference:Associate:DiscoveryAccess

              WHERE end_state = "GoodAccess"

              SHOW

              #Associate:Inference:InferredElement:NetworkDevice.type,

              #Associate:Inference:InferredElement:NetworkDevice.name,

              #DiscoveryAccess:DiscoveryAccessResult:DiscoveryResult:DeviceInfo.sysname,

              #DiscoveryAccess:DiscoveryAccessResult:DiscoveryResult:DeviceInfo.sysobjectid,

              #DiscoveryAccess:DiscoveryAccessResult:DiscoveryResult:DeviceInfo.serial,

              #DiscoveryAccess:DiscoveryAccessResult:DiscoveryResult:DeviceInfo.syslocation,

                  endpoint

               

              Best Regards