Cron question
Stuart Sears
stuart at sjsears.com
Sun Sep 12 22:06:32 UTC 2004
On Saturday 11 September 2004 21:50, Martin Alderson wrote:
> I'd recommend using Pico or Nano instead of Vi/emacs or anything. It
> just seemed far more usable to me at least, and I don't do much
> command line text editing (just config settings and similar).
If you do use pico/nano be aware that they forcibly insert line breaks on
extra long lines unless run with the -w switch:
e.g. nano -w filename
personally I believe that know ing the basics of vi(m) would stand anyone in
good stead, particularly as it is the only editor in the rescue environment
for when things really do go totally hatstand.
still, while I'm on the thread, an attempt at the original question:
were you after help with cron or with rsync?
in any case the following line in the file you edit with crontab -e will work:
# crontab format follows:
# Min Hour DoM Month DoW Command
# at 04:04 every day sync source to target
04 04 * * * rsync -a source target
alternatively this is something that would work well as a system daily cron
job - write a script to do your backup and drop it into /etc/cron.daily
(don't forget to make it executable)
which should run it at about 4 am every day. Be aware that if you do this it
will run as root, which may not be what you require.
Stuart
--
Stuart Sears RHCE, RHCX
--
I'm so miserable without you, it's almost like you're here.
More information about the fedora-list
mailing list