Skip to content

[inputs.ping] Native method gives higher results comparing to exec #9729

@manio

Description

@manio

Native method gives wrong results comparing to exec mode.

Relevant telegraf.conf:

[[inputs.ping]]
  urls = [
    "host1",
    "host2",
    "host3",
    "host4",
    "host5",
  ]

System info:

Telegraf 1.19.3 (git: HEAD a799489)
Debian Linux x86_64

Steps to reproduce:

  1. Collect ping data using preferred native method
  2. Collect ping data using the exec method
  3. Compare the results

Expected behavior:

The ping reply time should be at least comparable

Actual behavior:

Now it look like this
image

You probably can see on this graph at which time I changed from native to exec :)

Additional info:

No idea why the ping is collecting the data wrongly in native mode - just guessing:

  1. spawning new ping thread overhead?
  2. thread's priority?

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/pingbugunexpected problem or unintended behaviorupstreambug or issues that rely on dependency fixes

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions