View Full Version : Statistic not working
mzo
18th February 2006, 06:50
Hi Guys
I'm having problem with my web statistic. After see your previous solution in the thread i type :
#grep -i cron /var/log/messages
and the output as below :
Feb 18 12:01:01 server crond(pam_unix)[5084]: session opened for user root by (uid=0)
Feb 18 12:01:02 server crond(pam_unix)[5084]: session closed for user root
[root@server log]#
Any idea on how to solve this problem? Your help is very needed. Tq.
falko
18th February 2006, 12:39
Maybe this thread helpy you: http://www.howtoforge.com/forums/showthread.php?t=562
mzo
21st February 2006, 14:54
Maybe this thread helpy you: http://www.howtoforge.com/forums/showthread.php?t=562
MZO : I already read the thread but after 24 hr still can't work. I can see some errors in /var/log/messages when I run grep -i cron /var/log/messages that is :
Feb 21 00:01:01 server crond(pam_unix)[9837]: session opened for user root by (uid=0)
Feb 21 00:01:01 server crond(pam_unix)[9837]: session closed for user root
Feb 21 00:30:01 server crond(pam_unix)[10419]: session opened for user root by (uid=0)
Feb 21 00:30:01 server crond(pam_unix)[10419]: session closed for user root
Feb 21 00:40:01 server crond(pam_unix)[10629]: session opened for user root by (uid=0)
Feb 21 00:40:01 server crond(pam_unix)[10629]: session closed for user root
Feb 21 01:01:01 server crond(pam_unix)[11140]: session opened for user root by (uid=0)
Feb 21 01:01:01 server crond(pam_unix)[11140]: session closed for user root
Feb 21 02:01:01 server crond(pam_unix)[12343]: session opened for user root by (uid=0)
Feb 21 02:01:01 server crond(pam_unix)[12343]: session closed for user root
Feb 21 02:05:01 server crond(pam_unix)[12425]: session opened for user root by (uid=0)
Feb 21 02:05:02 server crond(pam_unix)[12425]: session closed for user root
Feb 21 03:01:01 server crond(pam_unix)[14439]: session opened for user root by (uid=0)
Feb 21 03:01:01 server crond(pam_unix)[14439]: session closed for user root
Feb 21 03:15:01 server crond(pam_unix)[15241]: session opened for user root by (uid=0)
Feb 21 03:15:02 server crond(pam_unix)[15241]: session closed for user root
Feb 21 04:00:01 server crond(pam_unix)[17829]: session opened for user root by (uid=0)
Feb 21 04:00:01 server crond(pam_unix)[17829]: session closed for user root
Feb 21 04:01:01 server crond(pam_unix)[17953]: session opened for user root by (uid=0)
Feb 21 04:01:01 server crond(pam_unix)[17953]: session closed for user root
Feb 21 04:02:01 server crond(pam_unix)[18011]: session opened for user root by (uid=0)
Feb 21 04:02:18 server crond(pam_unix)[18011]: session closed for user root
Feb 21 05:01:01 server crond(pam_unix)[19785]: session opened for user root by (uid=0)
Feb 21 05:01:01 server crond(pam_unix)[19785]: session closed for user root
Feb 21 06:01:01 server crond(pam_unix)[20985]: session opened for user root by (uid=0)
Feb 21 06:01:01 server crond(pam_unix)[20985]: session closed for user root
Feb 21 07:01:01 server crond(pam_unix)[22188]: session opened for user root by (uid=0)
Feb 21 07:01:01 server crond(pam_unix)[22188]: session closed for user root
Feb 21 08:01:01 server crond(pam_unix)[23389]: session opened for user root by (uid=0)
Feb 21 08:01:01 server crond(pam_unix)[23389]: session closed for user root
Feb 21 09:01:01 server crond(pam_unix)[24592]: session opened for user root by (uid=0)
Feb 21 09:01:01 server crond(pam_unix)[24592]: session closed for user root
Feb 21 10:01:01 server crond(pam_unix)[25794]: session opened for user root by (uid=0)
Feb 21 10:01:01 server crond(pam_unix)[25794]: session closed for user root
Feb 21 11:01:01 server crond(pam_unix)[26998]: session opened for user root by (uid=0)
Feb 21 11:01:01 server crond(pam_unix)[26998]: session closed for user root
Feb 21 12:01:01 server crond(pam_unix)[28201]: session opened for user root by (uid=0)
Feb 21 12:01:01 server crond(pam_unix)[28201]: session closed for user root
Feb 21 13:01:01 server crond(pam_unix)[29403]: session opened for user root by (uid=0)
Feb 21 13:01:01 server crond(pam_unix)[29403]: session closed for user root
Feb 21 14:01:01 server crond(pam_unix)[30606]: session opened for user root by (uid=0)
Feb 21 14:01:01 server crond(pam_unix)[30606]: session closed for user root
Feb 21 15:01:01 server crond(pam_unix)[31829]: session opened for user root by (uid=0)
Feb 21 15:01:01 server crond(pam_unix)[31829]: session closed for user root
Feb 21 15:15:01 server crond(pam_unix)[32111]: session opened for user root by (uid=0)
Feb 21 15:15:01 server crond(pam_unix)[32111]: session closed for user root
Feb 21 16:01:01 server crond(pam_unix)[573]: session opened for user root by (uid=0)
Feb 21 16:01:01 server crond(pam_unix)[573]: session closed for user root
Feb 21 17:01:01 server crond(pam_unix)[1790]: session opened for user root by (uid=0)
Feb 21 17:01:01 server crond(pam_unix)[1790]: session closed for user root
Feb 21 18:01:01 server crond(pam_unix)[3063]: session opened for user root by (uid=0)
Feb 21 18:01:01 server crond(pam_unix)[3063]: session closed for user root
Feb 21 19:01:01 server crond(pam_unix)[4354]: session opened for user root by (uid=0)
Feb 21 19:01:01 server crond(pam_unix)[4354]: session closed for user root
Feb 21 20:01:01 server crond(pam_unix)[5803]: session opened for user root by (uid=0)
Feb 21 20:01:01 server crond(pam_unix)[5803]: session closed for user root
I can't find any syslog files in /var/log. I'm using Fedora Core 4. Please advise.Tq.
falko
21st February 2006, 18:48
These messages are unrelated to the statistics.
Please run
/root/ispconfig/php/php /root/ispconfig/scripts/shell/logs.php
/root/ispconfig/php/php /root/ispconfig/scripts/shell/webalizer.php
on the shell. Do you get errors?
mzo
22nd February 2006, 03:25
These messages are unrelated to the statistics.
Please run
/root/ispconfig/php/php /root/ispconfig/scripts/shell/logs.php
MZO : I get error, that is :
[root@server ~]# /root/ispconfig/php/php /root/ispconfig/scripts/shell/logs.php
Warning: readlink(): Invalid argument in /root/ispconfig/scripts/shell/logs.php
on line 125
/root/ispconfig/php/php /root/ispconfig/scripts/shell/webalizer.php
on the shell. Do you get errors?
[root@server ~]# /root/ispconfig/php/php /root/ispconfig/scripts/shell/logs.php
Warning: readlink(): Invalid argument in /root/ispconfig/scripts/shell/logs.php on line 125
[root@server ~]# /root/ispconfig/php/php /root/ispconfig/scripts/shell/webalizer.php
113 records (113 ignored) in 0.00 seconds
till
22nd February 2006, 09:41
[root@server ~]# /root/ispconfig/php/php /root/ispconfig/scripts/shell/logs.php
Warning: readlink(): Invalid argument in /root/ispconfig/scripts/shell/logs.php on line 125
[root@server ~]# /root/ispconfig/php/php /root/ispconfig/scripts/shell/webalizer.php
113 records (113 ignored) in 0.00 seconds
This looks fine so far. Have the statistics been generated now?
mzo
22nd February 2006, 10:21
This looks fine so far. Have the statistics been generated now?
MZO : Nope. That why I still wonder what has been wrong. FYI, first I'm using domain a.a.a and it works but later I need to change it to b.b.b and then only it start fail to work. Is there any setting I need to change?tq.
-mzo-
falko
22nd February 2006, 11:07
What's your ISPConfig web root? /home/www or /var/www or something else?
mzo
23rd February 2006, 05:39
What's your ISPConfig web root? /home/www or /var/www or something else?
MZO : It in /home/www/web3
falko
23rd February 2006, 08:25
Please post the output of ls -la /home/www
mzo
23rd February 2006, 10:58
Please post the output of ls -la /home/www
MZO : Hi Falko. Below is the output.
[root@server ~]# ls -la /home/www
total 36
drwxr-xr-x 8 root root 4096 Feb 9 18:55 .
drwxr-xr-x 6 root root 4096 Feb 9 21:56 ..
drwxr-xr-x 3 root root 4096 Jan 18 00:30 localhost
drwxr-xr-x 3 root root 4096 Jan 18 00:30 server.puspakom.com
drwxr-xr-x 3 root root 4096 Feb 9 00:30 server.puspakom.net.ms
drwxr-xr-x 10 apache web1 4096 Feb 9 19:12 web1
drwxr-xr-x 11 apache web1 4096 Feb 6 21:55 web2
drwxr-xr-x 12 mz_o web3 4096 Feb 23 11:43 web3
lrwxrwxrwx 1 root root 14 Jan 17 14:41 www.puspakom.it.tt -> /home/www/web1
lrwxrwxrwx 1 root root 14 Feb 3 10:44 www.puspakom.net.ms -> /home/www/web2
lrwxrwxrwx 1 root root 14 Feb 9 18:55 www.puspakom.strangled.net -> /home/www/web3
[root@server ~]#
MZO : I only using www.puspakom.strangled.net. Is there a way on how to remove domain other than www.puspakom.strangled.net ?
falko
23rd February 2006, 18:02
I think your readlink() errors come from the directories localhost, server.puspakom.com and server.puspakom.com.ms because they weren't created by ISPConfig.
MZO : I only using www.puspakom.strangled.net. Is there a way on how to remove domain other than www.puspakom.strangled.net ?How do you mean that?
mzo
24th February 2006, 05:02
I think your readlink() errors come from the directories localhost, server.puspakom.com and server.puspakom.com.ms because they weren't created by ISPConfig.
How do you mean that?
MZO : My really domain is www.puspakom.strangled.net not www.puspakom.net.ms and www.puspakom.it.tt. So how I want to remove www.puspakom.net.ms and www.puspakom.it.tt ? Tq.
falko
24th February 2006, 13:12
MZO : My really domain is www.puspakom.strangled.net not www.puspakom.net.ms and www.puspakom.it.tt. So how I want to remove www.puspakom.net.ms and www.puspakom.it.tt ? Tq.
Is www.puspakom.strangled.net a Co-Domain of www.puspakom.net.ms or www.puspakom.it.tt? In that case you won't find it as a symlink in /home/www.
esezako
21st February 2011, 15:32
I have the same issue.
Various websites don't generate statistics from many days ago.
Any idea or solution?
Thanks
till
21st February 2011, 15:33
Which ISPConfiog 2 version do you use? Do you use webalizer or awstats?
esezako
21st February 2011, 17:37
Version: 2.2.35
I use webalizer.
till
21st February 2011, 17:50
Please post the output of:
ps aux | grep webalizer
esezako
21st February 2011, 17:55
# ps aux | grep webalizer
root 16567 0.0 0.0 3256 680 pts/1 S+ 16:53 0:00 grep webalizer
esezako
22nd February 2011, 10:36
any more ideas please?
till
22nd February 2011, 10:51
Take a look into the access log file which is inside the log folder of a website where stats do not work. Does it contain log lines for yesterday?
esezako
22nd February 2011, 11:02
yes, contain lines of yesterday.
till
22nd February 2011, 11:25
Try to delete the webalizer.current and webalizer.hist file which are in the webalizer folder of the website. Then run:
/root/ispconfig/php/php /root/ispconfig/scripts/shell/webalizer.php
to recreate the statistics.
esezako
22nd February 2011, 11:31
Try this and put the result here. Thanks
esezako
22nd February 2011, 11:53
No statics create. The files webalizer.current webalizer.history not reconstructed. Why?
till
22nd February 2011, 12:03
Did you got any errors on the shell while the script was run (except of the truncated line messages)?
esezako
22nd February 2011, 12:13
Maybe this warning
Warning: Cutting source link field too large
esezako
22nd February 2011, 13:52
Why not processed various websites?
esezako
22nd February 2011, 14:07
For any reason various websites not execute the webalizer.
If execute manually the webalizer work perfectly:
webalizer -n www.mydomain.info -s www.mydomain.info -r www.mydomain.info -q -T -o /home/www/www.mydomain.info/web/webalizer -c /root/ispconfig/scripts/shell/webalizer.conf /home/www/www.mydomain.info/log/web.log
Why webalizer.php exclude various websites?
esezako
22nd February 2011, 18:52
Maybe a data corrupt in database ?
falko
23rd February 2011, 15:20
so my stats dont work.
i updated the stats password via ispconfig 3 control panel:
the login is set at 'admin' and i used the correct password i set there also.
in the monitor module i get this for the ispconfig cron log
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found
sh: repquota: command not found ...
when i go to domain.com/stats
and log in, i get a ERROR 403 - Forbidden!
root@***:~# webalizer
Webalizer V2.01-10 (Linux 2.6.32.16-linode28) locale: C
Using logfile /var/log/apache2/access.log.1 (clf)
Using default GeoIP database
Error Opening file /usr/share/GeoIP/GeoIP.dat
there is a .htaccess file in the web directory, but thats it.
Please post this in the ISPConfig 3 forum!
esezako
23rd February 2011, 15:23
Hi Falko, any idea for my problem?
anubix
23rd February 2011, 18:53
sorry falko i now reposted in the correct forum, thanks.
esezako
24th February 2011, 10:33
Dont know what else I can do. Can anyone help?
falko
24th February 2011, 16:07
For any reason various websites not execute the webalizer.
If execute manually the webalizer work perfectly:
webalizer -n www.mydomain.info -s www.mydomain.info -r www.mydomain.info -q -T -o /home/www/www.mydomain.info/web/webalizer -c /root/ispconfig/scripts/shell/webalizer.conf /home/www/www.mydomain.info/log/web.log
Why webalizer.php exclude various websites?So it works if you run it manually? Stats are created then?
Do you see any error messages when you run it manually?
esezako
24th February 2011, 17:42
So it works if you run it manually? Stats are created then?
yes
Do you see any error messages when you run it manually?
No errors
falko
25th February 2011, 14:48
What's the output of crontab -l?
esezako
25th February 2011, 14:55
30 00 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/logs.php &> /dev/null
59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/ftp_logs.php &> /dev/null
59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/mail_logs.php &> /dev/null
59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/cleanup.php &> /dev/null
0 4 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/webalizer.php &> /dev/null
0,30 * * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/check_services.php &> /dev/null
15 3,15 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/quota_msg.php &> /dev/null
40 00 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/traffic.php &> /dev/null
05 02 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/backup.php &> /dev/null
30 3 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/awstats.php &> /dev/null
esezako
25th February 2011, 20:12
30 00 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/logs.php &> /dev/null
59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/ftp_logs.php &> /dev/null
59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/mail_logs.php &> /dev/null
59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/cleanup.php &> /dev/null
0 4 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/webalizer.php &> /dev/null
0,30 * * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/check_services.php &> /dev/null
15 3,15 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/quota_msg.php &> /dev/null
40 00 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/traffic.php &> /dev/null
05 02 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/backup.php &> /dev/null
30 3 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/awstats.php &> /dev/null
falko
26th February 2011, 15:04
Looks ok. My guess is that for some reason, cron uses a wrong PATH and therefore cannot find webalizer.
Can you add this as the first line to your crontab (by running crontab -e)?
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
esezako
28th February 2011, 11:31
But, why some sites processed correctly the stats and other no?
esezako
1st March 2011, 15:09
Looks ok. My guess is that for some reason, cron uses a wrong PATH and therefore cannot find webalizer.
Can you add this as the first line to your crontab (by running
Code:
crontab -e
)?
Code:
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
The problem is not solved :(
falko
1st March 2011, 17:03
Do the sites where it doesn't work have an access log in the logs directory? Maybe noone visited the sites; in this case there's no access log to process.
esezako
1st March 2011, 17:47
Do the sites where it doesn't work have an access log in the logs directory? Maybe noone visited the sites; in this case there's no access log to process.
Like I say before, yes.
All logs correct, but various websites suddenly stoped of create stats. ¿?
esezako
1st March 2011, 20:17
Think i find the problem. I have enormous log files or my sites (Many big sites make with Drupal CMS). I think the problem is a php time limit to execute the webalizer.php script.
I change this limit but, how can i reduce the filesize of logs in ispconfig?
esezako
2nd March 2011, 10:57
How can i recalculate all stats of a particular month?
anubix
8th March 2011, 19:16
esezako!!!!!!!!!!!
You are 'da man'
it works now after adding
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
to the first line of the cron tab.
but i have 1 question, isnt there a better place to add the path?
anubix
8th March 2011, 19:38
it seems that the stats dont work for all of my sites.
is this because i need to visit the site from different ip addresses if there are no visits yet?
(the files are not created in the stats folder)
anubix
8th March 2011, 20:43
i got the 2nd site working , perhaps by visiting the site from a few different ip addresses
esezako
20th April 2011, 13:19
I have issues with big log filesizes (1,5Gb, 500Mb, etc).
How can i rotate web.log?
vBulletin® v3.8.7, Copyright ©2000-2012, vBulletin Solutions, Inc.