The system of automatic old statistics removal lets you keep the database size, avoiding its uncontrolled growth.
The process of old data removal takes place in a background mode and therefore requires constant functioning of the cron script. No matter how often the cron script is launched, the process of old data removal will be taking place in the intervals you specify.
You can remove both complete visitors’ paths and parts of paths that are non-significant for statistics. Besides, you can remove the data that is not used in the statistics (referrers, keywords, visitors, site pages, products, action targets). Non-used data appears when the visitors’ paths have been removed but the additional information remains in other tables.
Every time after old statistics removal the database will still have non-used records left. As the program is meant to work with MySQL version >= 4.0, we can not use methods of automatic removal of non-used records that are available in MySQL starting with version 5.0 and any other “normal” databases.
You can specify the time period that should not be removed during old data removal – for example, not to affect the data within a year (starting from the current date backwards) or the last three months. Besides, you can specify a particular time period (from date to date) of statistics to be removed. You can specify separate settings for each particular client company.
Database cleaning will not affect the data to be archived, providing that Archiving function is enabled.
In case you want to launch automatic old statistics removal but doubt if it will affect the data that should be archived -- do not doubt. It will not. On the contrary, the database clearing might fail to remove anything if Archiving function is on but nothing has been archived yet.
Manual Statistics Removal
Besides the automatic old statistics data removal there is also a manual method. You will find the manual removal form in the section “Administration / Database”. The form only appears in case “Automatic mode” is disabled. We strongly recommend you to use the automatic mode. There is no big difference between the two modes of removal as the used settings and the code are the same. It is only that the manual mode launches the process in real time via a special HTTP request which means that the removal process will obey your server's PHP script execution timeout settings. If the removal process will take too long it might get terminated by PHP prematurely which may damage the database integrity. Besides, the cron script watches the server load and goes to the sleeping mode if the load exceeds the critical level. The real time removal process does not do this.
That is why we deliberately made the manual removal form not so easy to access.
The only reason why we have made this form at all is because you might not have an ability to setup the cron script on your server.
If you do not have any special reason to launch the manual removal, please use the auto removal mode. It requires constant functioning of cron script, but on the other hand the PHP timeout settings have no effect on the script running in a background mode and you can be sure the cron script will finish its work.
If you need to remove statistics as a one-shot job, in the settings you should specify that the removal process should be launched once a month (if it is not the first night of the month, the automatic removal will be waiting for the next appropriate period) and press the button “Run removal process as soon as possible”. Afterwards you can reload the page from time to time to check if the button is active again, or you can use the cron processes monitoring. As soon as the removal process is complete you can disable the automatic removal mode.
Copyright © Stuffed Guys — XXI century