AWStats Plugin for DA [version 3.0+]

I get:

Error: Couldn't open config file "awstats.temp.****.nl.conf" nor "awstats.conf" after searching in path ".,/etc/awstats,/usr/local/etc/awstats,/etc,/etc/opt/awstats": No such file or directory

- Did you use the correct URL ?
Example: http://localhost/awstats/awstats.pl?config=mysite
Example: http://127.0.0.1/cgi-bin/awstats.pl?config=mysite
- Did you create your config file 'awstats.temp.*****.conf' ?
If not, you can run "awstats_configure.pl" from command line, or create it manually.

Check config file, permissions and AWStats documentation (in 'docs' directory).

I just installed it on one of the domain. But getting that error.
 
Hey

firstly id like to say it works great however i'm having a bit of trouble with this part:

Code:
3) Setup to automatically add access for new accounts created in DA:

nano -w /usr/local/directadmin/scripts/custom/user_create_post.sh

insert the following:

#!/bin/sh
echo $username >> /usr/local/directadmin/plugins/awstats/hooks/permissions.txt

I assume this is done via ssh however on the first step it says command not found, am i doing something wrong here? i'm using Fedora Core 5

any help is appreciated
 
It just means that you don't have nano installed. use whatever text editor you like. I use vi personally.

So if I was to do the same thing I'd do something like this

Code:
3) Setup to automatically add access for new accounts created in DA:

vi /usr/local/directadmin/scripts/custom/user_create_post.sh

insert the following:

#!/bin/sh
echo $username >> /usr/local/directadmin/plugins/awstats/hooks/permissions.txt

BUT! I don't suggest you have your first adventure with vi on a live file.

But if you want to try.

Open the file in vi as described above.
Press i to insert the text.
Then enter the text above.
Then hit esc to exit insert mode.
Then Shift-ZZ to save and close the file.
 
Last edited:
Posted in old forum thread, sorry, this one is related to 3.02

Hello,

I have installed awstats before without any problem on FC5, CentOS 4.4, but on a Debian 3.1 installation I can't find what goes wrong.

