scheduling tasks

Adam Davis ald at dovienya.net
Sun Jan 19 04:59:07 CST 2003


Hey.

Yeah, use cron to schedule tasks.  The list of cron jobs for the
current user can be easily seen via `crontab -l` and edited via `crontab -e`.

Hopefully, there's a job or two already in there so you can see the
format used (try `cat /etc/crontab`, too).  Generally, each job to be
run gets a line along in the form of:

minute hour day-of-month month day-of-week command

Where you've got either a number or a * for the time-indicators and then a
command.  * means that it doesn't matter, so:

* * * * * echo Test >> test.file

would add a line with the world 'Test' on it every minute.

* 2 * * * echo Test >> test.file

would add the same line, but once a day at 2 am.

Not incredibly complicated, but... still read your man pages ;)

I'm 17.  I've been using Linux for about 3 years.  (I dropped my
dependence on a certain other OS a little over a year ago.)

Also... Does RR not give you an effective static IP address?  I've got
two computers always connected, and their IP addresses change only when
they d/c for more than 30 minutes or so.  RR has never forced an IP
change.

~Adam Davis

On Sat, 18 Jan 2003, Matthew Freeland wrote:

> Salutations.  Does anyone know how to schedule tasks to run at a specified
> time interval?  I have registered a domain name and am using a service
> called everydns.net to route traffic from it's nameservers to my dynamic ip
> address, since I am using roadrunner.  This service requires you to use an
> IP address updating program to send your ip address to it's servers.  The
> problem is, apparently, it must be run manually.  I have placed it in my
> init.d folder, but because I do not plan on rebooting this server often, I
> need a way to run the program at least once per hour.  Is there a way in
> linux to schedule a program to run once per hour?  What would be even better
> would be a script that would monitor my wan ip address and run the program
> when it changes.  Could I write a shell script that would do this, and if
> so, could someone give me a brief example of how it might be done?
>
> Also, I am 18 and have recently joined kclug.  Are there any other members
> out there whom are approximately my age?  I have been using linux for about
> 6 months now and absolutely love it.
>
> Thank you in advance.
>
> Matthew Freeland
>
> _________________________________________________________________
> The new MSN 8: smart spam protection and 2 months FREE*
> http://join.msn.com/?page=features/junkmail
>
>
>
>




More information about the Kclug mailing list