Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

snmp table not working on later releases than 1.20.4 #10793

Open
henriknoerr opened this issue Mar 8, 2022 · 13 comments
Open

snmp table not working on later releases than 1.20.4 #10793

henriknoerr opened this issue Mar 8, 2022 · 13 comments
Labels
area/snmp bug unexpected problem or unintended behavior

Comments

@henriknoerr
Copy link

henriknoerr commented Mar 8, 2022

Relevant telegraf.conf

[[inputs.snmp]]
alias = "/etc/telegraf/telegraf.d/firewall-clu-01-vsid/vsid13.conf"
   agents = [
"ip",
"ip2"
]

   ## Timeout for each SNMP query.
   timeout = "20s"
   ## Number of retries to attempt within timeout.

   interval = "60s"
   retries = 0
   ## SNMP version, values can be 1, 2, or 3
   version = 3

   ## SNMP community string.
   # SNMPv3 auth parameters
   sec_name = ""
   auth_protocol = "sha"      # Values: "MD5", "SHA", ""
   auth_password = ""
   sec_level = "authPriv"     # Values: "noAuthNoPriv", "authNoPriv", "authPriv"
   context_name = "ctxname_vsid13"
   priv_protocol = "AES"         # Values: "DES", "AES", ""
   priv_password = ""


  [[inputs.snmp.field]]
    name = "hostname"
    oid = "RFC1213-MIB::sysName.0"
    is_tag = true

  [[inputs.snmp.field]]
    name = "vdName"
    oid = "CHECKPOINT-MIB::vdName.0"
    is_tag = true

  [[inputs.snmp.field]]
    name = "fwFullyUtilizedDrops"
    oid = "CHECKPOINT-MIB::fwFullyUtilizedDrops.0"

  [[inputs.snmp.field]]
    name = "fwNumConn"
    oid = "CHECKPOINT-MIB::fwNumConn.0"

[[inputs.snmp.field]]
    name = "fwFrag-fragments"
    oid = "CHECKPOINT-MIB::fwFrag-fragments.0"
[[inputs.snmp.field]]
    name = "fwFrag-expired"
    oid = "CHECKPOINT-MIB::fwFrag-expired.0"
[[inputs.snmp.field]]
    name = "fwFrag-packets"
    oid = "CHECKPOINT-MIB::fwFrag-packets.0"


  [[inputs.snmp.field]]
    name = "vdCoreXL"
    oid = "CHECKPOINT-MIB::fwInstancesCPUTotal.0"

  [[inputs.snmp.table]]
    name = "fwInstancesCPUTable"
    inherit_tags = [ "vdName" , "hostname" ]
    oid = "CHECKPOINT-MIB::fwInstancesCPUTable"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::fwInstancesCPUInstanceName"
    name = "fwInstancesCPUInstanceName"
    is_tag = true
  [[inputs.snmp.table]]
    name = "svnNetIfTable"
    inherit_tags = [ "vdName" , "hostname" ]
#    oid = "CHECKPOINT-MIB::svnNetIfTable"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfName"
    name = "svnNetIfName"
    is_tag = true

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfTXPackets"
    name = "svnNetIfTXPackets"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfTXErrors"
    name = "svnNetIfTXErrors"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfTXDrops"
    name = "svnNetIfTXDrops"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfTXBytes"
    name = "svnNetIfTXBytes"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfRXPackets"
    name = "svnNetIfRXPackets"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfRXErrors"
    name = "svnNetIfRXErrors"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfRXDrops"
    name = "svnNetIfRXDrops"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::svnNetIfRXBytes"
    name = "svnNetIfRXBytes"

[[inputs.snmp.field]]
name = "fwRejected"
oid = "CHECKPOINT-MIB::fwRejected.0"
[[inputs.snmp.field]]
name = "fwDropped"
oid = "CHECKPOINT-MIB::fwDropped.0"
[[inputs.snmp.field]]
name = "fwAccepted"
oid = "CHECKPOINT-MIB::fwAccepted.0"
[[inputs.snmp.field]]
name = "HAState"
oid = "CHECKPOINT-MIB::haStatCode.0"

Logs from Telegraf

on 1.20.4

