Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Need help with some simple scripts and automation tasks.

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
Tyson0317
Posts: 13
Joined: 2006-01-02 01:21

Need help with some simple scripts and automation tasks.

#1 Post by Tyson0317 »

This is a repost from the General Questions forum. It sat there for 2 days without any replies. So I deleted and reposted here.

Hi all. I finally got my EVDO box running! Now it's time to automate some of the functions.

#1 I would like my box to dial up on it's own when it is powered on without having to log on.
#2 I would like my box to check the dial-up connection via Ping every 1-2 minutes. If it is down, I would like it to re-dial.
#3 I would like another scipt to reboot the whole box if the internet connection is down for more than 5 minutes.
#4 There are a few other scripts that I would like to run as it boots, before it is even logged in. How do I do this?

Ohh, I am running Debian 2.6 kernel in text mode. I am also using wvdial for my dial-up connection.

Thanks to everyone for your help.

User avatar
Humbletech99
Posts: 365
Joined: 2005-12-29 00:03

#2 Post by Humbletech99 »

these aren't that simple questions.

I assume that you are comfortable with Bash Scripting?

firstly, I've never used dial-up on linux, only lan, but I would use the commands with a bit of Bash Scripting cleverness to automate them and then cron them to run frequently to check the status of the connection etc.. and if it's down, then redial ...

For the startup script thing, what you want it something similar to the rc.local script. To my knowledge there is no such thing in Debian and therefore you must do the full Sys V init style thing and write a startup script possibly with a priority of of 99, again this needs to be done in Bash.

Alternatively, if you've got the scripts you can just add them individually to the default runlevel and get them to execute at the end, so by the time you see the login prompt they've already run.

Post Reply