(Answer) (Category) Faq-O-Matic Faq-O-Matic : (Category) Administrators' Guide : (Category) Maintain :
Automatic Maintenance
The installer should have set up your crontab to automatically run the maintenance module on an hourly basis. The maintenance module does these things:

- rebuilds the search database when needed
- culls stale cookies from the cookie file
- summarizes yesterday's access log
- removes old Unique Host Database (uhdb) files (part of the access log)
- removes temporary files from postponed user submissions that were never
completed
- truncates the 'errors' log and mails the old portion to the admin
- verifies that the cached files in $cacheDir (if configured) are up to date; regenerating those that aren't.

If you suspect the automatic maintenance script is not working correctly, check the file 'lastMaintenance' in your meta directory. If it's more than an hour old, your crontab script isn't running.

First, try "Running maintenance manually" from the install menu and make sure it acts normally (and lastMaintenance is updated).

If that works, try installing the cron entry again from the install menu. It should display the old cron line that it replaced.

If that seems right, perhaps your web scripts run as 'nobody,' which on some systems aren't allowed to submit cron jobs. In this case, you can install the cron job as another user. Since it invokes the module via an HTTP connection, having a different user run the cron job still works.

The reason that automatic maintenance is always invoked via an HTTP request is to ensure that the scripts that do the maintenance run in exactly the same environment as the scripts that service direct user requests. Otherwise, file permissions and RCS metadata can get put into strange states, causing subtle misbehavior.
[Append to This Answer]
Next: (Answer) Access Logs
This document is: http://www.jonh.net/cgi-bin/faqomatic/fom?file=43
[Search] [Appearance]
This is a Faq-O-Matic 2.718d.
Hosted by SourceForge Logo and jonh.net.