Stand-alone Nodes

There are times when a node will need to be set standalone. For example:

There is downsides:

Ground work(Edit)

This will only work on VKLink version 2 and up.

Before you disconnect your node from the network, you will have to change download the aststart script, and modify the initial startup script:

Download the script:(Edit)

# wget http://reporting.vklink.com.au/scripts/aststartpi3.sh -O /usr/aststart.sh
# chmod +x /usr/aststart.sh

Editing the scripts(Edit)

Now you have to edit the startup.sh script to invoke this. Here is the original file:

#/bin/bash
until /usr/bin/wget --no-check-certificate -q --tries=10 --timeout=20 --spider --delete-after https://reporting.vklink.com.au; do
    echo "No Internet Connectivity" >&2
    sleep 2
done
        
/usr/bin/wget --no-check-certificate -N "https://reporting.vklink.com.au/startuppi3.sh" -O /root/astrun/startup2.sh
chmod +x /root/astrun/startup2.sh
/root/astrun/startup2.sh &

Modify it to look like this:

#/bin/bash
#until /usr/bin/wget --no-check-certificate -q --tries=10 --timeout=20 --spider --delete-after https://reporting.vklink.com.au; do
#    echo "No Internet Connectivity" >&2
#    sleep 2
#done
        
#/usr/bin/wget --no-check-certificate -N "https://reporting.vklink.com.au/startuppi3.sh" -O /root/astrun/startup2.sh
#chmod +x /root/astrun/startup2.sh
#/root/astrun/startup2.sh &

sleep 10
#restart asterisk
/usr/sbin/asterisk
sleep 10
killall asterisk
killall asterisk
echo "waiting"
sleep 10
/usr/aststart.sh &

Editing rpt.conf(Edit)

After this is done, edit /etc/asterisk/rpt.conf and add this line to each node:

standalone=1

Changes in raspiconfig(Edit)

The raspi is set to not start unless a network cable is in. This has to be changed

run:

# sudo raspiconfig

Got to:

Boot options, press ENTER

Wait for network, press ENTER

and Select NO.

Testing(Edit)

Without a network cable plugged in, do a reboot and Asterisk should start and stay started after 30 seconds.

Main page | Advanced Stuff

Menu

Article:

Search: