Awstats config problem

Discussion in 'HOWTO-Related Questions' started by Paladinemishakal, Feb 12, 2009.

  1. Paladinemishakal

    Paladinemishakal New Member

    Hi All,

    I am having some problem with configuring awstats on Debian sarge and Apache2. I have multiple vhosts configured in Apache2 and I have also install awstats to enable log statistics for each site. Due to a request by a user, I have to enable basic authentication for one of the awstats config.

    Location of awstats.pl : /var/www/awstats/cgi-bin
    Location of awstats apache config : /etc/apache2/sites-enabled/awstats

    I put this config into the apache config for awstats:
    ScriptAlias /cgi-bin/ /srv/www/awstats/cgi-bin/
    <Directory "/srv/www/awstats/cgi-bin">
    #AllowOverride None
    AllowOverride AuthConfig
    Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
    Order allow,deny
    Allow from all
    </Directory>

    I created .htaccess and .htpasswd in /var/www/awstats/cgi-bin
    --------Content of .htpasswd----------------------
    AuthUserFile /var/www/awstats/cgi-bin/.htpasswd
    AuthGroupFile /dev/null
    AuthName "XXX Awstats"
    AuthType Basic
    #require user stats
    Require valid-user
    ---------------------------------------------------

    Site A: http://awstats.xxx.com/awstats/awstats.pl?config=abc.com
    Site B: http://awstats.xxx.com/awstats/awstats.pl?config=def.com

    I have created a separate data directory for each awstats config:
    1. DirData="/var/www/awstats/cgi-bin/abc.com"
    2. DirData="/var/www/awstats/cgi-bin/def.com"

    When I access my awstats site for each config, I get a password prompt. What I want to do is to just setup Site A with a password prompt and not Site B. How can i do this?

    Thanks & Regards.
     
  2. falko

    falko Super Moderator

    I think you have to set up two separate vhosts for awstats.
     

Share This Page