Just by curiosity I had a look to the source code. As far as I understand the source code the binding detects all available network interfaces and uses all of them. It is not possible to configure the network interface that is to be used. I think this is because of one user might want to use all of them while the other one only wants to use one. Doing a query on all the interfaces solves this.
I wanted to do it myself but I didn’t find the time. Thank you
The problem is in this “full” example…
"A" S 0:00 \_ arping -w 2 -c 1 -I docker0 192.168.5.3
"B" S 0:00 \_ arping -w 2 -c 1 -I eth0 192.168.5.5
The process “B” end immediately with “ON”, but the process “A” wait the timeout (-w) and overwrites the value. Result … the IP 192.168.5.3 is “OFF”.
If the code will not be changed with the possibility to select the interface, the solution is my “fake arping” /etc/openhab2/arping.sh
Hmm, the trouble is that for any target device, a ping is likely to fail on one interface on any non-trivial network. That wouldn’t usually matter (the other one worked!) but of course this binding takes positive action by design and reports the failure?