feat(agent): Deprecate active usage of netsnmp translator (#12358)
This commit is contained in:
parent
8d78c5fbdc
commit
c883673cdb
|
|
@ -84,7 +84,7 @@
|
|||
## If set to true, do no set the "host" tag in the telegraf agent.
|
||||
omit_hostname = false
|
||||
|
||||
## Method of translating SNMP objects. Can be "netsnmp" which
|
||||
## Method of translating SNMP objects. Can be "netsnmp" (deprecated) which
|
||||
## translates by calling external programs snmptranslate and snmptable,
|
||||
## or "gosmi" which translates using the built-in gosmi library.
|
||||
# snmp_translator = "netsnmp"
|
||||
|
|
|
|||
|
|
@ -458,6 +458,14 @@ func (c *Config) LoadConfigData(data []byte) error {
|
|||
c.Tags["host"] = c.Agent.Hostname
|
||||
}
|
||||
|
||||
// Warn when explicitly setting the old snmp translator
|
||||
if c.Agent.SnmpTranslator == "netsnmp" {
|
||||
models.PrintOptionValueDeprecationNotice(telegraf.Warn, "agent", "snmp_translator", "netsnmp", telegraf.DeprecationInfo{
|
||||
Since: "1.25.0",
|
||||
RemovalIn: "2.0.0",
|
||||
Notice: "Use 'gosmi' instead",
|
||||
})
|
||||
}
|
||||
// Set snmp agent translator default
|
||||
if c.Agent.SnmpTranslator == "" {
|
||||
c.Agent.SnmpTranslator = "netsnmp"
|
||||
|
|
|
|||
|
|
@ -263,8 +263,8 @@ The agent table configures Telegraf and the defaults used across all plugins.
|
|||
If set to true, do no set the "host" tag in the telegraf agent.
|
||||
|
||||
- **snmp_translator**:
|
||||
Method of translating SNMP objects. Can be "netsnmp" which
|
||||
translates by calling external programs snmptranslate and snmptable,
|
||||
Method of translating SNMP objects. Can be "netsnmp" (deprecated) which
|
||||
translates by calling external programs `snmptranslate` and `snmptable`,
|
||||
or "gosmi" which translates using the built-in gosmi library.
|
||||
|
||||
## Plugins
|
||||
|
|
|
|||
Loading…
Reference in New Issue