ioBroker / ioBroker.ping

Pings configured IPs for ioBroker
MIT License
21 stars 18 forks source link

Ping Adapter Fehler bei nicht Erreichbarkeit #54

Closed Alveran81 closed 2 years ago

Alveran81 commented 2 years ago

Ping Adapter Version 1.5.2

Wenn die Anzahl der eingestellten Ping Versuche größer als 1 bricht der Adapter das pingen bei dem Gerät was er nicht erreichen kann ab, die folgenden Geräte werden nicht mehr versucht zu pingen. Beispiel es sind 10 Geräte in der Liste und das dritte Gerät ist nicht erreichbar dann wird nicht versucht Gerät 4 bis 10 an zu pingen. Wenn die Anzahl der Versuche auf 1 gestellt wird, funktioniert es einwandfrei. Es scheint sich also noch ein Fehler in einer Schleife der Programmierung eingeschlichen zu haben.

Apollon77 commented 2 years ago

Can you please provide a debug log for both cases?

Alveran81 commented 2 years ago

Ping Retry is set to 3

ping.0 2022-01-25 13:05:32.079 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:32.078 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:30.073 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:30.073 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:28.067 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:28.066 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:26.061 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:26.060 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:24.052 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:24.051 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:22.045 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:22.044 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:20.037 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:20.036 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:18.030 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:18.029 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:16.022 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:16.022 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:14.016 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:14.015 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:12.009 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:12.008 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:10.001 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:09.999 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:07.988 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:07.987 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:05.981 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:05.980 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:03.963 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:03.962 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:05:01.956 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:05:01.956 debug Ping result for 10.210.128.1: false in -ms (Tried 1/3 times)
ping.0 2022-01-25 13:04:59.948 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1

Ping Retry is set to 1

ping.0 2022-01-25 13:09:16.168 debug Ping result for 10.210.128.41: true in 254ms (Tried 1/1 times)
ping.0 2022-01-25 13:09:15.908 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.41
ping.0 2022-01-25 13:09:15.908 debug Pinging 10.210.128.41
ping.0 2022-01-25 13:09:15.907 debug Ping result for 10.210.128.33: true in 493ms (Tried 1/1 times)
ping.0 2022-01-25 13:09:15.409 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.33
ping.0 2022-01-25 13:09:15.409 debug Pinging 10.210.128.33
ping.0 2022-01-25 13:09:15.408 debug Ping result for 10.210.128.25: true in 391ms (Tried 1/1 times)
ping.0 2022-01-25 13:09:15.012 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.25
ping.0 2022-01-25 13:09:15.011 debug Pinging 10.210.128.25
ping.0 2022-01-25 13:09:15.010 debug Ping result for 10.210.128.17: false in -ms (Tried 1/1 times)
ping.0 2022-01-25 13:09:13.004 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.17
ping.0 2022-01-25 13:09:13.004 debug Pinging 10.210.128.17
ping.0 2022-01-25 13:09:13.003 debug Ping result for 10.210.128.9: true in 533ms (Tried 1/1 times)
ping.0 2022-01-25 13:09:12.463 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.9
ping.0 2022-01-25 13:09:12.463 debug Pinging 10.210.128.9
ping.0 2022-01-25 13:09:12.459 debug Ping result for 10.210.128.1: false in -ms (Tried 1/1 times)
ping.0 2022-01-25 13:09:10.446 debug System command: /bin/ping -n -w 2 -c 1 10.210.128.1
ping.0 2022-01-25 13:09:10.446 debug Pinging 10.210.128.1
HolgerB73 commented 2 years ago

I have the same issue here

ping.1 2022-01-26 11:47:50.071 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.123 ping.1 2022-01-26 11:47:50.069 debug Ping result for 192.168.0.123: false in -ms (Tried 1/2 times) ping.1 2022-01-26 11:47:48.044 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.123 ping.1 2022-01-26 11:47:48.042 debug Ping result for 192.168.0.123: false in -ms (Tried 1/2 times) ping.1 2022-01-26 11:47:46.948 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.123 ping.1 2022-01-26 11:47:46.947 debug Ping result for 192.168.0.123: false in -ms (Tried 1/2 times) ping.1 2022-01-26 11:47:44.924 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.123 ping.1 2022-01-26 11:47:44.922 debug Ping result for 192.168.0.123: false in -ms (Tried 1/2 times) ping.1 2022-01-26 11:47:44.755 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.123 ping.1 2022-01-26 11:47:44.753 debug Ping result for 192.168.0.123: false in -ms (Tried 1/2 times) ping.1 2022-01-26 11:47:42.727 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.123

If I put the number of retries to '1', it works ping.1 2022-01-26 12:00:49.971 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.123 ping.1 2022-01-26 12:00:49.970 debug Pinging 192.168.0.123 ping.1 2022-01-26 12:00:44.967 debug Ping result for 192.168.0.198: true in 92.5ms (Tried 1/1 times) ping.1 2022-01-26 12:00:44.850 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.198 ping.1 2022-01-26 12:00:44.849 debug Pinging 192.168.0.198 ping.1 2022-01-26 12:00:44.846 debug Ping result for 192.168.0.169: false in -ms (Tried 1/1 times) ping.1 2022-01-26 12:00:42.821 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.169 ping.1 2022-01-26 12:00:42.820 debug Pinging 192.168.0.169 ping.1 2022-01-26 12:00:42.817 debug Ping result for 192.168.0.123: false in -ms (Tried 1/1 times) ping.1 2022-01-26 12:00:40.792 debug System command: /bin/ping -n -w 2 -c 1 192.168.0.123 ping.1 2022-01-26 12:00:40.790 debug Pinging 192.168.0.123

HolgerB73 commented 2 years ago

The bug seems to be in line 113 main.js If I change it to:
pingSingleDevice(task, taskList, index, retryCounter+1), retryCounter + 1); everything works fine

Apollon77 commented 2 years ago

Cool, thank you ... will check code later, with this it might be faster solved :-))

JuniperChris929 commented 2 years ago

Saw the same issue today - do you know when a fix will be available?

Apollon77 commented 2 years ago

soon(TM) :-) Currently working through some adapters, this one is next

JuniperChris929 commented 2 years ago

Nice :D