Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 19 Jul 2002 14:59:52 -0600
From:      Jason Porter <leporter@xmission.com>
To:        Thomas Connolly <tconnolly@electrosoftsolutions.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: cron and cvsup
Message-ID:  <3D387DC8.3000102@xmission.com>
References:  <71ED4DBF1EA19A45A3765CA9548BE30A2124@server1.electrosoftsolutions.com>

next in thread | previous in thread | raw e-mail | index | archive | help
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Thomas Connolly wrote:
| Hello,
| I'm brand new to FreeBSD and Unix both.  Could someone provide me with an
| example of how to create a both a cron tab and a cron job to run cvsup
once
| every month?  I need it explained in terms a 2 year old could understand.
| I've looked at the man pages for cron and cvsup but it's over my head.  I
| was told in the newbies list to post all my questions here so I
apologize to
| all you guru's here.
|
| Thanks in advance,
|
| Tom
|
| To Unsubscribe: send mail to majordomo@FreeBSD.org
| with "unsubscribe freebsd-questions" in the body of the message
|
|

Okay, from the shell you can type crontrab -e.  That'll let you edit the
crontab.  Now if you want to use cvsup you'll have do this as root.  So
you log in as root and type crontab -e.  You'll then be given the
crontab for that user, or a blank crontab if there isn't one in place
already.  You'll be editing the tab in whatever editor $EDITOR is set
for.  On a basic install without any changes I believe this is vi.
There are a couple of ways to setup a monthly cron process, probably the
easiest is do something like this:

PATH=/usr/bin:/bin:/usr/local/bin
@monthly  cvsup <supfile>

Then save that, if you're in vi <ESC>:wq<ENTER>  Then you're done.  That
process will run every month on the first day at midnight.  Now the
reason for PATH is that cvsup is typically in /usr/local/bin on FreeBSD,
which isn't loaded as part of the default path for cron.

Any output or errors from your crontab are mailed to the owner of the
crontab by default, so make sure to check that root mail every so often :)

If anyone else has anything to add, please do.

- --
- -Jason Porter

"Real programmers are secure enough to write
readable code, which they then self-righteously
refuse to explain."
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE9OH3DYV2rputn/eARAoYNAJ44usoLOwfNnDCvPylWgWx7EuLLXgCgiWXw
jqZ6b38isG2AobHZSxdoYT8=
=posw
-----END PGP SIGNATURE-----


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3D387DC8.3000102>