root@<hostname>:/etc/telegraf/telegraf.d/checkpoint/firewall-clu-01-vsid# telegraf --test --config vsid13.conf --debug
2022-03-08T10:43:39Z I! Starting Telegraf 1.20.4
2022-03-08T10:43:39Z D! [agent] Initializing plugins
2022-03-08T10:43:39Z D! [agent] Starting service inputs
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwInstancesCPUTable"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "CHECKPOINT-MIB::fwInstancesCPUTable.1"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptable" "-Ch" "-Cl" "-c" "public" "127.0.0.1" "CHECKPOINT-MIB::fwInstancesCPUTable"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwInstancesCPUInstanceName"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwInstancesCPUUsage"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfName"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfTXPackets"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfTXErrors"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfTXDrops"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfTXBytes"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfRXPackets"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfRXErrors"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfRXDrops"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::svnNetIfRXBytes"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "RFC1213-MIB::sysName.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::vdName.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwFullyUtilizedDrops.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwNumConn.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwFrag-fragments.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwFrag-expired.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwFrag-packets.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwInstancesCPUTotal.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwRejected.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwDropped.0"
2022-03-08T10:43:39Z D! [inputs.snmp] executing "snmptranslate" "-Td" "-Ob" "CHECKPOINT-MIB::fwAccepted.0"
> snmp,agent_host=10.52.12.8,host=<hostname>,hostname=firewall-c2-vsx-01,vdName=vsw-nm-nat2 fwAccepted=0i,fwDropped=0i,fwFrag-expired=0i,fwFrag-fragments=0i,fwFrag-packets=0i,fwFullyUtilizedDrops=0i,fwNumConn=0i,fwRejected=0i,vdCoreXL=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.8,fwInstancesCPUInstanceName=jemalloc_bg_thd,host=<hostname>,hostname=firewall-c2-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.8,fwInstancesCPUInstanceName=fwk13_kissd,host=<hostname>,hostname=firewall-c2-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.8,fwInstancesCPUInstanceName=fwk13_0,host=<hostname>,hostname=firewall-c2-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.8,fwInstancesCPUInstanceName=fwk13_hp,host=<hostname>,hostname=firewall-c2-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.8,fwInstancesCPUInstanceName=fwk13_service,host=<hostname>,hostname=firewall-c2-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.8,fwInstancesCPUInstanceName=fwk13_dev_0,host=<hostname>,hostname=firewall-c2-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.8,host=<hostname>,hostname=firewall-c2-vsx-01,svnNetIfName=wrpj1093,vdName=vsw-nm-nat2 svnNetIfRXBytes=1696i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=58i,svnNetIfTXBytes=14501354i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=258975i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.8,host=<hostname>,hostname=firewall-c2-vsx-01,svnNetIfName=wrpj1029,vdName=vsw-nm-nat2 svnNetIfRXBytes=1732i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=58i,svnNetIfTXBytes=14501326i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=258975i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.8,host=<hostname>,hostname=firewall-c2-vsx-01,svnNetIfName=bond3.2104,vdName=vsw-nm-nat2 svnNetIfRXBytes=3274543118i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=31071709i,svnNetIfTXBytes=3696061630i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=30823041i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.8,host=<hostname>,hostname=firewall-c2-vsx-01,svnNetIfName=lo,vdName=vsw-nm-nat2 svnNetIfRXBytes=6388902i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=33236i,svnNetIfTXBytes=6388902i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=33236i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.8,host=<hostname>,hostname=firewall-c2-vsx-01,svnNetIfName=br13,vdName=vsw-nm-nat2 svnNetIfRXBytes=10847522i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=258321i,svnNetIfTXBytes=0i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=0i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.8,host=<hostname>,hostname=firewall-c2-vsx-01,svnNetIfName=wrpj1797,vdName=vsw-nm-nat2 svnNetIfRXBytes=1360i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=46i,svnNetIfTXBytes=14501872i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=258987i 1646736220000000000
> snmp,agent_host=10.52.12.7,host=<hostname>,hostname=firewall-c1-vsx-01,vdName=vsw-nm-nat2 fwAccepted=0i,fwDropped=0i,fwFrag-expired=0i,fwFrag-fragments=0i,fwFrag-packets=0i,fwFullyUtilizedDrops=0i,fwNumConn=0i,fwRejected=0i,vdCoreXL=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.7,fwInstancesCPUInstanceName=fwk13_0,host=<hostname>,hostname=firewall-c1-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.7,fwInstancesCPUInstanceName=fwk13_hp,host=<hostname>,hostname=firewall-c1-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.7,fwInstancesCPUInstanceName=fwk13_service,host=<hostname>,hostname=firewall-c1-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.7,fwInstancesCPUInstanceName=fwk13_dev_0,host=<hostname>,hostname=firewall-c1-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.7,fwInstancesCPUInstanceName=jemalloc_bg_thd,host=<hostname>,hostname=firewall-c1-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
> fwInstancesCPUTable,agent_host=10.52.12.7,fwInstancesCPUInstanceName=fwk13_kissd,host=<hostname>,hostname=firewall-c1-vsx-01,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1646736220000000000
2022-03-08T10:43:40Z D! [agent] Stopping service inputs
2022-03-08T10:43:40Z D! [agent] Input channel closed
> svnNetIfTable,agent_host=10.52.12.7,host=<hostname>,hostname=firewall-c1-vsx-01,svnNetIfName=wrpj1093,vdName=vsw-nm-nat2 svnNetIfRXBytes=1799512i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=64267i,svnNetIfTXBytes=9038190i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=193708i 1646736220000000000
2022-03-08T10:43:40Z D! [agent] Stopped Successfully
> svnNetIfTable,agent_host=10.52.12.7,host=<hostname>,hostname=firewall-c1-vsx-01,svnNetIfName=wrpj1029,vdName=vsw-nm-nat2 svnNetIfRXBytes=1800716i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=64310i,svnNetIfTXBytes=9038540i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=193713i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.7,host=<hostname>,hostname=firewall-c1-vsx-01,svnNetIfName=bond3.2104,vdName=vsw-nm-nat2 svnNetIfRXBytes=3265934182i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=30872444i,svnNetIfTXBytes=3703018134i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=31005071i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.7,host=<hostname>,hostname=firewall-c1-vsx-01,svnNetIfName=lo,vdName=vsw-nm-nat2 svnNetIfRXBytes=6388965i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=33312i,svnNetIfTXBytes=6388965i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=33312i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.7,host=<hostname>,hostname=firewall-c1-vsx-01,svnNetIfName=br13,vdName=vsw-nm-nat2 svnNetIfRXBytes=8124284i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=257923i,svnNetIfTXBytes=0i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=0i 1646736220000000000
> svnNetIfTable,agent_host=10.52.12.7,host=<hostname>,hostname=firewall-c1-vsx-01,svnNetIfName=wrpj1797,vdName=vsw-nm-nat2 svnNetIfRXBytes=1927936i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=66817i,svnNetIfTXBytes=9019390i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=193164i 1646736220000000000

