LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 10-20-2009, 01:52 AM   #1
carabina5
LQ Newbie
 
Registered: Oct 2009
Posts: 1

Rep: Reputation: 0
Angry sarg reports problem


Hi to all,
I have installed an Ubuntu server with squid proxy, squidGuard and sarg.
I'm trying to generate automatically the sarg's Daily reports, but I didn't find it in my system.
I try whit webadmin, then I try to configure the contab, but without results.
I try to do manually the commands "sarg-reports daily", with root users, and all I get is "no records found". But, if I use "sarg-reports today", there are not problem.
I can see and read the access.log file, and, if I generate manually all reports with webmin, I don't have problems.

I can't understand what is the problem...
Can anyone help me, please?


P.S. I'm using a new server in my laboratory, with the same configuration files and all works without problems...
 
Old 10-22-2009, 12:41 AM   #2
cjshaw
LQ Newbie
 
Registered: Oct 2009
Location: Harare
Distribution: Ubuntu 9.04
Posts: 1

Rep: Reputation: 0
I experienced the same problem. To my understanding, the report was running after the logfile has been rotated. To sort it, add the following to your cron (crontab -e).

PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
00 08-18/1 * * * sarg-reports today
00 00 * * * sarg-reports daily
00 01 * * 1 sarg-reports weekly
30 02 1 * * sarg-reports monthly

This will run the today report hourly between 8am and 6pm, so your daily report is always up to date.It also runs the daily at midnight etc.

Next, edit your squid logrotate file (vim /etc/logrotate.d/squid) and change daily to monthly. This will then only rotate the logfile monthly and the logfile will contain the data for the reports to run.
 
  


Reply

Tags
reports, sarg


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
SARG is not generating reports. Phiggy Linux - Server 1 08-17-2009 08:45 AM
Sarg-reports jonette20 Linux - General 5 08-07-2009 02:20 PM
Squid Logs Reports with SARG kendrick Linux - Software 0 03-31-2008 08:51 AM
SARG not generating scheduled reports from Squid symesd Linux - Software 0 11-01-2007 04:52 PM
Sarg reports question (with Webmin) rickyinman Linux - Software 0 04-14-2006 08:01 AM


All times are GMT -5. The time now is 09:34 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration