<div dir="ltr"><div><div><div>Thanks Aleksander.<br><br></div>I will keep my system running, and will let know if anything fishy is observed despite the 3 watcher-tests.<br></div><div>Thanks again !!<br><br><br></div>Thanks and Regards,<br></div>Ajay<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Aug 15, 2016 at 7:31 PM, Aleksander Morgado <span dir="ltr"><<a href="mailto:aleksander@aleksander.es" target="_blank">aleksander@aleksander.es</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Mon, Aug 15, 2016 at 3:52 PM, Ajay Garg <<a href="mailto:ajaygargnsit@gmail.com">ajaygargnsit@gmail.com</a>> wrote:<br>
> I have a modem in QMI-mode, and through your help, I have been able to get<br>
> it up and running.<br>
><br>
><br>
> Now, my architecture is such ::<br>
><br>
> *<br>
> There is a python-script, which monitors the health of "wwan0" interface.<br>
><br>
> *<br>
> There is an application-binary in C, which uses POSIX-socket APIs to create<br>
> a socket (and the socket is created from wwan0, as that is the only active<br>
> interface).<br>
><br>
><br>
><br>
> Now, things are working fine so far.<br>
> I have put in the following tests in the python-script ::<br>
><br>
> 1)<br>
> Ensure power state: 'on' in output of "mmcli -m modem-id".<br>
><br>
> 2)<br>
> Ensure state: 'connected' in output of "mmcli -m modem-id".<br>
><br>
> 3)<br>
> Ensure there is a ipv4 address assigned to wwan0-interface.<br>
><br>
><br>
> I run the above 3 tests every 30 seconds, and assume that if all 3 match as<br>
> expected, then the wwan0-interface is fine (and any user-applications using<br>
> POSIX-Socket APIs would continue to achieve new socket-instantiations fine).<br>
><br>
><br>
><br>
> Are the 3 tests sufficient?<br>
> Or any other tests should/must be put?<br>
><br>
><br>
> Will be grateful for pointers, that could help make the wwan-interface-up<br>
> testing bullet-proof.<br>
<br>
</div></div>Those should be enough; unless you also want to test real Internet<br>
connectivity as well, e.g. doing a periodic ping -I wwan0 x.x.x.x.<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Aleksander<br>
<a href="https://aleksander.es" rel="noreferrer" target="_blank">https://aleksander.es</a><br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Regards,<br>Ajay<br></div>
</div>