File: awstats_setup.html

package info (click to toggle)
awstats 7.8-3%2Bdeb12u1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 14,336 kB
  • sloc: perl: 40,228; xml: 1,785; javascript: 1,493; java: 359; sh: 152; makefile: 40; php: 29
file content (590 lines) | stat: -rw-r--r-- 25,673 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<meta name="description" content="AWStats Documentation - Setup page">
<meta name="keywords" content="awstats, awstat, setup, config, install">
<meta name="robots" content="index,follow">
<meta name="title" content="AWStats Documentation - Setup page">
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
<title>AWStats Documentation - Setup page</title>
<link rel="stylesheet" href="styles.css" type="text/css">
</head>

<body topmargin="10" leftmargin="5">
<table
 style="font-family: arial,helvetica,verdana; font-style: normal; font-variant: normal; font-weight: normal; font-size: 10pt; line-height: normal; font-size-adjust: none; font-stretch: normal;"
 bgcolor="#ffffff" border="0" cellpadding="0" cellspacing="0"
 width="100%">
<!-- Large --> <tbody>
    <tr
 style="font-family: arial,helvetica,verdana; font-style: normal; font-variant: normal; font-weight: normal; font-size: 10pt; line-height: normal; font-size-adjust: none; font-stretch: normal;">
      <td align="center" bgcolor="#9999cc"><a href="/"><img
 src="images/awstats_logo6.png" border="0"></a></td>
      <td align="center" bgcolor="#9999cc"> <br>
      <font
 style="font-family: arial,helvetica,sans-serif; font-style: normal; font-variant: normal; font-weight: normal; font-size: 16pt; line-height: normal; font-size-adjust: none; font-stretch: normal;"
 color="#eeeeff"><b>AWStats logfile analyzer 7.8 Documentation</b></font><br>
<br>
</td>
      <td align="center" bgcolor="#9999cc">&nbsp; </td>
</tr>
  </tbody>
</table>
<br>
<br>
<h1
 style="font-family: arial,helvetica,sans-serif; font-style: normal; font-variant: normal; font-weight: normal; font-size: 26px; line-height: normal; font-size-adjust: none; font-stretch: normal;">AWStats
Installation, Configuration and Reporting</h1>
There are 3 steps to begin using AWStats:<br>
<ul>
  <li><a href="#INSTALL">I. Setup: Installation and configuration</a><br>
  </li>
  <li><a href="#BUILD_UPDATE">II. Process logs: Building/updating
statistics database</a><br>
  </li>
  <li><a href="#READ">III. Run Reports: Building and reading reports</a><br>
  </li>
</ul>
<br>

<!--
<br>
Before starting, check that your Perl version is at least 5.007 (or higher) by running the <i>perl -v</i> command.
If not, you can install a recent Perl interpreter from <a href="http://www.activestate.com/ActivePerl/">ActivePerl</a> (<font color=#221188>Win32</font>) or <a href="http://www.perl.com/pub/language/info/software.html">Perl.com</a> (<font color=#221188>Unix/Linux/Other</font>).<br>
-->
<br>
<a name="INSTALL">
<h2 style=""><u>I. Setup: Installation and configuration using
awstats_configure.pl</u></h2>
</a><br>
<a name="INSTALLAPACHE"><b>A) Setup for an Apache or compatible web
server (on Unix/Linux, Windows, MacOS...)</b></a><br>
<br>
<font style="color: rgb(17, 17, 85);"><b>* Step 1</b>:</font><br>
<br>
(if you use a package provided with a Linux distribution or Windows
installer, step 1
might have already been done; if you don't know, you can run this step
again)<br>
<br>
After downloading and extracting the AWStats package, you should run
the awstats_configure.pl script to do
several setup actions.
You will find it in the AWStats <b>tools</b> directory (If using the
Windows installer, the script is
automatically launched):<br>
<table border=1 cellpadding=1 cellspacing=0 bgcolor=#F4F4F4 width="95%" class=CFAQ><tr class=CFAQ><td class=CFAQ>
perl awstats_configure.pl
</td></tr></table>
<br>
<ul>
  <u>This is what the script does/asks (you can do all these steps
manually instead of running awstats_configure.pl if you prefer):</u><br>
<br>
A) awstats_configure.pl tries to determine your current log format from
your Apache web server
configuration file httpd.conf (it asks for the path if not found).
If you use a <b>common</b> log, awstats_configure.pl will
suggest changing it to the <b>NCSA combined/XLF/ELF</b> format (you
can use your own custom log
format but this predefined log format is often the best choice and
makes setup easier).<br>
If you answer yes, awstats_configure.pl will modify your <b>httpd.conf</b>,
changing the
following directive:<br>
  <i>from<br>
