AwStats plugin for DA [Still in BETA]

Downloading latest version<BR>
--22:40:20-- http://awstats.sourceforge.net/files/awstats.tgz
=> `/usr/local/directadmin/plugins/awstats/update/awstats.tgz'
Resolving awstats.sourceforge.net... done.
Connecting to awstats.sourceforge.net[66.35.250.209]:80... connected.
HTTP request sent, awaiting response... 404 Not Found
22:40:21 ERROR 404: Not Found.
 
I fixed the script to work, just add the version # to VERSION..

#!/bin/sh
VERSION=6.5

echo "Downloading latest version<BR>"
wget http://awstats.sourceforge.net/files/awstats-$VERSION.tar.gz -O/usr/local/directadmin/plugins/awstats/update/awstats.tar.gz
echo "Extracting<BR>"
tar zxvf /usr/local/directadmin/plugins/awstats/update/awstats.tar.gz -C /usr/local/directadmin/plugins/awstats/update
echo "Extracted.. now Updating<BR>"
AWSTATS=`ls /usr/local/directadmin/plugins/awstats/update | grep "awstats-"`
cd /usr/local/directadmin/plugins/awstats/update/$AWSTATS
PATHAW=/usr/local/directadmin/plugins/awstats/update/$AWSTATS

cp -f $PATHAW/wwwroot/cgi-bin/awstats.pl /usr/local/directadmin/plugins/awstats/hooks/cgi-bin/awstats.pl
/usr/local/bin/php /usr/local/directadmin/plugins/awstats/update/patch.php

cp -Rf $PATHAW/wwwroot/cgi-bin/lib /usr/local/directadmin/plugins/awstats/hooks/cgi-bin/
cp -Rf $PATHAW/wwwroot/cgi-bin/lang /usr/local/directadmin/plugins/awstats/hooks/cgi-bin/
cp -Rf $PATHAW/wwwroot/icon /usr/local/directadmin/plugins/awstats/hooks/cgi-bin/
cp -Rf $PATHAW/wwwroot/cgi-bin/plugins /usr/local/directadmin/plugins/awstats/hooks/cgi-bin/
echo "Removing all temp. files<BR>"

cd ..
rm -Rf /usr/local/directadmin/plugins/awstats/update/awstats*

echo "Done.. updated to $AWSTATS<BR>"
 
Hi!

After update, i have the same error for view "full year"

Thanks!

DRKT
 
I have a problem with awstats.
when i visit my awstats page it is not uptodate. So i have to update the page ontop of the mainframe. If i skip a day the stats are gone for that day is this a bug?
 
When i try to install the plugin version 2.1.8 (latest)
It says during installation:

Plugin Installed! Checking for latest version
... Updating to 6.5
Downloading 6.5
Extracting
awstats-6.5/ awstats-6.5/docs/ awstats-6.5/docs/awstats.pdf Extracted.. now Updating
Warning: fopen(/usr/local/directadmin/plugins/awstats/hooks/cgi-bin/awstats.pl): failed to open stream: No such file or directory in /usr/local/directadmin/plugins/awstats/update/patch.php on line 3
ERROR can't open awstats.pl

How can i solve this error ? :-)
 
after taking a look at the tar it looks like he is missing the awstats.pl file...

i have a custom version of this (because my perl location isnt default)

and i think thats the problem...
 
Offcourse it's missing the awstats.pl.. Because on installation the awstats.pl is downloaded and all other files... I'll check into the updating script later. Strange that it isn't working as the script sullise has posted, is almost the same as my script:

/usr/local/directadmin/plugins/awstats/update/update.sh

Could all of you please run this script from commandline and output the fullcontent as attachment, pm, email or post. Looks like one command or several aren't working or my setup is different of yours.
 
im slow...

fusionictnl said:
Offcourse it's missing the awstats.pl.. Because on installation the awstats.pl is downloaded and all other files... I'll check into the updating script later. Strange that it isn't working as the script sullise has posted, is almost the same as my script:

/usr/local/directadmin/plugins/awstats/update/update.sh

Could all of you please run this script from commandline and output the fullcontent as attachment, pm, email or post. Looks like one command or several aren't working or my setup is different of yours.

im slow...
before i would just modify the files then install them...

I did the awstats install directly from you... and i got the "fopen" error as ircman had.

then i ran update.sh

(since i have a different perl location i edited the *.pl files as needed)

then ran /usr/local/directadmin/plugins/awstats/hooks/alldomains.php
(and if im understanding it right... it updateded all users)

I double checked my install and its showing version 6.5 now.

if their is a problem it would probably be at the end of install.sh to automaticly grab the files.
 
Last edited:
The installation has never fully worked for me but I have always been able to workaround it by fixing it in the shell, and since its free I didnt persue it as I could workaround it but since I had to install this on a server today here is what happened installing it.

From the DA screen after install.

awstats successfully downloaded
plugin.tar.gz extracted
install.sh has been run:

Plugin Installed! Checking for latest version
Problems while checking... ERROR 1

Running the update script to replace current awstats binaries
Done running script.. Please verify by checking the version numbers on the bottom of the generated pages!

Then without touching anything in the shell I tried to activate for a domain and got errors saying couldnt link the dirs and couldnt install awstats.pl because not available.

So I went in the shell to check the plugin dir and cgi-bin had no awstats.pl and didnt have the icons dir etc. So is incomplete, this is the exact same problem I had on previous occasions and this problem didnt always exist but did start from about 3 versions back.

cgi-bin # ls -l
total 68
-rwxr-xr-x 1 diradmin diradmin 69 Jan 9 13:33 .htaccess
-rwxr-xr-x 1 diradmin diradmin 5407 Jan 9 13:33 awredir.pl
-rwxr-xr-x 1 diradmin diradmin 54171 Jan 9 13:33 awstats.none.conf
-rwxr-xr-x 1 diradmin diradmin 5203 Jan 9 13:33 awstats_updateall.pl


and plugin.tar.gz size

-rwx------ 1 diradmin diradmin 34629 Jan 9 13:33 plugin.tar.gz

note how small it is

yet on a working server it is as below

392658 Aug 19 15:43 plugin.tar.gz

also cgi-bin on a working server

-rw-r--r-- 1 diradmin diradmin 69 Aug 18 23:18 .htaccess
-r-xr-xr-x 1 diradmin diradmin 5407 Aug 18 23:18 awredir.pl
-rwxr-xr-x 1 diradmin diradmin 54171 Aug 18 23:18 awstats.none.conf
-rwxr-xr-x 1 diradmin diradmin 527414 Aug 18 23:18 awstats.pl
-rwxr-xr-x 1 diradmin diradmin 5203 Aug 18 23:18 awstats_updateall.pl
drwxr-xr-x 9 diradmin diradmin 512 Aug 18 23:14 icon
drwxr-xr-x 5 diradmin diradmin 1536 Aug 18 23:18 lang
drwxr-xr-x 2 diradmin diradmin 512 Aug 18 23:18 lib
drwxr-xr-x 3 diradmin diradmin 512 Aug 18 23:18 plugins

So I went into the update dir which has these files.

update # ls
patch.php update.sh

ran update.sh which worked without errors.

and now all seems normal so back into DA again and retry to activate for a domain and it works.

So it clearly fails to run update.sh but I cannot explain why I am sorry.
 
milan said:
I have a problem with awstats.
when i visit my awstats page it is not uptodate. So i have to update the page ontop of the mainframe. If i skip a day the stats are gone for that day is this a bug?

no reply lets bump :confused:
 
Milan If you read the first post. You know what to do. (Setup the cron job has been answered on almost every page of this thread)

Chrysalis

Problems while checking... ERROR 1

This means it couldn't download the main awstats page using WGET:

"wget http://awstats.sourceforge.net -Oawstats.ver -q"

If you haven't got wget installed. I could implement a work-around if this is the problem.
 
Password Feature Issue on FireFox

Hi,

The password setting feature is cool.

But I realized that upon setting a password, when I tried to key in http://www.mydomain.com/awstats/ in the IE, the page will prompt a login. However, when I use firefox, and repeat the same url, firefox can enter the site without prompting the login, and goes straight to the awstats page.

Please advise. Thanks.
 
lugin(s) Updated

Details

awstats successfully downloaded
plugin.tar.gz extracted
update.sh has been run:

Plugin has been updated! Plugin Installed! Checking for latest version
... Updating to 6.5
Downloading 6.5
Extracting
Extracted.. now Updating
Patched..
Removing all temp. files
Updating all user files..
Done.. updated to

Running the update script to replace current awstats binaries
Done running script.. Please verify by checking the version numbers on the bottom of the generated pages!

Redhat Fedora Core 3
DirectAdmin 1.26.1
 
fusionictnl said:
Pascal

That's the correct output after install. Did it correctly update for you ?

As far as I can see through GUI, yes.

If I look at the stats I still see: Advanced Web Statistics 6.4 (build 1.814) - Created by awstats.

Is that hardcoded?

If I re-install on a domain I'll lose my stats and the text remains.
 
Last edited:
Reinstallment doesn't remove any files from: /etc/awstats where the real data files are stored with historical information (the stats).

could you run the following:

/usr/local/directadmin/plugins/awstats/hooks/awstatsinstall.php -af

And see if the version number changed. I Really want to narrow down these problems.
 
fusionictnl said:
Reinstallment doesn't remove any files from: /etc/awstats where the real data files are stored with historical information (the stats).

could you run the following:

/usr/local/directadmin/plugins/awstats/hooks/awstatsinstall.php -af

And see if the version number changed. I Really want to narrow down these problems.

Nope, nothing changed :(

BTW: Where do I see stats from 2005 :?
 
Back
Top