[arm-allstar] Remote NODE
Luc Drolet VE2LUQ
ldrolet at cgocable.ca
Wed Feb 6 17:12:41 EST 2019
Hi Doug,
WOW, Ok I understand your script
I'm going to do tests at the end of the week and I cross well that it will work well
Thank you for your explanations it's greatly appreciate
73 's
Luc
> Le 6 févr. 2019 à 01:55, Doug Crompton via ARM-allstar <arm-allstar at hamvoip.org> a écrit :
>
> Luc,
>
> The Asterisk remote command in hamvoip Allstar has been turned off by
> default because of its inherent insecurity. While you could turn it back on
> a better approach might be to use Supermon with remote management. If you
> don't have a screen available such as in a mobile situation your could use
> a script to send ssh commands to control the node in question. This script
> could certainly be expanded on but gives you the idea. In order to use it
> you need to know the IP address of the node you want to control. Again the
> address could be automated since we know the address for public nodes. For
> private nodes you would need to specify it. right now this script is hard
> wired for control of one remote node l but again it could be made more
> flexible with more parameters. This script would be called from DTMF
> functions setup on the controlling server so DTMF could be used on the
> controlling server. You could further expand this using the autopatch DTMF
> parameter passing (howto at hamvoip.org) and pass the actual node number in
> the DTMF sequence. For now though if you decide to try it go simple and
> hardwire it and use a different script for each remote node you want to
> control. The script could be named to indetify it by the remote node
> number. Obviously you must have a valid login on the system you want to
> control.
>
> Example function to connect the remote node to node 40000
> D3=cmd,/root/remote-command.sh *340000
>
> Example function to disconnect all connected nodes from the remote node
> D76=cmd,/root/remote-command.sh *76
>
> Example to play the time on the remote node
> D81=cmd,/root/remote-command.sh *81
>
> and here is the remote-command.sh script -
>
> #!/bin/bash
> # Doug, WA3DSP 2/2019
> #
> # This script logs into a remote system executes an Asterisk command and
> logs out
> #
> # Command examples
> # remote-command.sh <command>
> # remote-command.sh *81
> # remote-command.sh *340000
> # remote-command.sh *76
>
> # Send remote ssh command automatically
>
> if [ -z $1 ]
> then
> echo "No command given"
> exit
> else
> command=$1
> fi
>
> # This is the distant node you are remote controlling from
> srcnode="1998"
>
> # This is the remote nodes IP address or domain name
> # Can be a local (LAN) address or anywhere on the Internet
> remote_address="127.0.0.1"
>
> #"This is the remote nodes ssh port
> port="222"
>
> #"This is the command to be executed"
> full_command="\"rpt fun $srcnode $command\""
>
> # The -f specifies where the password for this login is located
> # This file must be protected or use keys instead.
>
> sshpass -f /root/pname ssh -o StrictHostKeyChecking=no root@$remote_address
> -p $port "asterisk -rx $full_command"
>
> # END of script
>
>
> *73 Doug*
>
> *WA3DSP*
>
> *http://www.crompton.com/hamradio <http://www.crompton.com/hamradio>*
>
>
> On Tue, Feb 5, 2019 at 8:51 PM "Luc Drolet VE2LUQ via ARM-allstar" <
> arm-allstar at hamvoip.org> wrote:
>
>> Good night, Doug.
>>
>> OK, I'll make myself better understood with this file attached PDF
>>
>> My main Node is 1400 ve2luq.com
>> And I'm mobile on a 1410 NODE with my car
>> And I want to connect a repeater to Richboro fires the NODE 1800 for
>> example.
>> Is there a method I can do my connection because I'm not on the main node
>> so this node has the function in RPT. conf
>>
>> I can't do * 31800 because I'm not on the main node, I'm on a secondary
>> node of my main node.
>>
>> Is there a connection method?
>>
>> Thank you for your help
>>
>> 73’s
>> Luc
>>
>>
>>
>>
>>
>>
>>> Le 5 févr. 2019 à 02:51, Doug Crompton via ARM-allstar <
>> arm-allstar at hamvoip.org> a écrit :
>>>
>>> Luc,
>>>
>>> I am really not understanding your explanation. But I gather what you
>> want
>>> to be able to do is connect private nodes. Private nodes need to be
>>> manually routed. Any node can connect to any other node if BOTH ends have
>>> the proper port and IP address info for the other node. In your situation
>>> using private nodes you must put the address information in manually in
>> the
>>> [nodes] stanza of rpt.conf. Every route to every other server needs to be
>>> in that stanza if you want a connection between them. This includes the
>>> port. There is a howto on this at hamvoip.
>>>
>>>
>>> *73 Doug*
>>>
>>> *WA3DSP*
>>>
>>> *http://www.crompton.com/hamradio <http://www.crompton.com/hamradio>*
>>>
>>>
>>> On Mon, Feb 4, 2019 at 8:16 PM "Luc Drolet VE2LUQ via ARM-allstar" <
>>> arm-allstar at hamvoip.org> wrote:
>>>
>>>> Hello to you,
>>>>
>>>> Is it possible to make remote NODE, I explain
>>>>
>>>> I have my main node 1400 that it all the info from the external
>> repeaters
>>>> are in its RPT. conf of node 1400
>>>>
>>>> So if I'm on one of its nodes is it possible to make a connection to
>> other
>>>> repeaters, for example connection to node 1800 and that the info of node
>>>> 1800 is only in the RPT. conf of 1400 and I am on a node that is
>> already in
>>>> connection with the node 1400 by Example NODE 1410 and I want to connect
>>>> 1800
>>>>
>>>> If I would be on the node 1400 I would * 31800 but because I am on node
>>>> 1410 I can not do this with my microphone in DTMF
>>>>
>>>> Is there a solution?
>>>>
>>>> Thank you and good evening
>>>>
>>>> 73’s
>>>> Luc
>>>> VE2LUQ
>>>>
>>>>
>>>> _______________________________________________
>>>>
>>>> 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 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 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 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 web page - http://hamvoip.org
More information about the ARM-allstar
mailing list