memphis2k
Occasional Visitor
Did a little searching but found nothing that worked.
ASUS-Merlin 384.19 running on a RT-AC68U.
Script works manually, but I can't get CRON to run it after a reboot.
ping_google.sh
init-start
Running cru l
All scripts are 755
Nothing in syslog after a reboot. I have JFFS scripts turned on Admin / System. Running VLANs & Wifi Proximity scripts with no issues, however, not as CRON.
ASUS-Merlin 384.19 running on a RT-AC68U.
Script works manually, but I can't get CRON to run it after a reboot.
ping_google.sh
Code:
#!/bin/bash
#ping google and send a REST command back to ISY. Then ISY sends to Pushover
#Using curl because it doesn't create 0 files in directory
ping -q -c 1 -w 5 google.com > /dev/null
if [ $? -eq 0 ]; then
echo "House Online - Google"
curl --silent --output /dev/null http://**********/rest/vars/set/2/19/0
logger -t PX_DETECT "House Online - Google";
else
echo "House Offline - Google"
curl --silent --output /dev/null http://****************/rest/vars/set/2/19/1
logger -t PX_DETECT "House Offline - Google";
fi
init-start
Code:
#!/bin/sh
cru a pinggo "* * * * * /jffs/scripts/ping_google.sh"
Running cru l
Code:
admin@RT-AC1900P-33D8:/tmp/home/root# cru l
* * * * * /jffs/scripts/ping_google.sh #pinggo#
All scripts are 755
Nothing in syslog after a reboot. I have JFFS scripts turned on Admin / System. Running VLANs & Wifi Proximity scripts with no issues, however, not as CRON.