[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [cobalt-users] Cron jobs



>I have ftp-ed two .pl files to cron.quarter-hourly (that does mean they
>should execute every 15 mins right??)
Yes, that is what it means, you are correct.
I'm not sure I'd put the files themselves in there, I'd stick the files
in
a bin file someplace and put a file in cron.quater-hourly that calls the
.pl
script by its path. The idea of sticking scripts in there makes me
shudder.
I know Cobalt installs some .pl files in those directories, I just think
it's
a bad idea.

>But they don't seem to do anything, when i execute them by
>hand they work fine though, do i need to do anything else??
check permissions *and* check ownership!
they should be: owner=root group=root and 755 on perms,
although I know cron will tolerate tighter perms, so you might wanna
play with permissions.
Speaking of permissions, from a security standpoint, *If* you begin
using /etc/crontab to run jobs which can give someone extra information
about your system, make sure to:
chmod 640 /etc/crontab

Here's how I learned about cron:
1. I found some www references to cron (and crontab which is undoubtedly
the user's best friend)
2.THEN I threw together a shell script that wrote the system uptime to a
file
(so that I could prove if the crontab entry was working at the required
times or not)
and pounded on crontab until I understood the syntax, and the file was
being written to properly.

Cobalt, bless their hearts, has this cron.hourly "dot daily" and so on,
which although it works seems
oh, I dunno..."clunky" to me somehow. I prefer the slightly more complex
but *much* more powerful
traditional way of getting stuff to run as a cron job.

Here are some starting points for your journey into the land of cron (a
friendly place I might add, there are no monsters waiting to eat you!)
http://www.act.ucsd.edu/dba/cron.html
Useful, pretty, informative polite. UC San Diego...it figures. Thanks
guys!! :-)
http://www.gdn.net/help/crontab_howto.html
If memory serves me correctly, this is the reference I used to get
started with cron jobs when I got my first redhat box working. It's ugly
to look at, but meaty and helpful.

HTH
Regards,
-Colin
--
Colin J. Raven