CustomLog /yourlogpath/yourlogfile common</i><br>
to<br>
<i>CustomLog /yourlogpath/yourlogfile combined</i><br>
<br>
See the Apache manual for more information on this directive (possibly
installed on your server as www.mysite.com/manual).<br>
  <br>
B) awstats_configure.pl will then add, if not already present, the
following directives to your Apache configuration file
(note that the "/usr/local/awstats/wwwroot" path might differ according
to your distribution or OS:<br>
  <i> <br>
# <br>
# Directives to add to your Apache conf file to allow use of AWStats as
a CGI. <br>
# Note that path "/usr/local/awstats/" must reflect your AWStats
Installation path. <br>
# <br>
Alias /awstatsclasses "/usr/local/awstats/wwwroot/classes/" <br>
Alias /awstatscss "/usr/local/awstats/wwwroot/css/" <br>
Alias /awstatsicons "/usr/local/awstats/wwwroot/icon/" <br>
ScriptAlias /awstats/ "/usr/local/awstats/wwwroot/cgi-bin/" <br>
# <br>
# This is to permit URL access to scripts/files in AWStats directory. <br>
# <br>
&lt;Directory "/usr/local/awstats/wwwroot"&gt; <br>
Options None <br>
AllowOverride None <br>
Order allow,deny <br>
Allow from all <br>
&lt;/Directory&gt; </i><br>
  <br>
C) if changes were made as indicated in parts A and B,
awstats_configure.pl restarts Apache to apply the changes.&nbsp; To be
sure the log format change is effective, go to your homepage. This is
an example of the type of records you should see inserted in your new
log file after Apache
was restarted:<br>
  <br>
62.161.78.75 - - [dd/mmm/yyyy:hh:mm:ss +0000] "GET / HTTP/1.1" 200 1234
"http://www.from.com/from.html" "Mozilla/4.0 (compatible; MSIE 5.01;
Windows NT 5.0)"<br>
  <br>
D) awstats_configure.pl will ask you for a name for the configuration
profile file. Enter an appropriate name such as that of your
web server or the virtual domain to be analyzed, i.e. <b
 style="font-style: italic;">mysite</b>.<br>
  <br>
awstats_configure.pl will create a new file called <b>awstats.<span
 style="font-style: italic;">mysite</span>.conf</b>
by copying the template file <b>awstats.model.conf</b>.
The new file location is:<br>
- For Linux/BSD/Unix users: /etc/awstats.<br>
- For macOS, Windows and other operating systems: the same directory
as awstats.pl
(cgi-bin).<br>
<br>

E) awstats_configure.pl ends.<br>
<br>
</ul>
<font style="color: rgb(17, 17, 85);"><b>* Step 2</b>:</font><br>
<br>
Once a configuration file has been created (by
awstats_configure.pl, by your package
installer or just by a manual copy of awstats.model.conf), it's
important to verify that the "MAIN PARAMETERS"
match your needs.&nbsp; Open awstats.<span
 style="font-style: italic; font-weight: bold;">mysite</span>.conf in
