[ Top | Up | Prev | Next |
Map | Index ]
Quick reference
This section is list of all of analog's configuration commands, together with a
quick reference to their syntax and some examples. It's designed for those who
are already familiar with the program, so it's pretty useless for trying to
learn the program: to learn about the commands, read the section on
Customising analog instead, or consult
the index for a reference. I would
welcome feedback on this new section.
This section is divided into the following parts:
The syntax for each command is given using the following notation.
"stuff" the word stuff
x y x followed by y
(x | y) x or y
[x] optional x
subset("...") any letters from the string, in any order
perm("...") all the letters from the string, in any order
*x x may contain wildcards * and ? (and often comma-separated list)
x := y x is defined to be y
COMMAND the command under discussion
In addition, I use the following names for different types of argument.
char a single character
string a string
digit a digit
number a non-negative integer (i.e. a string of digits)
real a non-negative real number
regexp a POSIX extended regular expression
file a filename within your server's filespace;
e.g. /index.html
localfile a filename within your system's filespace;
e.g. /usr/local/analog.html
localfmtfile as localfile, but may contain date codes;
e.g. /usr/local/analog%y%M.html
referrer a URL of a referring page;
e.g. http://search.yahoo.com/
URL a URL which may be absolute, or relative to the output page;
e.g. images/ or /~fred/images/
or http://www.fred.com/images/
Note: I have occasionally opted for clarity above strict accuracy where I
don't think it will cause any confusion!
The syntax for commands in general was given
earlier: remember that an argument which contains a
hash or a space must be put in quotes or parentheses.
- Syntax
-
LOGFILE (*localfile | "-" | "none") [prefix_string]
OUTFILE (localfmtfile | "-" | "none")
CACHEFILE (*localfile | "-" | "none")
CACHEOUTFILE (localfmtfile | "-" | "none")
UNCOMPRESS *localfile program
- Examples
-
LOGFILE /httpd/logs/*
LOGFILE c:\logs\log1,c:\logs\log2
OUTFILE "Hard Disk:Report%Y%M.html"
UNCOMPRESS *.gz "/usr/bin/gzip -cd"
- Syntax
format_string := (see documentation)
Apache_format_string := (see Apache documentation)
logformat := ("COMMON" | "COMBINED" | "REFERRER" | "BROWSER" | "EXTENDED" |
"MICROSOFT-NA" | "MICROSOFT-INT" | "WEBSITE-NA" | "WEBSITE-INT" |
"MS-EXTENDED" | "MS-COMMON" | "NETSCAPE" | "WEBSTAR" | "AUTO" |
format_string)
LOGFORMAT logformat
DEFAULTLOGFORMAT logformat
APACHELOGFORMAT Apache_format_string
APACHEDEFAULTLOGFORMAT Apache_format_string
- Notes
- LOGFORMAT and APACHELOGFORMAT only affect logfiles
occurring later in the same configuration file.
- Examples
-
LOGFORMAT (%S - %u [%d/%M/%Y:%h:%n:%j %j] "%j %r %j" %c %b)
DEFAULTLOGFORMAT MS-EXTENDED
APACHELOGFORMAT (%h %l %u %t \"%r\" %s %b)
- 1. Commands (items)
-
FILEALIAS,
HOSTALIAS,
BROWALIAS,
REFALIAS,
USERALIAS,
VHOSTALIAS
- Syntax
-
COMMAND *olditem newitem
COMMAND ("REGEXP:" | "REGEXPI:")regexp newitem
- Notes
- Aliases item in all reports. Items with the same resultant name are
combined. newitem may contain $1, $2
etc., representing the *'s in olditem or the
bracketed subexpressions in regexp. Regular expressions are only
available on some platforms.
- Examples
- FILEALIAS /*/football/* /$1/soccer/$2
- USERALIAS REGEXP:^([^U].*) U$1
- 2. Commands (reports)
-
TYPEOUTPUTALIAS,
HOSTOUTPUTALIAS,
REQOUTPUTALIAS,
REDIROUTPUTALIAS,
FAILOUTPUTALIAS,
DIROUTPUTALIAS,
DOMOUTPUTALIAS,
ORGOUTPUTALIAS,
REFOUTPUTALIAS,
REFSITEOUTPUTALIAS,
REDIRREFOUTPUTALIAS,
FAILREFOUTPUTALIAS,
BROWOUTPUTALIAS,
FULLBROWOUTPUTALIAS,
OSOUTPUTALIAS,
VHOSTOUTPUTALIAS,
USEROUTPUTALIAS,
FAILUSEROUTPUTALIAS
- Syntax
-
COMMAND *item string
COMMAND ("REGEXP:" | "REGEXPI:")regexp string
- Notes
- Aliases item on one line of one report only. string may contain
$1, $2 etc., representing the *'s in
item or the bracketed subexpressions in
regexp. Regular expressions are only available on some
platforms.
- Examples
- REQOUTPUTALIAS /football/ "/football/ (Main football page)"
- REFOUTPUTALIAS REGEXP:^(http://([^/]*\.)?(maths|stats)\.uxy\.edu.*) ([$3] $1)
- 3. Other commands: syntax
-
CASE ("SENSITIVE" | "INSENSITIVE")
USERCASE ("SENSITIVE" | "INSENSITIVE")
SEARCHCHARCONVERT ("ON" | "OFF")
DIRSUFFIX suffix
LOGTIMEOFFSET ["+" | "-"] number
TIMEOFFSET ["+" | "-"] number
- Examples
-
CASE SENSITIVE
DIRSUFFIX index.htm
LOGTIMEOFFSET -300
- 1. Commands (items)
-
FILEINCLUDE,
FILEEXCLUDE,
HOSTINCLUDE,
HOSTEXCLUDE,
BROWINCLUDE,
BROWEXCLUDE,
REFINCLUDE,
REFEXCLUDE,
USERINCLUDE,
USEREXCLUDE,
VHOSTINCLUDE,
VHOSTEXCLUDE
- Syntax
-
COMMAND (*item | "")
COMMAND ("REGEXP:" | "REGEXPI:")regexp
- Notes
- Excludes all logfile entries containing an excluded item from all reports.
Includes and excludes are done after aliases, so the item is the
aliased name, if applicable. Regular expressions are only available on some
platforms.
- Examples
-
FILEINCLUDE /jim/*
FILEINCLUDE REGEXP:^/~[^/]*/$
HOSTEXCLUDE proxy*.aol.com
USEREXCLUDE ""
- 2. Syntax (including and excluding dates)
-
partdate := ["+" | "-"] digit digit
date := partdate partdate partdate [":" partdate partdate]
FROM date
TO date
- Examples
-
FROM 990719:1200
TO -00-0101
- 3. Commands (reports)
-
REQINCLUDE,
REQEXCLUDE,
REDIRINCLUDE,
REDIREXCLUDE,
FAILINCLUDE,
FAILEXCLUDE,
TYPEINCLUDE,
TYPEEXCLUDE,
DIRINCLUDE,
DIREXCLUDE,
HOSTREPINCLUDE,
HOSTREPEXCLUDE,
DOMINCLUDE,
DOMEXCLUDE,
ORGINCLUDE,
ORGEXCLUDE,
REFREPINCLUDE,
REFREPEXCLUDE,
REFSITEINCLUDE,
REFSITEEXCLUDE,
SEARCHQUERYINCLUDE,
SEARCHQUERYEXCLUDE,
SEARCHWORDINCLUDE,
SEARCHWORDEXCLUDE,
REDIRREFINCLUDE,
REDIRREFEXCLUDE,
FAILREFINCLUDE,
FAILREFEXCLUDE,
BROWSUMINCLUDE,
BROWSUMEXCLUDE,
FULLBROWINCLUDE,
FULLBROWEXCLUDE,
OSINCLUDE,
OSEXCLUDE,
VHOSTREPINCLUDE,
VHOSTREPEXCLUDE,
USERREPINCLUDE,
USERREPEXCLUDE,
FAILUSERINCLUDE,
FAILUSEREXCLUDE
- Syntax
-
COMMAND *item
COMMAND ("REGEXP:" | "REGEXPI:")regexp
- Notes
- Excludes an excluded item from one report only. Regular expressions are
only available on some platforms.
- Example
- REQINCLUDE pages
- 4. Syntax (miscellaneous)
-
PAGEINCLUDE *file
PAGEEXCLUDE *file
ARGSINCLUDE *file
ARGSEXCLUDE *file
REFARGSINCLUDE *referrer
REFARGSEXCLUDE *referrer
- Notes
- These can be regular expressions too, on suitable platforms.
- Example
-
PAGEINCLUDE *.asp
- Syntax
-
DNSFILE localfile
DNS ("NONE" | "READ" | "LOOKUP" | "WRITE")
DNSLOCKFILE localfile
DNSGOODHOURS number
DNSBADHOURS number
- Examples
-
DNSFILE dnscache.txt
DNS WRITE
DNSBADHOURS 48
- Syntax
-
SUBDIR *file
SUBDOMAIN *subdomain
SUBORG *subdomain
SUBTYPE *extension
SUBBROW *browser
REFDIR *referrer
- Examples
-
SUBDIR /jim/*/*
SUBTYPE *.gz
- Commands
- FILELOWMEM,
HOSTLOWMEM,
BROWLOWMEM,
REFLOWMEM,
USERLOWMEM,
VHOSTLOWMEM
- Syntax
-
COMMAND ("0" | "1" | "2" | "3")
- Example
-
HOSTLOWMEM 3
- Commands
- GENERAL,
ALL,
MONTHLY,
WEEKLY,
FULLDAILY,
DAILY,
FULLHOURLY,
HOURLY,
QUARTER,
FIVE,
HOST,
ORGANISATION,
DOMAIN,
REQUEST,
DIRECTORY,
FILETYPE,
SIZE,
PROCTIME,
REDIR,
FAILURE,
REFERRER,
REFSITE,
SEARCHQUERY,
SEARCHWORD,
REDIRREF,
FAILREF,
FULLBROWSER,
BROWSER,
OSREP,
VHOST,
USER,
FAILUSER,
STATUS
- Syntax
-
REPORTCOMMAND ("ON" | "OFF")
- Examples
-
ALL OFF
FULLHOURLY ON
- Commands
- ALLGRAPH,
MONTHGRAPH,
WEEKGRAPH,
DAYGRAPH,
FULLDAYGRAPH,
HOURGRAPH,
FULLHOURGRAPH,
QUARTERGRAPH,
FIVEGRAPH
- Syntax
-
COMMAND ("R" | "r" | "P" | "p" | "B" | "b")
- Example
-
ALLGRAPH B
- Commands
- ALLBACK,
MONTHBACK,
WEEKBACK,
FULLDAYBACK,
FULLHOURBACK,
QUARTERBACK,
FIVEBACK
- Syntax
-
COMMAND ("ON" | "OFF")
- Example
-
ALLBACK ON
- Commands
- MONTHROWS,
WEEKROWS,
FULLDAYROWS,
FULLHOURROWS,
QUARTERROWS,
FIVEROWS
- Syntax
-
COMMAND number
- Example
-
QUARTERROWS 192
- 1. Commands (time reports)
-
TIMECOLS,
MONTHCOLS,
WEEKCOLS,
DAYCOLS,
FULLDAYCOLS,
HOURCOLS,
FULLHOURCOLS,
QUARTERCOLS,
FIVECOLS
- Syntax
- cols1 := subset("RrPpBb")
COMMAND cols1
- Example
-
MONTHCOLS bRP
- 2. Commands (most success reports)
-
HOSTCOLS,
ORGCOLS,
DOMCOLS,
DIRCOLS,
REFCOLS,
REFSITECOLS,
SEARCHQUERYCOLS,
SEARCHWORDCOLS,
FULLBROWCOLS,
BROWCOLS,
OSCOLS,
VHOSTCOLS,
USERCOLS
- Syntax
- cols2 := subset("NDdRrPpBb")
COMMAND cols2
- Example
-
USERCOLS BD
- 3. Commands (Request and File Type Reports)
-
REQCOLS,
TYPECOLS
- Syntax
- cols3 := subset("NDdRrpBb")
COMMAND cols3
- Example
-
TYPECOLS NRb
- 4. Commands (failure, redirection and Status Code reports)
-
REDIRCOLS,
FAILCOLS,
REDIRREFCOLS,
FAILREFCOLS,
FAILUSERCOLS,
STATUSCOLS
- Syntax
- cols4 := subset("NDdRr")
COMMAND cols4
- Example
-
FAILCOLS D
- 5. Commands (Size and Processing Time Reports)
-
SIZECOLS,
PROCTIMECOLS
- Syntax
- cols5 := subset("DdRrPpBb")
COMMAND cols5
- Example
-
SIZECOLS RB
- 1. Commands (most success reports)
-
HOSTSORTBY,
ORGSORTBY,
DOMSORTBY,
DIRSORTBY,
REFSORTBY,
REFSITESORTBY,
SEARCHQUERYSORTBY,
SEARCHWORDSORTBY,
FULLBROWSORTBY,
BROWSORTBY,
OSSORTBY,
VHOSTSORTBY,
USERSORTBY,
SUBDIRSORTBY,
SUBDOMSORTBY,
SUBORGSORTBY,
SUBBROWSORTBY,
SUBOSSORTBY,
REFDIRSORTBY,
REFARGSSORTBY
- Syntax
- sortby1 := ("REQUESTS" | "PAGES" | "BYTES" | "DATE" | "ALPHABETICAL" | "RANDOM")
COMMAND sortby1
- Example
-
DOMSORTBY ALPHABETICAL
- 2. Commands (Request and File Type Reports)
-
REQSORTBY,
TYPESORTBY,
REQARGSSORTBY,
SUBTYPESORTBY
- Syntax
- sortby2 := ("REQUESTS" | "BYTES" | "DATE" | "ALPHABETICAL" | "RANDOM")
COMMAND sortby2
- Example
-
REQSORTBY REQUESTS
- 3. Commands (failure, redirection and Status Code reports)
-
REDIRSORTBY,
FAILSORTBY,
REDIRREFSORTBY,
FAILREFSORTBY,
FAILUSERSORTBY,
STATUSSORTBY,
REDIRARGSSORTBY,
FAILARGSSORTBY,
REDIRREFARGSSORTBY,
FAILREFARGSSORTBY
- Syntax
- sortby3 := ("REQUESTS" | "DATE" | "ALPHABETICAL" | "RANDOM")
COMMAND sortby3
- Example
-
FAILSORTBY DATE
- Commands (top-level)
-
HOSTFLOOR,
ORGFLOOR,
DOMFLOOR,
REQFLOOR,
DIRFLOOR,
TYPEFLOOR,
REDIRFLOOR,
FAILFLOOR,
REFFLOOR,
REFSITEFLOOR,
SEARCHQUERYFLOOR,
SEARCHWORDFLOOR,
REDIRREFFLOOR,
FAILREFFLOOR,
FULLBROWFLOOR,
BROWFLOOR,
OSFLOOR,
VHOSTFLOOR,
USERFLOOR,
FAILUSERFLOOR,
STATUSFLOOR
- Commands (lower levels)
-
REQARGSFLOOR,
REDIRARGSFLOOR,
FAILARGSFLOOR,
REFARGSFLOOR,
REDIRREFARGSFLOOR,
FAILREFARGSFLOOR,
SUBDIRFLOOR,
SUBDOMFLOOR,
SUBORGFLOOR,
SUBTYPEFLOOR,
SUBBROWFLOOR,
SUBOSFLOOR,
REFDIRFLOOR
- Syntax
-
partdate := ["+" | "-"] digit digit
date := partdate partdate partdate [":" partdate partdate]
COMMAND number ("r" | "p")
COMMAND number ["k" | "M" | "G" | "T"] "b"
COMMAND real ("%" | ":") ("r" | "p" | "b")
COMMAND date "d"
COMMAND "-" number ("r" | "p" | "b" | "d")
- Notes
- Actually, this syntax isn't quite correct. REQFLOOR,
TYPEFLOOR, REQARGSFLOOR and SUBTYPEFLOOR
aren't allowed to be of type "p"; and REDIRFLOOR,
FAILFLOOR, REDIRREFFLOOR, FAILREFFLOOR,
FAILUSERFLOOR, STATUSFLOOR, REDIRARGSFLOOR,
FAILARGSFLOOR, REDIRREFARGSFLOOR and
FAILREFARGSFLOOR aren't allowed to be of types "p" or
"b".
- Examples
-
TYPEFLOOR -20r
REQARGSFLOOR 0.1%b
- Syntax
-
LINKINCLUDE *file
LINKEXCLUDE *file
REFLINKINCLUDE *referrer
REFLINKEXCLUDE *referrer
BASEURL prefix_string
- Examples
-
LINKINCLUDE pages
REFLINKINCLUDE *.cgi
BASEURL http://www.mycompany.com
- Syntax
LANGUAGE ("ARMENIAN" | "BOSNIAN" | "CATALAN" | "SIMP-CHINESE" |
"TRAD-CHINESE" | "CZECH" | "DANISH" | "DUTCH" | "ENGLISH" |
"US-ENGLISH" | "FINNISH" | "FRENCH" | "GERMAN" | "GREEK" |
"ICELANDIC" | "ITALIAN" | "JAPANESE" | "NORWEGIAN" | "NYNORSK" |
"POLISH" | "PORTUGUESE" | "BR-PORTUGUESE" | "RUSSIAN" | "SERBIAN" |
"SLOVAK" | "SLOVENE" | "SPANISH" | "SWEDISH" | "TURKISH" |
"UKRAINIAN")
LANGFILE localfile
DOMAINSFILE localfile
- Notes
- Other languages were available in
version 3 of analog,
and should be available for version 4 soon.
- Examples
-
LANGUAGE ITALIAN
LANGFILE lang/hindi.lng
- Syntax
-
OUTPUT ("HTML" | "ASCII" | "COMPUTER" | "NONE")
GOTOS ("ON" | "OFF" | "FEW")
RUNTIME ("ON" | "OFF")
LASTSEVEN ("ON" | "OFF")
REPORTORDER perm("xmWDdHh45uJoZSvitzcPrEIfsNnkKbBp")
IMAGEDIR URL
NOROBOTS ("ON" | "OFF")
LOGO (URL | "none")
HOSTNAME string
HOSTURL (URL | "none")
HEADERFILE (localfile | "none")
FOOTERFILE (localfile | "none")
STYLESHEET (URL | "none")
SEPCHAR (char | "none")
REPSEPCHAR (char | "none")
DECPOINT char
COMPSEP string
RAWBYTES ("ON" | "OFF")
HTMLPAGEWIDTH number
ASCIIPAGEWIDTH number
BARSTYLE ("a" | "b" | "c" | "d" | "e" | "f" | "g" | "h")
MARKCHAR char
MINGRAPHWIDTH number
WEEKBEGINSON ("SUNDAY" | "MONDAY" | "TUESDAY" | "WEDNESDAY" | "THURSDAY" | "FRIDAY" | "SATURDAY")
SEARCHENGINE *referrer comma-separated-strings
- Examples
- Too many to list. See the documentation on each individual command.
- Syntax
-
SETTINGS ("ON" | "OFF")
DEBUG ("ON" | "OFF" | ["+" | "-"] subset("CDFSU"))
WARNINGS ("ON" | "OFF" | ["+" | "-"] subset("CDEFLMR"))
PROGRESSFREQ number
ERRFILE localfile
ERRLINELENGTH number
- Examples
-
DEBUG ON
DEBUG CF
WARNINGS -DL
PROGRESSFREQ 50000
Stephen Turner
Need help with analog? Subscribe to the analog-help
mailing list
[ Top | Up | Prev | Next |
Map | Index ]