[arm-allstar] A way to check allstar connection status

Doug Crompton wa3dsp at gmail.com
Tue Apr 21 23:54:01 EDT 2020


I haven't followed this thread to detail but if you are having a
registration issue you really should have a Hamvoip registration for your
node(s)  The Allstar registration system is often flaky and it you are not
registering and have a good Internet connection that is probably the case.
I also would not depend on a status server to give you that information as
it to can be flaky. Better to do a dns-query on a remote system for the
node in questions. This assumes you have a Hamvoip registration. dns-query
returns an error message that is easy to script..

Example -

# dns-query 56000
-ER|NOT FOUND
# dns-query 40000
+OK|radio at 129.21.198.83:4569/40000,129.21.198.83

#!/bin/bash

while :
do
res=$(dns-query node)

if [[ ${str:0:3} == "-ER" ]]

   then
       do something if not registered
fi
sleep seconds
done

set seconds and node

*73 Doug, WA3DSP*
*http://wa3dsp.org <http://wa3dsp.org>*


On Tue, Apr 21, 2020 at 7:34 PM "Justin Grigg via ARM-allstar" <
arm-allstar at hamvoip.org> wrote:

> Bryan,
> Thank you for the information and I was leaning that way at first. The
> weird part is when the node I am helping with falls into this error state,
> it is still functioning as an RF repeater and can still ping websites. It
> has just lost the connection to allstarlink. Once you cycle asterisk it
> reconnects and comes right back up.
>
> I spent this evening creating a script that I believe will take care of
> this. It pulls down the text from the allstar node website and searches the
> text for the connection error. If detected, it runs a script that is
> defined in the variables. I have it running a custom asterisk restart
> script.
>
> If I run this hourly, do you think that would be a problem?
>
> Thank you for your quick response!!
>
> Justin
>
>
>
> On Tue, Apr 21, 2020 at 1:20 PM "Bryan St Clair via ARM-allstar" <
> arm-allstar at hamvoip.org> wrote:
>
> > If you want to trigger off a dns error, do just that.
> >
> > Script a dns query on your own node number and if a error returns,
> perform
> > the action you want.
> >
> > But I wouldn't run it too often, I could see that loop easily if there
> was
> > ever a slow update to registration status.
> >
> > Would be smarter to setup a reverse ssh tunnel and you can restart it as
> > needed.
> >
> > On Tue, Apr 21, 2020, 10:11 "Justin Grigg via ARM-allstar" <
> > arm-allstar at hamvoip.org> wrote:
> >
> > > Hello,
> > > I am working on depoying a repeater that will be using a hamvoip node
> as
> > a
> > > controller. This site will have a cellular connection for data but it
> is
> > > hard to access. I have a script that will trigger a restart if a
> network
> > > connection is lost, but I am worried about an unrepnisve node.
> > >
> > > My question is if there is a way to check for the node's status on
> > Allstar
> > > via bash? I have seen nodes that get locked up and show the status
> "Node
> > > ###### is not in the stats database, invalid node number or a temporary
> > > communications error, please try again later". I want to trigger a
> > > asterisks restart automaitclly if this happens.
> > >
> > > Is this possible?
> > >
> > > Thanks!!
> > >
> > > Justin
> > > _______________________________________________
> > >
> > > ARM-allstar mailing list
> > > ARM-allstar at hamvoip.org
> > > http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
> > >
> > > Visit the BBB and RPi2/3/4 web page - http://hamvoip.org
> > >
> > _______________________________________________
> >
> > ARM-allstar mailing list
> > ARM-allstar at hamvoip.org
> > http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
> >
> > Visit the BBB and RPi2/3/4 web page - http://hamvoip.org
> >
> _______________________________________________
>
> ARM-allstar mailing list
> ARM-allstar at hamvoip.org
> http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
>
> Visit the BBB and RPi2/3/4 web page - http://hamvoip.org
>


More information about the ARM-allstar mailing list