Asus router stopped logging after using ChkWAN.sh

Salty Wagyu

Occasional Visitor
I installed using curl --retry 3 "https://raw.githubusercontent.com/MartineauUK/Chk-WAN/master/ChkWAN.sh" -o "/jffs/scripts/ChkWAN.sh" && chmod 755 "/jffs/scripts/ChkWAN.sh"

Then nano /jffs/scripts/wan-start
added:
sh /jffs/scripts/ChkWAN.sh &
then chmodded 755 wan-start

It was working but I wanted it to ping less, found an entry that does it every 5 minutes, so I changed it to:
sh /jffs/scripts/ChkWAN.sh cron=\*/5

This didn't seem to do anything after 5 minutes, so I tried removed the \ and manually restarting wan (Internet Connection On/Off) in the webui to see if this made a difference. Now I'm not sure if its running because the logs in System Log are completely blank.

I've reverted back to sh /jffs/scripts/ChkWAN.sh & and restarted the router, but the logs remain blank, have I broken something?
./ChkWAN.sh status reports it is active
cat /tmp/syslog.log shows my active log but still nothing in the webui

On latest RT-AX86U Merlin firmware

edit: After using cat/temp/syslog.log to troubleshoot chkwan it doesn't run every 5 minutes, there is a crond parse error at proc/5

[email protected]:/jffs/scripts# crontab -l
*/3 * * * * /jffs/scripts/connmon generate #connmon#
proc/5 * * * * /jffs/scripts/ChkWAN.sh #WAN_Check#
[email protected]:/jffs/scripts# cat wan-start
sh /jffs/scripts/ChkWAN.sh cron=\*/5 &
 
Last edited:

Salty Wagyu

Occasional Visitor
Logs are working again in the UI, only had to press the clear button to fix it. Wouldn't have thought to try that but it worked

If anyone knows about the cron issue I would appreciate some assistance with that!
 

Martineau

Part of the Furniture
If anyone knows about the cron issue I would appreciate some assistance with that!
I think you need to specify a complete cron specification

e.g. Perform a check every 13 minutes
Code:
/jffs/scripts/ChkWAN.sh cron="\*/13 \* \* \* \*"

    ChkWAN scheduled by cron

*/13 * * * * /jffs/scripts/ChkWAN.sh #WAN_Check#


(ChkWAN.sh): 8965 v1.17 WAN connection status monitoring will begin in 10 seconds.....

(ChkWAN.sh): 8965 v1.17 Monitoring WAN connection using 4 target PING hosts (192.168.0.1 192.168.0.1 9.9.9.9 1.1.1.1) (Tries=3)
(ChkWAN.sh): 8965 Monitoring pass 1 out of 3
(ChkWAN.sh): 8965 Private LAN 192.168.0.1 will be skipped for WAN PING check!
(ChkWAN.sh): 8965 Private LAN 192.168.0.1 will be skipped for WAN PING check!

(ChkWAN.sh): 8965 Monitoring WAN connection OK.....(Successful ping to '9.9.9.9'); Terminating due to ACTIVE cron schedule
Code:
cru l

*/13 * * * * /jffs/scripts/ChkWAN.sh #WAN_Check#
Obviously it is just as easy to manually create the cron schedule without invoking the script

e.g. Perform a check every 7 miniutes
Code:
cru a ChkWAN "*/7 * * * * /jffs/scripts/ChkWAN.sh"

cru l

*/13 * * * * /jffs/scripts/ChkWAN.sh #WAN_Check#
*/7 * * * * /jffs/scripts/ChkWAN.sh #ChkWAN#
 
Last edited:

Similar threads

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top