on 1.21.4 or in between

root@hostname:/etc/telegraf/telegraf.d/tower_sync/checkpoint/firewall-01-vsid# telegraf --test --config vsid13.conf_disabled --debug
2022-03-11T15:51:54Z I! Starting Telegraf 1.21.4
2022-03-11T15:51:54Z I! Loaded inputs: snmp
2022-03-11T15:51:54Z I! Loaded aggregators:
2022-03-11T15:51:54Z I! Loaded processors:
2022-03-11T15:51:54Z W! Outputs are not used in testing mode!
2022-03-11T15:51:54Z I! Tags enabled: host=hostname
2022-03-11T15:51:54Z D! [agent] Initializing plugins
2022-03-11T15:51:57Z D! [agent] Starting service inputs
> snmp,agent_host=ip2,host=hostname,hostname=firewall-01,vdName=vsw-nm-nat2 fwAccepted=0i,fwDropped=0i,fwFrag-expired=0i,fwFrag-fragments=0i,fwFrag-packets=0i,fwFullyUtilizedDrops=0i,fwNumConn=0i,fwRejected=0i,vdCoreXL=0i 1647013917000000000
> snmp,agent_host=ip1,host=hostname,hostname=firewall-02,vdName=vsw-nm-nat2 fwAccepted=0i,fwDropped=0i,fwFrag-expired=0i,fwFrag-fragments=0i,fwFrag-packets=0i,fwFullyUtilizedDrops=0i,fwNumConn=0i,fwRejected=0i,vdCoreXL=0i 1647013917000000000
> svnNetIfTable,agent_host=ip2,host=hostname,hostname=firewall-01,svnNetIfName=wrpj1029,vdName=vsw-nm-nat2 svnNetIfRXBytes=1732i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=58i,svnNetIfTXBytes=15542856i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=277575i 1647013917000000000
> svnNetIfTable,agent_host=ip2,host=hostname,hostname=firewall-01,svnNetIfName=bond3.2104,vdName=vsw-nm-nat2 svnNetIfRXBytes=3516769416i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=33311597i,svnNetIfTXBytes=3968621180i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=33044468i 1647013917000000000
> svnNetIfTable,agent_host=ip2,host=hostname,hostname=firewall-01,svnNetIfName=lo,vdName=vsw-nm-nat2 svnNetIfRXBytes=6847754i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=35608i,svnNetIfTXBytes=6847754i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=35608i 1647013917000000000
> svnNetIfTable,agent_host=ip2,host=hostname,hostname=firewall-01,svnNetIfName=br13,vdName=vsw-nm-nat2 svnNetIfRXBytes=11628610i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=276920i,svnNetIfTXBytes=0i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=0i 1647013917000000000
> svnNetIfTable,agent_host=ip2,host=hostname,hostname=firewall-01,svnNetIfName=wrpj1797,vdName=vsw-nm-nat2 svnNetIfRXBytes=1360i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=46i,svnNetIfTXBytes=15543402i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=277587i 1647013917000000000
> svnNetIfTable,agent_host=ip2,host=hostname,hostname=firewall-01,svnNetIfName=wrpj1093,vdName=vsw-nm-nat2 svnNetIfRXBytes=1836i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=63i,svnNetIfTXBytes=15542674i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=277570i 1647013917000000000
> svnNetIfTable,agent_host=ip1,host=hostname,hostname=firewall-02,svnNetIfName=wrpj1093,vdName=vsw-nm-nat2 svnNetIfRXBytes=1929264i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=68901i,svnNetIfTXBytes=9689162i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=207663i 1647013917000000000
2022-03-11T15:51:57Z D! [agent] Stopping service inputs
> svnNetIfTable,agent_host=ip1,host=hostname,hostname=firewall-02,svnNetIfName=wrpj1029,vdName=vsw-nm-nat2 svnNetIfRXBytes=1930496i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=68945i,svnNetIfTXBytes=9689582i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=207669i 1647013917000000000
2022-03-11T15:51:57Z D! [agent] Input channel closed
> svnNetIfTable,agent_host=ip1,host=hostname,hostname=firewall-02,svnNetIfName=bond3.2104,vdName=vsw-nm-nat2 svnNetIfRXBytes=3507585500i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=33098477i,svnNetIfTXBytes=3976157758i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=33240461i 1647013917000000000
2022-03-11T15:51:57Z D! [agent] Stopped Successfully
> svnNetIfTable,agent_host=ip1,host=hostname,hostname=firewall-02,svnNetIfName=lo,vdName=vsw-nm-nat2 svnNetIfRXBytes=6847329i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=35688i,svnNetIfTXBytes=6847329i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=35688i 1647013917000000000
> svnNetIfTable,agent_host=ip1,host=hostname,hostname=firewall-02,svnNetIfName=br13,vdName=vsw-nm-nat2 svnNetIfRXBytes=8709638i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=276512i,svnNetIfTXBytes=0i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=0i 1647013917000000000
> svnNetIfTable,agent_host=ip1,host=hostname,hostname=firewall-02,svnNetIfName=wrpj1797,vdName=vsw-nm-nat2 svnNetIfRXBytes=2067092i,svnNetIfRXDrops=0i,svnNetIfRXErrors=0i,svnNetIfRXPackets=71636i,svnNetIfTXBytes=9668496i,svnNetIfTXDrops=0i,svnNetIfTXErrors=0i,svnNetIfTXPackets=207072i 1647013917000000000