your favorite text editor (i.e. notepad.exe, vi, gedit, etc) -
don&acute;t use a word processor - and make changes as required.<br>
<br>
Particular attention should be given to these parameters:<br>
- Verify the <a href="awstats_config.html#LogFile">LogFile</a>
value.&nbsp; It should be the full path of your server log file (You
can also use a relative path from your awstats.pl directory, but a full
path avoids errors).<br>
- Verify the <a href="awstats_config.html#LogType">LogType</a>
value.&nbsp; It should be "W" for analyzing
web log files.<br>
- Check if <a href="awstats_config.html#LogFormat">LogFormat</a> is
set to "1" (for "NCSA apache combined/ELF/XLF log format")
or use a custom log format if you don't use the combined log format.<br>
- Set the <a href="awstats_config.html#SiteDomain">SiteDomain</a>
parameter to the main domain name or the intranet web server name
used to reach the web site to analyze (Example: www.mysite.com). If
you have several
possible names for same site, use the main domain name and add the
others to the list in the <a href="awstats_config.html#HostAlias">HostAlias</a>
parameter.<br>
- You can also change other parameters if you want. The full list is
described in <a href="awstats_config.html">Configurations/Directives
options</a> page.<br>
<br>
Installation and configuration is finished. You can jump to the <a
 href="#BUILD_UPDATE">Process logs: Building/updating statistics
database</a> section.<br>
<br>
<br>	
<br>
<a name="INSTALLIIS"><b>B) Setup for Microsoft's IIS server</b></a><br>
<br>
<font style="color: rgb(17, 17, 85);"><b>* Step 1</b>:</font><br>
<br>
Configure IIS to create logs in the <b>"Extended W3C log format"</b> (You can
still use
your own custom log format but setup is easier if you use the standard
extended format). To do so, start the IIS management console snap-in,
select the
appropriate web site and open its
<span style="font-weight: bold;">Properties</span>. Choose "<span
 style="font-weight: bold;">W3C Extended Log Format</span>", then <span
 style="font-weight: bold;">Properties</span>, then the
Tab "<span style="font-weight: bold;">Extended Properties</span>" and
uncheck everything under Extended
Properties.
Once they are all cleared, check just the following fields:<br>
<table width="95%" border=1 cellpadding=0 cellspacing=0 bgcolor=#F4F4F4 class=CFAQ><tr class=CFAQ><td class=CFAQ>
date<br>
time<br>
c-ip<br>
cs-username<br>
cs-method<br>
cs-uri-stem<br>
cs-uri-query<br>
sc-status<br>
sc-bytes<br>
cs-version<br>
cs(User-Agent)<br>
cs(Referer)<br>
</td></tr></table>
<br>
To be sure the log format change is effective, you must stop IIS,
backup it up (if you desire) and remove all of the old log files, restart IIS and go to
your homepage. This is an example of the type of records you should
find in the
new log file:<br>
<table width="95%" border=1 cellpadding=0 cellspacing=0 bgcolor=#F4F4F4 class=CFAQ><tr class=CFAQ><td class=CFAQ>
2000-07-19 14:14:14 62.161.78.73 - GET / 200 1234 HTTP/1.1
Mozilla/4.0+(compatible;+MSIE+5.01;+Windows+NT+5.0)
http://www.from.com/from.htm
</td></tr></table>
<br>

