cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

SNMP extension v2 topology awareness

Yosi_Neuman
DynaMight Guru
DynaMight Guru

Hi guys,

After creating SNMP extension and collecting metrics, we have set custom event for alerting on those metrics and every thing is awesome!

But (is there always but in our world?) the custom/resource problems are open with environment impact and not under the device IP.

The question here is how we can add topology awareness from the extension in which the IP of the device will create custom device and the problem will be associate with it and the impact will show this custom device and not the whole environment? 

Didn't find any explanation in documentation, did I missed anything ?

Thanks in advance and be safe 

Yos     

dynatrace certificated professional - dynatrace master partner - Matrix Soft Ware Division - Israel
8 REPLIES 8

Mike_L
Dynatrace Guru
Dynatrace Guru

Hi,

If you create a generic entity in the settings UI or in the YAML and map the metrics to there the problem will be assigned to that entity instead of to the environment. That way you can even create different entities per interface for example and create relationships between the interfaces and the device.

Mike

Mike

Hi @Mike_L 

Thanks for your prompt answer !

Can you please elaborate on how to create the generic entity from UI or yaml ?

My yaml file look like:

Yosi_Neuman_1-1641295873152.png

 

What do i miss in the yaml that will create generic entity?

Thanks in advance

Yos 

dynatrace certificated professional - dynatrace master partner - Matrix Soft Ware Division - Israel

This is the topology section of the generic snmp device extension. It creates two entities with a relationship between them:

 

topology:
  types:
    - name: snmp:com_dynatrace_extension_snmp_generic_device
      displayName: Generic SNMP Device
      enabled: true
      rules:
      - idPattern: snmp_generic_device_{device.address}
        sources:
        - sourceType: Metrics
          condition: $prefix(com.dynatrace.extension.snmp-generic-device)
        attributes:
        - pattern: '{sys.contact}'
          key: system_contact
          displayName: System Contact
        - pattern: '{sys.name}'
          key: system_name
          displayName: Device Name
        - pattern: '{device.address}'
          key: system_ip
          displayName: Device Address
        - pattern: '{sys.description}'
          key: system_descr
          displayName: Description
        - pattern: '{sys.location}'
          key: system_location
          displayName: Location
        - pattern: '{activation.tag}'
          key: activation_tag
          displayName: Tag
        - pattern: '{device.port}'
          key: device_port
          displayName: Port
        - pattern: '{if.count}'
          key: interface_count
          displayName: Network Interface Count
        requiredDimensions: []
        instanceNamePattern: Network device {sys.name} @ {device.address}:{device.port}

    - name: snmp:com_dynatrace_extension_snmp_generic_device_interface
      displayName: Generic SNMP Device Network Interface
      enabled: true
      rules:
      - idPattern: snmp_generic_device_if_{device.address}-{if.idx}
        sources:
        - sourceType: Metrics
          condition: $prefix(com.dynatrace.extension.snmp-generic-device.if)
        attributes:
        - pattern: '{device.address}'
          key: deviceAddress
          displayName: Network device address
        - pattern: '{if.promiscuousmode}'
          key: promiscuousMode
          displayName: PromiscuousMode
        - pattern: '{if.speed}'
          key: speed
          displayName: Interface Speed
        - pattern: '{if.type}'
          key: type
          displayName: Interface Type
        - pattern: '{if.operstatus}'
          key: opStatus
          displayName: Operational Status
        - pattern: '{if.mtu}'
          key: mtu
          displayName: MTU
        - pattern: '{if.descr}'
          key: description
          displayName: Description
        - pattern: '{if.adminstatus}'
          key: adminStatus
          displayName: Admin Status
        requiredDimensions: []
        instanceNamePattern: Network interface {if.descr} @ {device.address}

  relationships:
    - typeOfRelation: CHILD_OF
      fromType: snmp:com_dynatrace_extension_snmp_generic_device_interface
      toType: snmp:com_dynatrace_extension_snmp_generic_device
      enabled: true
      sources:
      - sourceType: Metrics
        condition: $prefix(com.dynatrace.extension.snmp-generic-device)
Mike

Hi @Mike_L 

And just to paste in the end of the extension.yaml  or its should be under the snmp section? or any other way? 

Tried to paste this at the end of the extension.yaml did not work for us (i.e. problem still marked as impact on environment level 

Yos

dynatrace certificated professional - dynatrace master partner - Matrix Soft Ware Division - Israel

Hi, it just goes at the end of the yaml. You cannot copy that exact topology definition but change it to be your own based on the metrics you're bringing back from your extension.

If you don't manage to do it in the yaml you can also do it in the UI: https://www.dynatrace.com/support/help/how-to-use-dynatrace/metrics/metric-ingestion/topology-model/...

Mike

Hi @Mike_L 

Thanks for the gaudiness with that.

After "few" tests we succeed to set topology from UI and then understood what to put in yaml.

From our point of view the part about topology in extension v2 documentation must be added.

All the best and stay safe

Yos  

dynatrace certificated professional - dynatrace master partner - Matrix Soft Ware Division - Israel

motdde
Participant

Hello, @Yosi_Neuman @Mike_L is there a way to visualize these relationships (Devices and Interfaces) on Smartscape topology?

Mike_L
Dynatrace Guru
Dynatrace Guru

Not currently. In the new Dynatrace experience announced at Perform there is a new smartscape app which will be able to include any entity.

Mike

Featured Posts