On Tue, 2020-10-20 at 15:59 +0200, Florian Obser wrote: > On Tue, Oct 20, 2020 at 03:46:19PM +0200, Martijn van Duren wrote: > > On Tue, 2020-10-20 at 15:19 +0200, Florian Obser wrote: > > > On Tue, Oct 20, 2020 at 09:20:32AM +0200, Martijn van Duren wrote: > > > > I have an icinga-instance running on openbsd.amsterdam. Here I found > > > > that sometimes check_ping from the monitoring-plugins package fails, > > > > because ping(8) sends "failed to get receiving hop limit", but still > > > > receives all the ping replies. These packets/annomalies are clearly > > > > not meant for us. > > > > > > But it is. This is comming from the local machine, > > > see L949ff of netinet6/ip6_input.c. > > > > What I meant to say is meant for ping(8). All the icmp echo replies > > still arrive and are accounted for. > > > > I don't understand. > > I patched the kernel to make sbcreatecontrol() fail 50% of the time: > > $ ping6 -qc10 fe80::5667:51ff:fede:e7ce%vio0 > PING fe80::5667:51ff:fede:e7ce%vio0 (fe80::5667:51ff:fede:e7ce%vio0): 56 data > bytes > ping6: failed to get receiving hop limit > ping6: failed to get receiving hop limit > ping6: failed to get receiving hop limit > ping6: failed to get receiving hop limit > > --- fe80::5667:51ff:fede:e7ce%vio0 ping statistics --- > 10 packets transmitted, 6 packets received, 40.0% packet loss > round-trip min/avg/max/std-dev = 0.980/1.196/1.955/0.342 ms > > I assure you, I do not have 40% packet loss towards my gateway. > The packets are not accounted for. > When running: /usr/local/libexec/nagios/check_ping -vv -6 -H <ip> -c 500,75% -w 250,50% in a tight loop at some point I get the following output:
CMD: /sbin/ping6 -n -c 5 <ip> Output: PING <ip> (<ip>): 56 data bytes Output: 64 bytes from <ip>: icmp_seq=0 hlim=57 time=1.724 ms Output: 64 bytes from <ip>: icmp_seq=1 hlim=57 time=1.612 ms Output: 64 bytes from <ip>: icmp_seq=2 hlim=57 time=1.785 ms Output: 64 bytes from <ip>: icmp_seq=3 hlim=57 time=1.762 ms Output: 64 bytes from <ip>: icmp_seq=4 hlim=57 time=1.708 ms Output: Output: --- <ip> ping statistics --- Output: 5 packets transmitted, 5 packets received, 0.0% packet loss Output: round-trip min/avg/max/std-dev = 1.612/1.718/1.785/0.060 ms Got stderr: ping6: failed to get receiving hop limit PING WARNING - System call sent warnings to stderr Packet loss = 0%, RTA = 1.72 ms|rta=1.718000ms;3000.000000;5000.000000;0.000000 pl=0%;80;100;0 3000.000000:80% 5000.000000:100% So I have 5 echo requests, 5 echo replies and one unrelated packet not related to my ping command. Yet this notice to stderr forces check_ping into a warning state.