<font style="color: rgb(17, 17, 85);"><b>* Step 2</b>:</font><br>
<br>
Copy the contents of the AWStats provided cgi-bin folder, from where
the AWStats package put it on your local hard
drive,
to your server's cgi-bin
directory (this includes <b>awstats.pl</b>, <b>awstats.model.conf</b>,
and the <b>lang</b>, <b>lib</b> and <b>plugins</b> sub-directories).<br>
<br>
<font style="color: rgb(17, 17, 85);"><b>* Step 3</b>:</font><br>
<br>
Move AWStats <b>icon sub-directories</b> and its content into a
directory readable by your
web server, for example C:\yourwwwroot\icon.<br>
<br>
<font style="color: rgb(17, 17, 85);"><b>* Step 4</b>:</font><br>
<br>
Create a configuration file by copying <b>awstats.model.conf</b> to a
new file named <b>awstats.<span style="font-style: italic;">mysite</span>.conf</b>
where "<span style="font-style: italic;">mysite</span>" is a
value of your choice but usually is the domain or virtual host name.
This new file must be saved in the same directory as awstats.pl (i.e.
cgi-bin).<br>
<br>
<font style="color: rgb(17, 17, 85);"><b>* Step 5</b>:</font><br>
<br>
Edit your new <b>awstats.<span style="font-style: italic;">mysite</span>.conf</b>
file to match your specific environment:<br>
- Change the <a href="awstats_config.html#LogFile">LogFile</a> value
to the
full path of your web server log file (You
can also use a relative path from your awstats.pl (cgi-bin) directory).<br>
- Change the <a href="awstats_config.html#LogType">LogType</a> value
to
"W" for analyzing
web log files.<br>
- Change the <a href="awstats_config.html#LogFormat">LogFormat</a> to
2 if you are using the <b>"Extended W3C log format"</b> described in
step 1; in the case of a custom format, list the IIS fields
being logged, for example:<br>
<i>LogFormat="date time c-ip cs-username cs-method cs-uri-stem
cs-uri-query sc-status sc-bytes cs-version cs(User-Agent) cs(Referer)"</i><br>
- Change the <a href="awstats_config.html#DirIcons">DirIcons</a>
parameter to reflect relative path of icon directory.<br>
- Set the <a href="awstats_config.html#SiteDomain">SiteDomain</a>
parameter to the main domain name or the intranet
web server name used to reach the web site being analyzed (Example:
www.mydomain.com).<br>
- Set the <a href="awstats_config.html#AllowToUpdateStatsFromBrowser">AllowToUpdateStatsFromBrowser</a>
parameter to 1 if you don't have command line access and have only cgi
access.<br>
- Review and change other parameters if appropriate.<br>
<br>
Installation and configuration is finished. You can jump to the <a
 href="#BUILD_UPDATE">Process logs: Building/Updating statistics
database</a> section.<br>
<br>
<b>C) Setup for other web servers</b><br>
<br>
The setup process is similar to the setup for Apache or IIS.<br>
Use <a href="awstats_config.html#LogFormat">LogFormat</a> to value "3"
if you have WebStar native log format.
Use a personalized <a href="awstats_config.html#LogFormat">LogFormat</a>
if your log format is other.<br>
<br>
<b>D) Setup for other Internet servers, i.e. FTP, Mail, Streaming media</b><br>
<br>
The setup process for other file formats is described in the relevant
FAQ topics:&nbsp;
<a href="awstats_faq.html#FTP">FAQ-COM090: FTP</a>&nbsp;
<a href="awstats_faq.html#MAIL">FAQ-COM100: Mail</a> and <a
 href="awstats_faq.html#MEDIASERVER">FAQ-COM110: Streaming media</a>.<br>
<br>

