ERROR: Slooooow dooooown... this page load was delayed.


awstats - Perl-based log file analyzer ChangeLog

HOWTO


# awstats 6.4
# ===========
cd
test -f installed/awstats-6.4.tgz && mv installed/awstats-6.4.tgz .
test ! -f awstats-6.4.tgz &&
wget http://download.sf.net/awstats/awstats-6.4.tgz
cd /usr/local/src
find -type d -maxdepth 1 -name "awstats-*" -exec rm -r {} \;
tar xzvf ~/awstats-6.4.tgz
cd awstats-6.4
chown -R root.root .

# Create the directories that everything will be installed in to,
# fix permissions and ownership on files and directories:
for dir in apache apache2; do
test -d /usr/local/$dir &&
( cd /usr/local/$dir
   mkdir -p cgi-bin/awstats htdocs/images/awstats
   test -d cgi-bin/awstats/lang && rm -r cgi-bin/awstats/lang
   test -d cgi-bin/awstats/lib && rm -r cgi-bin/awstats/lib
   test -d cgi-bin/awstats/plugins && rm -r cgi-bin/awstats/plugins
   cp -a /usr/local/src/awstats-6.4/wwwroot/cgi-bin/* \
    /usr/local/$dir/cgi-bin/awstats
   cp -a /usr/local/src/awstats-6.4/wwwroot/icon/* \
    /usr/local/$dir/htdocs/images/awstats
   chown -R root:nobody cgi-bin/awstats htdocs/images/awstats
   find cgi-bin/awstats -type d -exec chmod 750 {} \;
   find cgi-bin/awstats -type f -exec chmod 640 {} \;
   chown root:root cgi-bin/awstats/awstats.model.conf
   chmod 600 cgi-bin/awstats/awstats.model.conf
   chmod 750 cgi-bin/awstats/awstats.pl
   chown -R root:root cgi-bin/awstats/plugins/example
   chmod 700 cgi-bin/awstats/plugins/example
   chmod 600 cgi-bin/awstats/plugins/example/example.pm
   find htdocs/images/awstats -type d -exec chmod 750 {} \;
   find htdocs/images/awstats -type f -exec chmod 440 {} \; )
done

cd
mkdir -p -m 0700 installed
rm -f installed/awstats-*.tgz
mv awstats-6.4.tgz installed/

# Make sure your Apache logs are set up to be the 'combined' type, not
# 'common'.  You should have something like this set in your httpd.conf:
# CustomLog /usr/local/apache/logs/access_log combined

# In /usr/local/apache/cgi-bin/awstats is awstats.model.conf  Copy that file
# to any virtual's name you want to monitor like awstats.foo.org.conf
# Open up that config file, modify it as necessary.  You'll need to set
# at least these (with example values):
#
# LogFile="/usr/local/apache/logs/access_log-foo.org"
# SiteDomain="foo.org"
# DirData="/usr/local/apache/cgi-bin/awstats/data/foo.org"
# DirCgi="/cgi-bin/awstats"
# DirIcons="/images/awstats"
# AllowAccessFromWebToFollowingIPAddresses="192.168.0.1-192.168.0.255"
# SaveDatabaseFilesWithPermissionsForEveryone=0

# Run awstats at the commandline at midnight before your logs are rotated.
# I run a small bash script like this out of root's crontab:
# #!/bin/sh
# /usr/local/apache/cgi-bin/awstats/awstats.pl -config=foo.org -update
# /usr/local/apache/cgi-bin/awstats/awstats.pl -config=foo2.net -update
# /usr/local/apache/cgi-bin/awstats/awstats.pl -config=foo3.com -update
# find /usr/local/apache/cgi-bin/awstats/data -type f -name "awstats*.txt" -exec chown root:nobody {} \;
# find /usr/local/apache/cgi-bin/awstats/data -type f -name "awstats*.txt" -exec chmod 640 {} \;

# When you view the stats, use a URL like this:
# http://localhost/cgi-bin/awstats/awstats.pl?config=foo.org

List of HOWTOs

Web page itself last updated: 2023-12-20 8:06pm (EST -0500)
HOWTO last updated: 2005-03-21 3:44pm
Copyright © 2001-2024 Jason Englander. All Rights reserved.
[HTML5]