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

scary ping error in logs #2653

Closed
rburchell opened this issue Apr 11, 2017 · 8 comments
Closed

scary ping error in logs #2653

rburchell opened this issue Apr 11, 2017 · 8 comments
Labels
bug unexpected problem or unintended behavior platform/windows

Comments

@rburchell
Copy link

Bug report

Relevant telegraf.conf:

 # Ping given url(s) and return statistics
 [[inputs.ping]]
   ## NOTE: this plugin forks the ping command. You may need to set capabilities
   ## via setcap cap_net_raw+p /bin/ping
   #
   ## urls to ping
   urls = ["8.8.8.8", "192.168.1.1"] # required
   ## number of pings to send per collection (ping -c <COUNT>)
   count = 10
   ## interval, in s, at which to ping. 0 == default (ping -i <PING_INTERVAL>)
   # ping_interval = 1.0
   ## per-ping timeout, in s. 0 == no timeout (ping -W <TIMEOUT>)
   # timeout = 1.0
   ## interface to send ping from (ping -I <INTERFACE>)
   # interface = ""

System info:

Windows 10.

Steps to reproduce:

Run telegraf, view the log output.

Expected behavior:

See no scary warnings :)

Actual behavior:

See this:

2017-04-11T23:30:30Z E! Field type conflict, dropping conflicted points: {"error":"field type conflict: input field "average_response_ms" on measurement "ping" is type integer, already exists as type float dropped=1"}

Additional info:

I'm not yet sure what impact this has, but I guess that it means that my ping measurements aren't going to be correctly recorded.

@danielnelson danielnelson added the bug unexpected problem or unintended behavior label Apr 11, 2017
@danielnelson
Copy link
Contributor

This means the output InfluxDB already has received the field as a float, which is the correct type for this field. I suggest not running ping in Windows until this is fixed as it might cause the opposite problem with clients reporting it as a float as they fight over the field type.

Can you run the ping command and add the output as well as the output of telegraf -test? The command is probably something like ping -c 10 -i 1.0 -W 1.0

@rburchell
Copy link
Author

Certainly. I had to tweak your ping flags a bit:

C:\Users\burchr>ping -n 10 -i 1.0 -w 1.0 192.168.1.1

Pinging 192.168.1.1 with 32 bytes of data:
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64

Ping statistics for 192.168.1.1:
    Packets: Sent = 10, Received = 10, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 0ms, Maximum = 0ms, Average = 0ms

That "time<1ms" looks fun.

Internet pings were a little more interesting:

C:\Users\burchr>ping -n 10 -i 1.0 -w 1.0 8.8.8.8

Pinging 8.8.8.8 with 32 bytes of data:
Reply from 192.168.1.1: TTL expired in transit.
Reply from 192.168.1.1: TTL expired in transit.
Reply from 192.168.1.1: TTL expired in transit.
Reply from 192.168.1.1: TTL expired in transit.
Reply from 192.168.1.1: TTL expired in transit.
Reply from 192.168.1.1: TTL expired in transit.

Ping statistics for 8.8.8.8:
    Packets: Sent = 6, Received = 6, Lost = 0 (0% loss),
Control-C
^C

Flailing blindly at the values (it's nearly 2am here, so I'm a little too tired to be reading manpages) I got this:

C:\Users\burchr>ping -n 10 -i 10 -w 10 8.8.8.8

Pinging 8.8.8.8 with 32 bytes of data:
Reply from 8.8.8.8: bytes=32 time=151ms TTL=57
Reply from 8.8.8.8: bytes=32 time=95ms TTL=57
Reply from 8.8.8.8: bytes=32 time=83ms TTL=57
Request timed out.
Reply from 8.8.8.8: bytes=32 time=122ms TTL=57
Reply from 8.8.8.8: bytes=32 time=103ms TTL=57
Reply from 8.8.8.8: bytes=32 time=117ms TTL=57
Reply from 8.8.8.8: bytes=32 time=137ms TTL=57
Reply from 8.8.8.8: bytes=32 time=162ms TTL=57
Reply from 8.8.8.8: bytes=32 time=92ms TTL=57

Ping statistics for 8.8.8.8:
    Packets: Sent = 10, Received = 9, Lost = 1 (10% loss),
Approximate round trip times in milli-seconds:
    Minimum = 83ms, Maximum = 162ms, Average = 118ms

@rburchell
Copy link
Author

Regarding the -test flag, I ran over similar issues as in #2652. I had to disable the "net" and "system" input plugins to be able to run tests OK. Should I file a separate bug for this, or is it intentional in this case?

After that, the relevant part of the test output is:

* Plugin: inputs.ping, Collection 1
> ping,url=192.168.1.1,host=bea packets_transmitted=10i,reply_received=10i,packets_received=10i,percent_packet_loss=0,percent_reply_loss=0 1491954460000000000
> ping,url=8.8.8.8,host=bea percent_reply_loss=10,average_response_ms=106i,minimum_response_ms=57i,maximum_response_ms=156i,packets_transmitted=10i,reply_received=9i,packets_received=9i,percent_packet_loss=10 1491954464000000000

@danielnelson
Copy link
Contributor

If it is the same error just on a different plugin then don't open another ticket.

@rburchell
Copy link
Author

They run fine normally (with warnings), but not when -test is passed. Slightly different issue.

@danielnelson
Copy link
Contributor

Okay go ahead and open an issue with the details

@danielnelson
Copy link
Contributor

Looks like this issue was fixed by #2462.

@rburchell
Copy link
Author

Thanks! Sorry for the duplicate.

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

No branches or pull requests

2 participants