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

Best way to update a monitoring configuration for SNMP extension?

AntonioSousa
DynaMight Guru
DynaMight Guru

I need to add/remove devices from a certain monitoring configuration for a certain SNMP extension.

Now, an existing monitoring configuration can be read, but when read, it doesn't show the community strings of existing devices. It does show some random number in the middle:

 

        {
          "ip": "192.168.1.1",
          "port": 161,
          "authentication": {
            "type": "SNMPv2c",
            "community": "***346***"
          }
        }

 

 

Every time I get the data, the numbers change. Does posting this data back to the API mean the community string will be maintained? What care has to be taken, so that Dynatrace doesn't interpret this Community string linearly?

BTW, I'm thinking in using the /extensions/{extensionName}/monitoringConfigurations/{configurationId}
endpoint. Or is there any other better way?

Antonio Sousa
3 REPLIES 3

witold_turzansk
Dynatrace Promoter
Dynatrace Promoter

Hi,

community string contains a secret value, so API returns a temporary replacement. To prevent the secret value from being modified, the configuration should be updated with exactly the same temporary value.

 

BR,
Witold

AntonioSousa
DynaMight Guru
DynaMight Guru

@witold_turzansk,

Thanks for your answer! Given that the reply is different, or at least it seems, which limitations for reusing the temporary value apply?

  • Is it time driven, so that if I submit the update request in a certain amount of time, it will still apply?
  • Is it request driven, so that after each "GET", I have to do an update following?
  • Combination of the above?
  • Other?
Antonio Sousa

The starred value for the secret is valid until the next update, so after first use in an update request it must be read again.

Featured Posts