Bug #6083
openSuqid Realtime Monitor / Squid Cache Table not diplaying correctly
0%
Description
On the GUID under Package / Squid / Monitor the realtime tab have all the squid / squidguard logs displayed. The log for "Squid Cache Table" shows the information wrong.
I could find the source of the problem. The file /usr/local/www/squid_monitor_data.php has a line that reads:
// Split line by delimiter
$logline = preg_split("@\|
@",$logent);
Apparently that pattern is not correct for that log file. On my system, a line from that log file looks like this:
"2016-04-06 16:22:56 [65440] loading dbfile /var/db/squidGuard/Black_Listed/domains.db"
That should split each line separating the date form the message, but since that fails, the displayed info is wrong.
I changed the pattern (I'm DO NOT really know how to do it properly) to ""/\[+/"" and now the array split almost correctly.
[0] 2016-04-06 16:22:56
[1] 65440] loading dbfile /var/db/squidGuard/Black_Listed/domains.db
I don't know how to split it correctly tough.
Updated by Andres Arenas over 8 years ago
O, I tried a new pattern : "/\[|]+/" .. This split the line in 3. Using [0] and [2] fixed the display of the message.
Updated by Chris Buechler over 8 years ago
- Project changed from pfSense to pfSense Packages
- Category changed from Web Interface to Squid
- Affected Version changed from 2.3 to 2.3.x
Updated by Kill Bill about 8 years ago
I have no idea why's Squidguard logging something into Squid cache log. This is not a bug in Squid package, and given the readability of code in Squidguard, I highly doubt anyone will ever fix this.