Hello,
I am running Aztech DSL600E DSL Modem with IP 192.168.1.1 (in bridge mode) with the following firmware information :
Linux RouterTech.AR7RD 2.4.17_mvl21-malta-mips_fp_le #1 Wed Jul 23 00:24:31 BST 2008 mips unknown
BUILD=RouterTech_3.6.0D_20080723_2.60
VERSION=3.6.0D-RouterTech-1P-PSBL
BOARD=AR7RD
It is connected to the WAN port of a Linksys WRTSL54GS IP 192.168.10.1 which is acting as the gateway / DHCP for the rest of the network. I can access the modem interface just by writing its IP address in the web browser.
It is happening quite often these days that my internet service locks up for no reason at random intervals and modem thus hangs. Sometimes it disconnects and never connects again (the connection light keeps blinking). The remedy to such problems are usually a cold boot (turning off and on the modem) or doing a software reset using the System --> Reboot Router --> Yes Reboot Now (Button).
Since I am not usually at home to monitor this, I need to write a script in the Linksys router interface that if it detects the disconnection to internet it should reboot the router and wait for "x" amount of time before checking and ensuring that connectivity has been restored.
So based on the collective experience of the folks here, can some please guide me a script to preferably Turn OFF and ON (Cold Boot) or at least do the Reboot Router (Soft Boot) of the DSL modem to remedy the situation.
It maybe something like which I have already tried, which is, keep checking the ping connectivity to any website (google.com for example) every "x" amount of time, if the ping response is not received (maybe within y" amount of time), then run the DSL modem reboot script and wait for it to come back.
I m novice in Linux and in router configuration. However I know where to write script in Linksys Interface (Tomato Firmware v1.27.8747 ND USB vpn3.6), I just need the right code to be placed over there.
Thanks for reading and replying.
Script :Cold-ReBoot or Soft-ReBoot the Modem with RT 2.4.17
- thechief
- RouterTech Team
- Posts: 12067
- Joined: Wed Feb 01, 2006 10:22 pm
- Location: England, the Centre of Africa
- Contact:
Re: Script :Cold-ReBoot or Soft-ReBoot the Modem with RT 2.4.17
The Chief: Be sure to read the Firmware FAQ and do a Forum Search before posting!
No support via PM. Ask all questions on the open forum.
No support via PM. Ask all questions on the open forum.
Re: Script :Cold-ReBoot or Soft-ReBoot the Modem with RT 2.4.17
If its the DSL light that flickers it would be worth experimenting with different versions of RouterTech firmware which will have different DSL drivers, I don't recall what the 1-port 2MB flash used in 2.6.
Checksync wouldn't work if the modem in "PPPoE" full bridge mode, as the modem won't have direct access to the internet - but then special firewall commands needed to get access to the modem. In "PPPoE" full bridge mode the username and password are entered into Tomato, not the modem. Not being in this mode on a ram challenged modem could be the root cause of such problems.
Checksync wouldn't work if the modem in "PPPoE" full bridge mode, as the modem won't have direct access to the internet - but then special firewall commands needed to get access to the modem. In "PPPoE" full bridge mode the username and password are entered into Tomato, not the modem. Not being in this mode on a ram challenged modem could be the root cause of such problems.
Re: Script :Cold-ReBoot or Soft-ReBoot the Modem with RT 2.4.17
mstombs wrote:If its the DSL light that flickers it would be worth experimenting with different versions of RouterTech firmware which will have different DSL drivers, I don't recall what the 1-port 2MB flash used in 2.6.
Checksync wouldn't work if the modem in "PPPoE" full bridge mode, as the modem won't have direct access to the internet - but then special firewall commands needed to get access to the modem. In "PPPoE" full bridge mode the username and password are entered into Tomato, not the modem. Not being in this mode on a ram challenged modem could be the root cause of such problems.
So any other fruitful ideas that can really work. It would be a big help.thechief wrote:firmware-faq/#checksync
In my tomato interface (Linksys WRTSL54GS) I have already written a script to check the connectivity, I just need to hard-reset or soft-reset the modem when the condition occurs. The script is as follows :
I am basically controlling the Linksys GPIO PIN 5 (as a test example ) and printing the modem hang up failure frequency in a text file for later reference. I call this script as ping_check.sh which is called by a cron job after every minute.#!/bin/sh
DATE=`date`
x=`ping -c1 66.102.7.104 2>&1 | grep 100%`
if [ ! "$x" = "" ]; then
gpio disable 5; sleep 5; gpio enable 5;
PRINT="Modem Failure and Restart (5 second delay) @ "$DATE;
echo $PRINT >> /jffs/modemlog.txt;
fi
Ideas are awaited.
Thanks.
Re: Script :Cold-ReBoot or Soft-ReBoot the Modem with RT 2.4.17
What does the modem log say when you lose connection - if the modem is actually crashing you would need a hardware watchdog to power cycle, but I've even seen a mod for that over at Linksysinfo. If the modem is actually crashing you won't be able to see the log - but do post a copy of the system diagnostics from the current version of RouterTech and let us see if we can see a configuration problem - it is not normal!
Re: Script :Cold-ReBoot or Soft-ReBoot the Modem with RT 2.4.17
I have searched the modem firmware directory for this file.thechief wrote:firmware-faq/#checksync
Can someone please guide where is this shell script located, or maybe just post the contents of this script so I can explore it.
Thanks.
Re: Script :Cold-ReBoot or Soft-ReBoot the Modem with RT 2.4.17
Look on your RouterTech router under /usr/local/bin/
The scripts are built-in, and there's more than one and cron used to schedule. At the heart there is a ping script which expects that the modem can reach google (or other user defined), and if all else fails a reboot is requested. I'm pretty sure ping would always fail from a bridged modem.
The scripts are built-in, and there's more than one and cron used to schedule. At the heart there is a ping script which expects that the modem can reach google (or other user defined), and if all else fails a reboot is requested. I'm pretty sure ping would always fail from a bridged modem.