<br>
<a name="BUILD_UPDATE">
<h2 style=""><u>II. Process logs: Building/updating statistics database</u></h2>
</a><br>
<font style="color: rgb(17, 17, 85);"><b>* Update from command line (recommended)</b>:</font><br>
<br>
The first log analysis should be done
manually from the command line since the
process may be long and it's easier to solve problems when you can see
the
command output (if you don't
have Command Line access, skip to Step 2). The
AWStats create (and update) statistics database command is:<br>
<br>
<table border=1 cellpadding=1 cellspacing=0 bgcolor=#F4F4F4 width="95%" class=CFAQ><tr class=CFAQ><td class=CFAQ>
perl awstats.pl -config=mysite -update
</td></tr></table>
<br>
where <span style="font-style: italic;">mysite</span> must
be substituted with the domain/virtual host name you selected earlier
during AWStats configuration.<br>
<br>
AWStats will read the configuration file awstats.mysite.conf
(or if
not found, awstats.conf)
and create/update its database with all summary information issued from
analyzed log file.<br>
<br>
AWStats statistics database files are saved in directory defined by the
<a href="awstats_config.html#DirData">DirData</a> parameter in
configuration file.<br>
When the create/update is finished, you should see a similar result on
your screen:<br>
<br>
<table width="95%" border=1 cellpadding=0 cellspacing=0 bgcolor=#F4F4F4 class=CFAQ><tr class=CFAQ><td class=CFAQ>
Update for config "/etc/awstats/awstats.mysite.conf"<br>
With data in log file "/pathtoyourlog/yourlog.log"...<br>
Phase 1 : First bypass old records, searching new record...<br>
Searching new records from beginning of log file...<br>
Phase 2 : Now process new records (Flush history on disk after 20000
hosts)...<br>
Jumped lines in file: 0<br>
Parsed lines in file: 225730<br>
&nbsp;Found 122 dropped records,<br>
&nbsp;Found 87 corrupted records,<br>
&nbsp;Found 0 old records,<br>
&nbsp;Found 225521 new qualified records.<br>
</td></tr></table>
<br>
<b>Dropped records</b> are records discarded because they were not
"user HTTP requests" or were requests matching AWStats filters (See the
<a href="awstats_config.html#SkipHosts">SkipHosts</a>,
<a href="awstats_config.html#SkipUserAgents">SkipUserAgents</a>,
<a href="awstats_config.html#SkipFiles">SkipFiles</a>, <a
 href="awstats_config.html#OnlyHosts">OnlyHosts</a>,
<a href="awstats_config.html#OnlyUserAgents">OnlyUserAgents</a> and <a
 href="awstats_config.html#OnlyFiles">OnlyFiles</a> parameters).
If you want to see which lines were dropped, you can add the <b>-showdropped</b>
option on the command line.<br>
<br>
<b>Corrupted records</b> are records that do not match the log format
defined by the "LogFormat" parameter in the AWStats configuration file.
All web servers will typically have a few corrupted records
(&lt;5%) even when everything works correctly.
This can result for several reasons: 1) Web server internal bugs,
2) bad requests made by buggy browsers, 3) a dirty web server shutdown,
such as unplugging the server...&nbsp; <br>
<br>
If all of your lines are corrupted and the <a
 href="awstats_config.html#LogFormat">LogFormat</a> parameter in
AWStats configuration file is
correct, then there may be a setup problem with your web server log format.
Don't forget that
your <a href="awstats_config.html#OnlyFiles">LogFormat</a> parameter
in the AWStats configuration file MUST match
the log file format you analyze.&nbsp; If you want to see which lines
are corrupted, you can add the <b>-showcorrupted</b>
option on the command line.<br>
<br>
<b>Old records</b> are simply records that were already processed by a
previous update session.
Although it is not necessary to purge your log file after
each update process, it is highly recommended that you do so as often
as possible.<br>
<br>
<b>New records</b> are records in your log file that were successfully
used to build/update the statistics database.<br>
<br>
Note: A log analysis process might be slow (one second for each 4500
lines of your
logfile with an Athlon 1Ghz, plus DNS resolution time for each
different
IP
address in your logfile if <a href="awstats_config.html#DNSLookup">DNSLookup</a>
is set to 1 and not already done in your log file).&nbsp; See the <a
 href="awstats_benchmark.html">Benchmarks page</a> for more detailed
