Met with GM Broadband @ MTNL last Friday and he told me that their portal software was not ready to handle NU and non NU hours for the NU plan i.e. if the login sessions spans over NU and non NU hours, the traffic could counted towards "additional usage" leading to the overcharge nightmare I posted a few weeks back. He told me to turn the modem off/on @ 00:00 and 08:00 which would create fresh login sessions until the portal vendor provides them with a fix (this method was also discussed in this list).
Fortunately, with a Linux/*nix box, the following script can automate this annoying chore. You need expect and tcl packages installed in your box.
Enjoy, -- Arun Khan
<script> #!/usr/bin/expect -f ########################################################################### # Name: dsl502t-reboot (install in /usr/local/bin, owner:group root.root # and file perms 700) # Purpose: Reboot the DLink 502T ADSL modem/router # Author: Arun Khan (knura at yahoo dot com) # Warranty: None - if it breaks your system, you get to keep all the # pieces :) # Usage: Create a file with the following lines and install it in # /etc/cron.d - do not forget to remove "#" for the 2 entries ########################################################################### # reboot MTNL ADSL modem #1 0 * * * root /usr/local/bin/dsl502t-reboot #59 7 * * * root /usr/local/bin/dsl502t-reboot ###########################################################################
# change the ip number if different spawn telnet 192.168.1.1 expect "ogin:" { send "root\r" } # change the password if different expect "ssword:" { send "admin\r" } expect "#" { send "reboot\r" } expect eof </script>
On Monday 21 November 2005 12:00, Arun K. Khan wrote:
Met with GM Broadband @ MTNL last Friday and he told me that their portal software was not ready to handle NU and non NU hours for the NU plan i.e. if the login sessions spans over NU and non NU hours, the traffic could counted towards "additional usage" leading to the overcharge nightmare I posted a few weeks back. He told me to turn the modem off/on @ 00:00 and 08:00 which would create fresh login sessions until the portal vendor provides them with a fix (this method was also discussed in this list).
Fortunately, with a Linux/*nix box, the following script can automate this annoying chore. You need expect and tcl packages installed in your box.
Enjoy, -- Arun Khan
Mind if I distribute the script "as-is" ? I would know some people that would be grateful :)
Thanks,
On Mon, 2005-11-21 at 18:42 +0000, Dinesh Joshi wrote:
On Monday 21 November 2005 12:00, Arun K. Khan wrote:
Fortunately, with a Linux/*nix box, the following script can automate this annoying chore. You need expect and tcl packages installed in your box.
Enjoy, -- Arun Khan
Mind if I distribute the script "as-is" ? I would know some people that would be grateful :)
Not at all. I know there quite a few TriBand users in this list; that is why I posted it here.
Arun K. Khan wrote:
Not at all. I know there quite a few TriBand users in this list; that is why I posted it here.
Hello Arun,
Where is the original mail with the script? I will get triband installed any day whenever mtnl is in a mood to deliver. I placed my order 13 days ago. :D
Regards,
Rony.
___________________________________________________________ WIN ONE OF THREE YAHOO! VESPAS - Enter now! - http://uk.cars.yahoo.com/features/competitions/vespa.html
Hello Arun, Thanks for the script Arun I do know that quiet a few people will be breathing a lot easy because of this....
Derwyn
On Monday 21 November 2005 15:57, Rony Bill wrote:
Hello Arun,
Where is the original mail with the script? I will get triband installed any day whenever mtnl is in a mood to deliver. I placed my order 13 days ago. :D
Regards,
Rony.
Heres the script:
<script> #!/usr/bin/expect -f ########################################################################### # Name: dsl502t-reboot (install in /usr/local/bin, owner:group root.root # and file perms 700) # Purpose: Reboot the DLink 502T ADSL modem/router # Author: Arun Khan (knura at yahoo dot com) # Warranty: None - if it breaks your system, you get to keep all the # pieces :) # Usage: Create a file with the following lines and install it in # /etc/cron.d - do not forget to remove "#" for the 2 entries ########################################################################### # reboot MTNL ADSL modem #1 0 * * * root /usr/local/bin/dsl502t-reboot #59 7 * * * root /usr/local/bin/dsl502t-reboot ###########################################################################
# change the ip number if different spawn telnet 192.168.1.1 expect "ogin:" { send "root\r" } # change the password if different expect "ssword:" { send "admin\r" } expect "#" { send "reboot\r" } expect eof </script>