Good morning dear friends of IpFire Community, for some time now, I have had a problem when consulting the IPFire reports, it is not generating the reports, I have already uninstalled and installed and nothing is resolved, what could it be? … it is worth mentioning that this happened without having updated the core, and updating also still has not been resolved.
This message gets shown when the directory storing the reports contains no reports.
First thing to check. Do you have Logging enabled on the Web Proxy WUI page. This is not enabled by default.
On the Web Proxy WUI page, the 4th section down is labelled Log settings and there is an entry called Log enabled: and the check box needs to be selected.
Is the problem occurring only with the today report or also with the daily and weekly etc reports?
If logging is selected then on the console command line run the following command to manually execute the today report. /usr/sbin/update-sarg-reports today
If this is successful you will get a message similar to the following:-
SARG: Records in file: 11691
SARG: Successful report generated on /var/log/sarg/today/21Jun2022-21Jun2022
If you get the following message:-
SARG: Records in file: 11687
SARG: No records found
SARG: End
This means that SARG found no data for todays date in the Squid Logs. If logging is enabled then check that you have got your browser(s) set up to use the IPFire Web Proxy. If not then there will be no data to get logged.
You can also manually execute the earlier command replacing today with daily or weekly to check if there is earlier data available in your logs.
This is indicating some problem with what is written in the Squid Log File that SARG was trying to parse.
The today option looks in a maximum of three of the log files so you should look through the following log files
access.log
access.log.1.gz
access.log.2.gz
which are in the following directory /var/log/squid/
Unfortunately the error output does not show which line caused the problem or what the parsing problem wasso all of the three logs need to be fully reviewed.
Looks like your squid log files contain errors.
Because of your posted messages I suppose they contain CR/LF sequences as line delimiters.
IPFire uses and expects LF as all Linux systems.
EDIT: Playing around with my access.log file shows, that sarg is not vulnerable to wrong line ends.
But a non-empty line containing spaces produces the error.
Hello! I have exactly the same problem.
Sometimes the daily report is not generated and i reciev 404 error.
When I request on ssh connect:
/usr/sbin/update-sarg-reports today
…
SARG: 4 consecutive errors found in the input log file -
How to overcome the problem?
to see if there are any errors in there or if there are any lines that only contain spaces and nothing else.
Unfortunately @alexrochagallo never came back with any information about the contents of those access.log files 3 years ago and nobody else seems to have suffered from the problem, although that depends on how many users use the Sarg addon.
If you find any lines only containing spaces then it would be good to see what the line before it looks like in case that has some linkage with the line with only spaces being created.