make readme rst-compatible
[awstats-helper.git] / README.rst
1 AWStats helper scripts
2 ======================
3
4 We use AWStats[1] to get statistics about the web sites hosted
5 on our server.
6 Setting up AWStats for a single site is easy, but for multiple domains
7 it is really tedious work.
8 Further, the tools provided with AWStats that support multiple
9 configuration files do not support historic data.
10 There is i.e. no way to look at the detailled statistics of last month
11 or the stats for a site of two years ago.
12
13 These scripts provide the following functionality:
14
15 - Rendering of historical data
16 - Updating the current month's data and regenerating report files
17 - Regenerating last month's report files
18 - Index page generation linking to all this data
19
20 The scripts utilize ``awstats.pl`` and ``awstats_buildstaticpages.pl``
21 from the AWStats distribution.
22
23 [1] http://awstats.sourceforge.net/
24
25
26
27 Installation
28 ------------
29 0. copy ``config.php.dist`` to ``config.php``
30 1. Adjust ``config.php`` to your needs
31 2. Run ``update-sites.php`` to generate initial data collection
32 3. Run ``create-historic.php`` to create all historic files
33 4. Add ``update-sites.php`` to your crontab, let it run every hour
34 5. Add ``update-lastmonth.php`` to your crontab and let it run
35    on the first day every month
36
37
38 AWStats vhost host setup
39 ------------------------
40 AWStats needs a configuration file for each of the domains you want to analyze.
41
42 The file needs to be put in ``/etc/awstats/awstats.$domain.conf``,
43 e.g. ``/etc/awstats/awstats.cweiske.de.conf``.
44
45 Example::
46
47   Include "/etc/awstats/awstats.conf"
48   LogFile="/var/log/apache2/cweiske/cweiske.de-access.log"
49   SiteDomain="cweiske.de"
50   DefaultFile=""