custom periodic scripts
Paul Schmehl
pauls at utdallas.edu
Fri Jan 28 15:58:56 PST 2005
--On Friday, January 28, 2005 10:32:35 PM +0000 Xian <ian at codepad.net>
wrote:
> How would I go about adding scripts to periodic? I particular I have a
> couple of scripts to fetch virus definitions and scan my system.
> I gathered the is a 'proper' way to do it by using
> /usr/local/etc/periodic but not how to do it.
Write the script. Put it in /etc/periodic/{period you want}
Name it xxx.name (as in some number that isn't already used. Scripts are
run in numerical order.)
Make it executable for root.
Edit the /etc/periodic.conf file to enable it. See the man page for
details, but the syntax is period_scriptname_enable="YES"
For example, write a script name "foo". Make it 250.foo and put it in
/etc/periodic/daily. Chown it root:wheel and chmod it 750. Edit
/etc/periodic.conf to read daily_foo_enable="YES".
Paul Schmehl (pauls at utdallas.edu)
Adjunct Information Security Officer
The University of Texas at Dallas
AVIEN Founding Member
http://www.utdallas.edu
More information about the freebsd-questions
mailing list