System info

telegraf 1.21.4

Docker

No response

Steps to reproduce

...

Expected behavior

I want releases later than 1.20.4 to be able to gather metrics from the CHECKPOINT-MIB::fwInstancesCPUTable

Actual behavior

no data from said table

Additional info

snippet from CHECKPOINT-MIB
CHECKPOINT-MIB.txt

      fwInstancesCPU OBJECT IDENTIFIER ::= { fw 31 }

      fwInstancesCPUTable OBJECT-TYPE
            SYNTAX  SEQUENCE OF  fwInstancesCPUEntry
            MAX-ACCESS  not-accessible
            STATUS  current
            DESCRIPTION
                                "OID to present the CPU usage of all instances of the fw"
            ::= { fwInstancesCPU 1 }

      fwInstancesCPUEntry OBJECT-TYPE
            SYNTAX  fwInstancesCPUEntry
            MAX-ACCESS  not-accessible
            STATUS  current
            DESCRIPTION
                                ""
            ::= { fwInstancesCPUTable 1 }

      fwInstancesCPUEntry ::=
              SEQUENCE {
                 fwInstancesCPUInstanceName
                      DisplayString,
                 fwInstancesCPUUsage
                      Unsigned32
              }

      fwInstancesCPUInstanceName OBJECT-TYPE
            SYNTAX  DisplayString
            MAX-ACCESS read-only
            STATUS  current
            DESCRIPTION
                                "Name of instance thread"
            ::= { fwInstancesCPUEntry 1 }

      fwInstancesCPUUsage OBJECT-TYPE
            SYNTAX  Unsigned32
            MAX-ACCESS read-only
            STATUS  current
            DESCRIPTION
                                "Current CPU usage percent"
            ::= { fwInstancesCPUEntry 2 }

     fwInstancesCPUTotal OBJECT-TYPE
            SYNTAX  Unsigned32
            MAX-ACCESS  read-only
            STATUS  current
            DESCRIPTION
                                "OID to present the total CPU usage of all instances of the fw"
            ::= { fwInstancesCPU 2 }