information.<br>
<br>
<!-- <span style="font-weight: bold;">Flush history </span>messages referer
to ...&nbsp; (Flush history on disk after 20000 hosts). Flush history
file on disk (unique url reach flush limit of 5000 -->

<br>
<font style="color: rgb(17, 17, 85);"><b>* Update from a browser</b>:</font><br>
<br>
AWStats statistics can also be updated from a browser, providing
real-time statistics, by clicking
the "Update now" link that appears when AWStats is used as a CGI (The
URL is described in the next
section '<a href="#READ">Run reports: Building and reading reports</a>').<br>
<br>
<b>Warning</b>!!<br>
To enable this link, the configuration file parameter <a
 href="awstats_config.html#AllowToUpdateStatsFromBrowser">AllowToUpdateStatsFromBrowser</a>
must be set to 1 (The link is not enabled by
default).<br>
Using the on-line update does not prevent you from running the update
process automatically on a scheduled basis (the command is same as that
of the first update process above).<br>
For this, you have two choices:<br>
- Include the update command in your <b>logrotate</b> process. See <a
 href="awstats_faq.html#ROTATE">FAQ-COM120</a> for details.<br>
- Or add instructions in your <b>crontab</b> (Unix/Linux) or your <b>task
scheduler</b> (Windows), to regularly launch the Awstats update
process. See <a href="awstats_faq.html#CRONTAB">FAQ-COM130</a> for
details.<br>
<br>
See the AWStats <a href="awstats_benchmark.html">Benchmarks page</a>
for
the recommended update/logrotate frequency.<br>
<br>

<br>
<a name="READ">
<h2 style=""><u>III. Run reports: Building and reading reports</u></h2>
</a><br>
To see the analysis results, you have several options depending on your
<a href="awstats_security.html">security policy</a>.<br>
<br>
Note: you must have created a statistics data base for the analysis
period by processing your
log files before you try to create reports.&nbsp; See the previous
section.<br>
<br>
1. The first option is to build the main reports, in a static HTML
page,
from the command line,
using the following syntax (skip to the second option if you only have
CGI access):<br>
<br>
<table border=1 cellpadding=1 cellspacing=0 bgcolor=#F4F4F4 width="95%" class=CFAQ><tr class=CFAQ><td class=CFAQ>
perl awstats.pl -config=mysite -output -staticlinks
&gt; awstats.mysite.html
</td></tr></table>
<br>
where <span style="font-style: italic;">mysite</span> must
be substituted with the domain/virtual host name you selected earlier
during AWStats configuration.<br>
<br>
To create specific individual reports, specify the report name on the
command
line as follows&sup1;:<br>
<table border=1 cellpadding=1 cellspacing=0 bgcolor=#F4F4F4 width="95%" class=CFAQ><tr class=CFAQ><td class=CFAQ>
perl awstats.pl -config=mysite -output=alldomains
-staticlinks &gt; awstats.mysite.alldomains.html<br>
perl awstats.pl -config=mysite -output=allhosts
-staticlinks &gt; awstats.mysite.allhosts.html<br>
perl awstats.pl -config=mysite -output=lasthosts
-staticlinks &gt; awstats.mysite.lasthosts.html<br>
perl awstats.pl -config=mysite -output=unknownip
-staticlinks &gt; awstats.mysite.unknownip.html<br>
perl awstats.pl -config=mysite -output=alllogins
-staticlinks &gt; awstats.mysite.alllogins.html<br>
perl awstats.pl -config=mysite -output=lastlogins
-staticlinks &gt; awstats.mysite.lastlogins.html<br>
perl awstats.pl -config=mysite -output=allrobots
-staticlinks &gt; awstats.mysite.allrobots.html<br>
perl awstats.pl -config=mysite -output=lastrobots
-staticlinks &gt; awstats.mysite.lastrobots.html<br>
perl awstats.pl -config=mysite -output=urldetail
-staticlinks &gt; awstats.mysite.urldetail.html<br>
perl awstats.pl -config=mysite -output=urlentry
-staticlinks &gt; awstats.mysite.urlentry.html<br>
perl awstats.pl -config=mysite -output=urlexit
-staticlinks &gt; awstats.mysite.urlexit.html<br>
perl awstats.pl -config=mysite -output=browserdetail
-staticlinks &gt; awstats.mysite.browserdetail.html<br>
perl awstats.pl -config=mysite -output=osdetail
-staticlinks &gt; awstats.mysite.osdetail.html<br>
perl awstats.pl -config=mysite -output=unknownbrowser
-staticlinks &gt; awstats.mysite.unknownbrowser.html<br>
perl awstats.pl -config=mysite -output=unknownos
-staticlinks &gt; awstats.mysite.unknownos.html<br>
perl awstats.pl -config=mysite -output=refererse
-staticlinks &gt; awstats.mysite.refererse.html<br>
perl awstats.pl -config=mysite -output=refererpages
-staticlinks &gt; awstats.mysite.refererpages.html<br>
perl awstats.pl -config=mysite -output=keyphrases
-staticlinks &gt; awstats.mysite.keyphrases.html<br>
perl awstats.pl -config=mysite -output=keywords
-staticlinks &gt; awstats.mysite.keywords.html<br>
perl awstats.pl -config=mysite -output=errors404
-staticlinks &gt; awstats.mysite.errors404.html<br>
</td></tr></table>
<br>
&sup1;If you prefer, you can use the <a
 href="awstats_tools.html#awstats_buildstaticpages">awstats_buildstaticpages</a>
tool to
build all these pages in one command, or to generate PDF files.<br>
<br>
Notes:<br>
<br>
a) You can also add a <i>filter</i> on the following reports: <b>urldetail,
urlentry, urlexit, allhosts, refererpages</b>.&nbsp; The <i>filter</i>
can be a regexp (regular expression) on the full key you want AWStats
to report on and is appended to the output
parameter separated by a ":".<br>
<br>
For example, to output the urldetail report, including only pages which
contain /news in their URL, you
can use the following command line:<br>
<table border=1 cellpadding=1 cellspacing=0 bgcolor=#F4F4F4 width="95%" class=CFAQ><tr class=CFAQ><td class=CFAQ>
perl awstats.pl -config=mysite -output=urldetail:</b>/news<b>
-staticlinks &gt; awstats.mysite.urldetailwithfilter.html</b>
</td></tr></table>
<br>
b) If you want to build a report for a particular month, add
the options <i><b>-month=MM -year=YYYY</b></i> where MM is the month
expressed as two digits, i.e. 03, and year is the four digit
year.&nbsp; To build a
report for a full year, add the options <i><b>-month=all -year=YYYY</b></i>
(warning: this is often resource intensive and might use a lot of
memory
and CPU.&nbsp; Unix/Linux like operating systems might benefit from use
of the "nice" command.)<br>
<br>
<br>
2) The second option is to dynamically view your statistics from a
browser.&nbsp; To do this, use the URL:<br>
<table border=1 cellpadding=1 cellspacing=0 bgcolor=#F4F4F4 width="95%" class=CFAQ><tr class=CFAQ><td class=CFAQ>
http://www.myserver.mydomain/awstats/awstats.pl?config=mysite
</td></tr></table>
<br>
where <i>mysite</i> specifies the configuration
file to
use (AWStats will use the file awstats.<i>mysite</i>.conf).<br>
<br>
All output command line options (except -staticlinks and -logfile) are
also available when using AWStats with a browser. Just use them as URL
parameters: change "-option" to
"&amp;option", i.e.&nbsp; <b><i>http://www.myserver.mydomain/awstats/awstats.pl?month=MM&amp;year=YYYY&amp;output=unknownos</i></b><br>
<br>
Reports are generated in real time from the statistics data
base.&nbsp; If this is slow, or putting too much load on your server,
consider generating static reports instead.<br>
<br>
If the <a href="awstats_config.html#AllowToUpdateStatsFromBrowser">AllowToUpdateStatsFromBrowser</a>
parameter is set to 1 in AWStats configuration file,
you will also be able to run the update process from your browser. Just
click on the link "Update now".<br>
<br>
<br>
<hr>

<!-- You can remove this part if you distribution need documentation without external tags -->
<!-- BEGIN_SOCIAL_NETWORKS -->
<div class="htmldoc-ignore">
<!-- google plus -->
<span style="color: #bbb; font-weight: normal;">Article written by <a href="https://www.destailleur.fr/awstats.php?category=awstats?rel=author" rel="author" style="color: #ccc; font-weight: normal;">Laurent Destailleur</a>.</span><br>
<br>
<!-- twitter -->
<a href="https://twitter.com/awstats_project" class="twitter-follow-button" data-show-count="false">Follow @awstats_project</a>
</div>
<!-- END_SOCIAL_NETWORKS -->

</body>
</html>