I'm looking for someone that can help me out:
- Debian 3.1
2.6.8-4-686-smp
- DirectAdmin 1.29.7
- DA plugin: 3.02
- Apache 1.3.37 with suexec enabled (doesn't work with suexec disabled)
Compiled-in modules:
http_core.c
mod_so.c
mod_frontpage.c
suexec: enabled; valid wrapper /usr/sbin/suexec

suexec -V output:
-D DOC_ROOT="/"
-D GID_MIN=100
-D HTTPD_USER="apache"
-D LOG_EXEC="/var/log/httpd/suexec_log"
-D SAFE_PATH="/usr/local/bin:/usr/bin:/bin"
-D UID_MIN=100
-D USERDIR_SUFFIX="public_html"
- Perl: This is perl, v5.8.4 built for i386-linux-thread-multi

I can run the awstats.pl from command line and generate an output and that works just fine. When I try to access /awstats/awstats.pl on http request via browser, I get the known Internal Server Error, please...

With suexec enabled: I can find this in the error_log (apache)
fopen: Permission denied
[Sat Jun 30 15:49:36 2007] [error] [client 84.193.51.252] Premature end of script headers: /home/b02/domains/domain.be/public_html/awstats/awstats.pl
and: /var/log/httpd/suexec_log
[2007-06-30 15:49:36]: info: (target/actual) uid: (b02/b02) gid: (b02/b02) cmd: awstats.pl

With suexec disabled: httpd error_log
[Sat Jun 30 15:43:38 2007] [error] (2)No such file or directory: exec of /home/b02/domains/domain.be/public_html/awstats/awstats.pl failed
[Sat Jun 30 15:43:38 2007] [error] [client 84.193.51.252] Premature end of script headers: /home/b02/domains/domain.be/public_html/awstats/awstats.pl
and nothing shows in de suexec_log (cause disabled)

config files: /etc/awstats/
-rw-r--r-- 1 b02 b02 54277 2007-06-28 13:31 awstats.domain.be.conf

The plugin (don't know if the script uses it or not):
server:/usr/local/directadmin/plugins/awstats/hooks/cgi-bin#
-rwxr-xr-x 1 root root 547776 2007-06-28 13:17 awstats.pl

I've tried chmod the /etc/awstats dir to my username, but didn't help much. Tried also copying all files (without symlinking them) to the public_html/awstats dir, with correct user and group (chown).

Does anyone know how I can solve my Internel Server Error? Or where can I find other config files, files to check permission, etc. to solve it or someone else needs to know what's causing this error?

I know the thread is long and read it completely, lot of people are asking same things about the Permission story, but can't find a solution for this.

Hope someone can help me out, TIA,
Fossie
 
Update on this issue:

I can (as root) execute the awstats.pl and generate an output. But when I try, (didn't test that before) to run as regular user (on command line): perl awstats.pl -config=domain.be -update
I recieve an error that the script can't read log file:

Create/Update database for config "/etc/awstats/awstats.domain.be.conf" by AWStats version 6.6 (build 1.887)
From data in log file "/var/log/httpd/domains/domain.be.log"...
Error: Couldn't open server log file "/var/log/httpd/domains/domain.be.log" : Permission denied
Setup ('/etc/awstats/awstats.domain.be.conf' file, web server or permissions) may be wrong.
Check config file, permissions and AWStats documentation (in 'docs' directory).

Permissions on these files:

-rw-r--r-- 1 b02 b02 54277 2007-07-01 20:53 /etc/awstats/awstats.domain.be.conf

-rw-r--r-- 1 root root 14793 2007-07-02 03:47 /var/log/httpd/domains/domain.be.log

In brief, I can run the awstats as root, but not as a user!

Maybe this helps to find a solution, because it's not related to apache, just permissions issue.

Debian 3.1, DA 1.29.7

Hope someone now can help me (and the others facing this issue).

TIA,
Fossie
 
Awstats 2.1.9 (6.5)

Guys,

I need awstats 2.1.9 (AWSTATS) file, which i can upload from DA on PLUGINS. I tried 3.0 but i dont like it. I am using on my server 2.1.9 works fine so i want also install on my another server.

CAN SOME SEND THE FILE (tar or zip)?

Thanks..
 
Great script and the install is very easy!

It looks like that everything is fine behalve this error:

Warning: fopen(/home/arcadepack/domains/arcadepacks.com/public_html/awstats/.htpasswd): failed to open stream: Permission denied in /usr/local/directadmin/plugins/awstats/user/index.html on line 140 Warning: fwrite(): supplied argument is not a valid stream resource in /usr/local/directadmin/plugins/awstats/user/index.html on line 141 Warning: fclose(): supplied argument is not a valid stream resource in /usr/local/directadmin/plugins/awstats/user/index.html on line 142 Warning: chown(): Operation not permitted in /usr/local/directadmin/plugins/awstats/user/index.html on line 144

I get this error after activating the stats in a hosting account (I guess that why the batch script doesn't work) How can I solve this?

Thanks
 
just noticed that the bach script "alldomains.php" doesn't work on my server. If I remove the awstats directory from the user and create it via DA (user level) everything is fine!
 
Great script and the install is very easy!

It looks like that everything is fine behalve this error:



I get this error after activating the stats in a hosting account (I guess that why the batch script doesn't work) How can I solve this?

Thanks


Check your php.ini file. Looks like you have the FOPEN functionality disabled.
 
Check your php.ini file. Looks like you have the FOPEN functionality disabled.

no thats not the case, while running the alldomains.php script some files doesn't getting the right permissions (there was some errors while execution of the batch)

if I didn't use that batch script everything is fine.

thanks!


btw. the permission problem is very common I saw the same error on some reseller hosting I use
 
Great work! Just installed this and works like a charm.

:D

CentOS 4.5/Apache 1.3/PHP5
 
Hi,

I install this plugin via DA admin cpanel and run update.sh
After install, i did not see "awstat statistic" under extra features section.

any ideas why?

i am on centOS 5 , DA
 
Last edited:
Hi,

I install this plugin via DA admin cpanel and run update.sh
After install, i did not see "awstat statistic" under extra features section.

any ideas why?

i am on centOS 5 , DA


Looks like either a bug in the lastest release of DA or the skins. Just installed it on a new server here and same thing...as a matter of fact NONE of the plugins are showing up.
 
Create awstat folder while creating da user

Great plugin .
I would have a question: i there any way I can make it create the awstats folder while the DA user is being created? I would like my users automatically have their awstats installed, without clicking that button. Offcourse running that batch script would do it but it's hard especially if I create da accounts via API.
Thanks all
Claudiu
 
is there a quick fix for this? like some variable need to be add to DA skin in order get the link shown up?
 
Great plugin .
I would have a question: i there any way I can make it create the awstats folder while the DA user is being created? I would like my users automatically have their awstats installed, without clicking that button. Offcourse running that batch script would do it but it's hard especially if I create da accounts via API.
Thanks all
Claudiu

Might be able to do it using the /usr/local/directadmin/scripts/custom/user_create_post.sh script. I'll see if I can make it work this weekend.
 
sean,

have you found the cause of the problem on why awstats statistic 'did not show up' at extra feature after adding this plugin?
 
Back
Top