@henriknoerr henriknoerr added the bug unexpected problem or unintended behavior label Mar 8, 2022
@Hipska
Copy link
Contributor

Hipska commented Mar 11, 2022

Could you edit your message, it seems like you pasted the same output for 1.21.4 so we don't see any error messages..

@Hipska
Copy link
Contributor

Hipska commented Mar 11, 2022

Could you also update the relevant telegraf config from your starting post to include the whole [[inputs.snmp]] section?

@henriknoerr
Copy link
Author

done, and also corrected the initial 1.21.4 output to represent a real poll with 1.21.4 to same device

@Hipska
Copy link
Contributor

Hipska commented Mar 11, 2022

Does it work if you manually added this field for example?

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::fwInstancesCPUUsage"
    name = "fwInstancesCPUUsage"

@henriknoerr
Copy link
Author

henriknoerr commented Mar 11, 2022

hmm yes when I add it under the table I get the following.

> fwInstancesCPUTable,agent_host=ip,fwInstancesCPUInstanceName=fwk13_dev_0,host=hostname,hostname=firewall,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1647014962000000000
> fwInstancesCPUTable,agent_host=ip,fwInstancesCPUInstanceName=jemalloc_bg_thd,host=hostname,hostname=firewall,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1647014962000000000
> fwInstancesCPUTable,agent_host=ip,fwInstancesCPUInstanceName=fwk13_kissd,host=hostname,hostname=firewall,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1647014962000000000
> fwInstancesCPUTable,agent_host=ip,fwInstancesCPUInstanceName=fwk13_0,host=hostname,hostname=firewall,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1647014962000000000
> fwInstancesCPUTable,agent_host=ip,fwInstancesCPUInstanceName=fwk13_hp,host=hostname,hostname=firewall,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1647014962000000000
> fwInstancesCPUTable,agent_host=ip,fwInstancesCPUInstanceName=fwk13_service,host=hostname,hostname=firewall,vdName=vsw-nm-nat2 fwInstancesCPUUsage=0i 1647014962000000000

So config now looks like;

  [[inputs.snmp.table]]
    name = "fwInstancesCPUTable"
    inherit_tags = [ "vdName" , "hostname" ]
    oid = "CHECKPOINT-MIB::fwInstancesCPUTable"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::fwInstancesCPUUsage"
    name = "fwInstancesCPUUsage"

  [[inputs.snmp.table.field]]
    oid = "CHECKPOINT-MIB::fwInstancesCPUInstanceName"
    name = "fwInstancesCPUInstanceName"
    is_tag = true

Am I doing something wrong leaving that table field out? My understanding is that all fields are recorded when adding oid at the table level.

@Hipska
Copy link
Contributor

Hipska commented Mar 11, 2022

Hi @MyaLongmire another example that there might be something wrong with snmp's Table.Init().

(Other example was in #10445)

@henriknoerr
Copy link
Author

What is the most worrisome is that this fails silently - no way to know that you are actually dropping metrics until someome kindly reminds you that we are missing several days of data :(

@reimda
Copy link
Contributor

reimda commented Mar 19, 2022

Hi @henriknoerr, we recently merged a change that switches back to the 1.20.4 behavior (#10802). It's in the nightly build now. Could you try the nightly build to see if it works for you? We're planning to release this in 1.23.0 which is scheduled for next Wednesday, March 23. If you could report what you find it would help us flush out bugs and gain confidence in the change.

Nightly builds: https://github.com/influxdata/telegraf/blob/master/docs/NIGHTLIES.md

@henriknoerr
Copy link
Author

The nightly build correctly polls the table I was missing.

@henriknoerr
Copy link
Author

henriknoerr commented Mar 21, 2022

root@hostname:~$ telegraf --version
Telegraf 1.22.0-77040ef4 (git: master 77040ef)

@reimda
Copy link
Contributor

reimda commented Mar 22, 2022

Thanks for testing. I'm glad it's working again for you

@reimda
Copy link
Contributor

reimda commented Mar 24, 2022

Since this is working with the netsnmp translator, I'm closing the issue

@reimda reimda closed this as completed Mar 24, 2022
@Hipska Hipska reopened this Mar 24, 2022
@Hipska
Copy link
Contributor

Hipska commented Mar 24, 2022

No, we still need to investigate what's wrong with the gosmi table init..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/snmp bug unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

4 participants