Skip to content

ethtool: lots of extra escaped charachters in output #9902

@powersj

Description

@powersj

Relevant telegraf.conf:

[agent]
  interval = "5s"
  round_interval = true
  metric_batch_size = 1000
  metric_buffer_limit = 10000
  collection_jitter = "1s"
  flush_interval = "5s"
  flush_jitter = "1s"
  precision = ""
  debug = false
  quiet = false
  logfile = ""
  omit_hostname = false

[[inputs.ethtool]]
name_prefix = "dns_"
interface_include = ["enp0s3"]


[[outputs.file]]
  ## Files to write to, "stdout" is a specially handled file.
  files = ["/tmp/metrics.out"]
  rotation_max_size = "10MB"
  rotation_max_archives = 3

System info:

v1.20

Steps to reproduce:

  1. Run telegraf with ethtool input plugin on a NIC using the vmxnet3 driver on ESXi
  2. Observe output

Expected behavior:

The field keys are not escaping extra whitespace

Actual behavior:

dns_ethtool,driver=vmxnet3,host=foobar,interface=enp0s3 \ \ mcast\ pkts\ rx=14i,\ \ \ \ \ tso=0i,\ \ LRO\ byte\ rx=0i,Rx\ Queue#=0i,\ \ TSO\ pkts\ tx=10i,\ \ bcast\ pkts\ tx=3i,\ \ pkts\ linearized=0i,\ \ pkts\ rx\ err=0i,\ \ \ \ \ err=0i,\ \ TSO\ bytes\ tx=26976i,\ \ ucast\ pkts\ rx=397741i,\ \ giant\ hdr=0i,\ \ ring\ full=0i,\ \ hdr\ cloned=0i,\ \ \ \ \ too\ many\ frags=0i,\ \ drv\ dropped\ rx\ total=0i,tx\ timeout\ count=0i,\ \ bcast\ pkts\ rx=669i,\ \ pkts\ tx\ err=0i,\ \ pkts\ rx\ OOB=0i,\ \ \ \ \ hdr\ err=0i,\ \ mcast\ bytes\ rx=1607i,\ \ mcast\ pkts\ tx=35i,interface_up=true,Tx\ Queue#=0i,\ \ LRO\ pkts\ rx=0i,\ \ bcast\ bytes\ rx=41313i,\ \ pkts\ tx\ discard=0i,\ \ rx\ buf\ alloc\ fail=0i,\ \ mcast\ bytes\ tx=4855i,\ \ ucast\ pkts\ tx=238773i,\ \ drv\ dropped\ tx\ total=0i,\ \ ucast\ bytes\ rx=598561435i,\ \ \ \ \ fcs=0i,\ \ bcast\ bytes\ tx=726i,\ \ ucast\ bytes\ tx=16947278i,\ \ \ \ \ giant\ hdr=0i 1633726650000000000

Additional info:

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugunexpected problem or unintended behavior

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions