Restricting Periodic Scripts

Polytropon freebsd at edvax.de
Wed Feb 6 18:00:37 UTC 2013


On Wed, 6 Feb 2013 09:26:17 -0800, Tim Gustafson wrote:
> I have a FreeBSD ZFS file server with tens of millions of files stored on it.
> 
> But, the daily periodic scripts like
> /etc/periodic/security/110.neggrpperm and
> /etc/periodic/weekly/310.locate take hours iterating through those
> folders, and I just don't need them to be scanned.
> 
> I see that I can edit /etc/locate.rc to fix the behavior for
> /etc/periodic/weekly/310.locate but I don't see a way to exclude
> folders from other scripts like /etc/periodic/security/110.neggrpperm
> from scanning them.  Is there any way to prune out folders that I
> don't want scanned, or should I just disable those jobs?

You can disable them per /etc/periodic.conf (see examples in
/etc/defaults/periodic.conf). To keep the functionality, but
restrict it to a smaller amount of files, you could use the
system's scripts as templates, make your own "derivates"
(wich inclusion or exclusion rules) and place them in
/usr/local/etc/periodic for the system to call them (which
it will if they are present). You can add your custom
configuration flags to /etc/periodic.conf and have your
scripts source that file (like the system's scripts do).




-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...


More information about the freebsd-questions mailing list