Koozali.org: home of the SME Server
Obsolete Releases => SME 7.x Contribs => Topic started by: MasterSleepy on April 27, 2006, 08:32:18 AM
-
Hello everyone,
I've finished my last howto, it concerne the installation of sarg (http://sarg.sourceforge.net/) on sme server 7.
You can find it http://www.vanhees.cc/index.php?module=ContentExpress&func=display&ceid=41.
Regards.
-
Thanks for this great to see.
I am however having issues.
When I reboot my server I am getting the following error on screen and am unable to use the local web server.
Syntax Error on line 1690 of /etc/httpd/cpnf/httpd.conf:
Invalid Command'_______',Perhaps mis-spelled or defined by module not included in the server configuration
I can confirm that line 1690 is the start of the entry for sarg and that if I remove the custom template and reconfigure/reboot the server the error disapears.
I have double checked the template fragment and cannot see anything.
Any ideas.
Thanks
Tony
-
Managed to sort this.
This is my copy of the 90e-smithAccess20sarg custom template
{
my $externalSSLAccess = '';
my $validFrom = db_get_prop($confref, "httpd-admin", "ValidFrom") || 'none';
$validFrom =~ s/,/ /g;
$validFrom =~ s:/255.255.255.255::g;
unless ($validFrom eq 'none')
{
$externalSSLAccess = $validFrom;
}
$OUT .= <<HERE;
#-----------------------------------------------------------------------------
# SARG generated squid access log reports web repository
#
#-----------------------------------------------------------------------------
Alias /squid /var/www/sarg
<Directory /var/www/sarg>
Options +Includes
AllowOverride None
order deny,allow
deny from all
allow from $localAccess $externalSSLAccess
AuthName "e-smith manager"
AuthType Basic
AuthExternal pwauth
require user admin
</Directory>
#-----------------------------------------------------------------------------
# End of SARG generated squid access log reports web repository
#
#-----------------------------------------------------------------------------
HERE
}
The problem was the # at the start and end of the sarg generated squid access log reports.
Thanks again
Tony
-
I can confirm with you Tony that exactly what I had to do too is add the # to the...
#-----------------------------------------------------------------------------
# SARG generated squid access log reports web repository
#
#-----------------------------------------------------------------------------
Start & end.
Mastersleepy many thanks for this great contrib that I've used for many years!! have a :pint: on me
-
Great thanks.
I've made a too fast copy-paste.
I've correct the howto now.
:pint: byte
:pint: ajkeane
-
Just installed and works fine thankyou.
Small details you might like to change in the howto -
when you try and edit /etc/e-smith/web/functions/sarg the file did not initially exist, need to pico /etc/e-smith/web/functions/sarg
At the end
/sbin/e-smith/signal-event post-upgrade
/sbin/e-smith/signal-event reboot
to get rid of Unknown in the server-manager.
Many thanks for updating this contrib. Not having it has been one reason I have not gone to sme 7 :)
Regards
Brian Kirk
-
Howto has been modified.
:pint: briank
-
Just re-reading this and this line...
#
-----------------------------------------------------------------------------
# End of SARG generated squid access log reports web repository
#
-----------------------------------------------------------------------------
needs to be...
#-----------------------------------------------------------------------------
# End of SARG generated squid access log reports web repository
#
#-----------------------------------------------------------------------------
Otherwise httpd will complain about incorrect usage.
Mastersleepy will you be doing this an RPM for this? if not I may look into this, the only thing with that code is it's not done in FormMagick, but still it works and that's great...Thanks again
-
Now it's corrected.
Effectively, rpm should be a good idea.
I'll take a look at that this week-end.
Thanks for feedback.
-
Hello all,
Following the byte's idea, thanks to him :pint: , I build rpm for sarg installation.
Howto have been modified.
http://www.vanhees.cc/index.php?module=ContentExpress&func=display&ceid=41
Regards.
-
I have noticed that every saturday night I get no records for the day and that the weekly stats fail as well stating no records found.
Is anyone else having this issue?
Tony
-
I have noticed that every saturday night I get no records for the day and that the weekly stats fail as well stating no records found.
Is anyone else having this issue?
Tony
Hi,
I've installed Sarg a few days ago, and I've just noticed the same problem:
- no Saturday report
- no Weekly report
this email was sent to the admin:
/etc/cron.weekly/sarg:
SARG: No records found
SARG: End
-
I have also installed dansguardian as per the how to here: http://mirror.contribs.org/smeserver/contribs/rmitchell/smeserver/howto/dansguardian%20instal%20&%20configure%20HOWTO%20for%20sme%20server.htm
I have configured the proxy to use port 8080 with the following code:
db configuration setprop squid TransparentPort 8080
signal-event post-upgrade
signal-event reboot
However now all internet usage is listed under localhost. Is there a way to correct this?
Thanks.
Tony
-
Hello all,
for weekly report, i found the solution this week-end, I apply the solution for monthly report but I forget to a apply it to daily :-x
So I will correct it this evening.
There is a new version
http://www.vanhees.cc/index.php?name=CmodsDownload&file=index&req=viewsdownload&orderby=dateD
but not the final.
Regards.
-
Thanks for the update.
However when I try o install I get the following error:
rpm -Uvh smeserver-sarg-1.0-2.noarch.rpm
Preparing... ########################################### [100%]
file /etc/cron.monthly/sarg from install of smeserver-sarg-1.0-2 conflicts with file from package sarg-1.4.1-5.2.el4.rf
file /etc/cron.weekly/sarg from install of smeserver-sarg-1.0-2 conflicts with file from package sarg-1.4.1-5.2.el4.rf
Thanks
Tony
-
HHhmmm that seems normal because I change that file.
Normally you can force installation but I prefer to build a new rpm this week.
I think that I'll integrate both rpm in one.
Regards
-
Thanks for that. I must admit that I decided against a force but agree that that should work.
I look forward to your new rpm and thank you for all the great work.
Tony
-
Thanks as well,
No hurry for me, I will wait the final RPM
-
Hy all,
Here the "final" rpm.
This rpm contains automatic installation of sarg in only one rpm
Here is the rpm
http://www.vanhees.cc/index.php?name=CmodsDownload&file=index&req=viewdownloaddetails&lid=289
Here is the source rpm
http://www.vanhees.cc/index.php?name=CmodsDownload&file=index&req=viewdownloaddetails&lid=290
Please remove every other rpm concerning sarg installation.
For the moment I didn't change the howto, I'll change it this week-end.
Regards.
-
Hi thanks for that.
I upgrade on the 13th and all seemed to go well untill the next morning when I checked the usage and find that there are no reports being generated overnight.
The scripts are all present in cron.daily weekly etc.
Is anyone else having these issues.
I uninstalled the previous version and then installed the new.
Thanks in advance for any insites into what i have done wrong.
Tony
-
Hi Guys,
We installed this package today running off the latest RPM. I have found what ajkeane has found where no data is being shown.
after closer inspection something has changed, the /etc/cron.daily/sarg file has some differences, /usr/sbin/sarg is incorrect as the file lives in /usr/bin this was the first error which stopped it from creating the pages.
Once the files were created they went to /var/www/squid/daily, except the URL on the webpanel is expecting it to be /var/www/sarg/daily.
This is also the case for /etc/cron.weekly & monthly.
Another interesting thing to note is ONE-SHOT doesn't work unless you run the sarg command from the /usr/bin.
I have now got working SARG reports, but i am a newbie and i might have missed a fundamental piece of info so don't flame me if I have missed something simple.
Cheers
ShaneO
-
Hello,
Great thanks, ShaneO & ajkeane, for that feedback.
I'll adapt the rpm today or tomorrow.
Regards.
-
Hello all,
The new version of rpm is available.
smeserver-sarg-1.4.1-2.i386.rpm
http://www.vanhees.cc/index.php?name=CmodsDownload&file=index&req=getit&lid=289
smeserver-sarg-1.4.1-2.src.rpm
http://www.vanhees.cc/index.php?name=CmodsDownload&file=index&req=getit&lid=290
Regards.
-
Hi
I installed this rpm on Friday but cannot get reports via Server Manager. The cron jobs are working and creating them in /var/www/sarg, but I get a message 'File not found /squid/daily/index.html' - and for weekly, monthly and onetime - when I try to access via Server Manager Sarg menu. There is an entry in httpd.conf setting an alias of /squid to /var/www/sarg.
Tim
-
Hello,
An another bug, :hammer:
Thanks timn.
The new version of rpm is available.
smeserver-sarg-1.4.1-3.i386.rpm
http://www.vanhees.cc/index.php?name=CmodsDownload&file=index&req=getit&lid=289
smeserver-sarg-1.4.1-3.src.rpm
http://www.vanhees.cc/index.php?name=CmodsDownload&file=index&req=getit&lid=290
Regards.
-
Hi
Can we please get this put into the main contribs section (http://no.longer.valid/phpwiki/index.php/SME7Contribs) ... I think a lot of ppl would use this ... and it will get lost here.
Regards,
Tib
-
Something is wrong, i get the normal sarg page but when i try to view a report i get this page:
Not Found
The requested URL /squid/ONE-SHOT/index.html was not found on this server.
-
Hello,
The "ONE-SHOT" section is only for manual launch.
So that message is normal except if you have launch it manually.
Regards.
-
I have the same error for the other reports like daily, weekly
-
Hello,
For daily report, you have to wait one day, so normally you should see result next morning.
For weekly, you can see result next monday morning.
For monthly, result are generated first of each month.
regards.
-
Yeah, now it works. Can you tell me how to translate de usernames to some more readable? now it lists the pc name
1 date/time pc-00183.promaen.local 350 101.988.095 71.93% 0.05% 99.95% 00:12:30 750.662 22.46%
2 date/time pc-02689.promaen.local 2.318 13.555.810 9.56% 4.23% 95.77% 00:08:58 538.342 16.11%
3 date/time pc-02610.promaen.local 1.990 13.025.772 9.19% 0.20% 99.80% 00:05:14 314.627 9.42%
-
It is a bit of a pain this way
The old Sarg on SME 6 shows the Ip address of the machine ... that is a slightly better way I would think as it is easier to find out what machine it is.
The PC name can be found here ... /var/lib/dhcp/dhcpd.leases
But I wouldn't know how to intergrate that into anything as I know nothing about scripting etc.
Maybe MasterSleepy can have a look and see if he can do anything with it.
Regards,
Tib
-
Hello,
I'll check for ip problem.
Regards.
-
G'day all,
I've installed the latest SARG rpm on a fresh 7.0 SME server/gateway machine but am only getting Monday to Saturday reports. The machine has been running for 2 months now.
Any ideas where I can look for what may be stopping the Sunday/Weekly/Monthly reports from being generated.
Everything looks good to me (cron jobs look correct), so not really sure where the problem lies.
-
Hello,
You are right, saterday statistic are missing.
I will check for that as soon.
Regards.
-
I'm having some troubles too with the sarg contrib. I only get the montlhly reports. The others (one-shot, daily, weekly) give me an " /squid/daily/index.html was not found " type of error. I tried launching the cron jobs manually but to no avail.
This is on a fresh install of SME Server v7.0, running for a couple of days now.
-
Hello all,
I've made a new RPm that should solved the problem
RPM:
http://www.vanhees.cc/modules.php?op=modload&name=CmodsDownload&file=index&req=viewdownloaddetails&lid=289&ttitle=smeserver-sarg-1.4.1-4.i386.rpm
Source RPM:
http://www.vanhees.cc/modules.php?op=modload&name=CmodsDownload&file=index&req=viewdownloaddetails&lid=290&ttitle=smeserver-sarg-1.4.1-4.src.rpm
This new rpm include also report by name and by ip.
Regards.
-
Thanks MasterSleepy, I've installed the new rpms and everything seems to work ok.
However I had to disable squid for the moment, cause one of the users had some problems accessing a specific site. Can squid be setup so a machine bypasses the transparent proxy? Or does the setting must be done on that machine?
-
First of all, thanks alot MasterSleepy for your tireless work on Sarg for SME.
I have installed your contrib, and it's been working great for about a month, now however Im getting "Segmentation fault" errors when the cron.daily/sarg runs.
I've googled and found this http://mikhail.greenway.ru/sarg/ have you come across this fault before?
Thank you
Alfred
-
Hello,
Try running lastest version.
You could find it at http://www.dungog.net/
Regards.
-
Hello,
Try running lastest version.
You could find it at http://www.dungog.net/
Regards.
MasterSleepy, I noticed Stephen had sarg as well, what are the differences between your version and Dungog?
Thanks!
-
Hello,
Dungog version use two rpm, the first one is i386 sarg compiled.
The last one is bundle of script for smeserver 7.
Advantage of this solution is that it use binary build for rhel.
Regards.
-
Dungog version use two rpm, the first one is i386 sarg compiled.
The last one is bundle of script for smeserver 7.
Advantage of this solution is that it use binary build for rhel.
Ok - Thanks, so in future anyone looking to install sarg should use the dungog version as it is built with the rhel version on which the SME Server is based.
-
fyi
sarg-2.2.1-1.el4.rf.i386.rpm
is lifted from dag, so you could d/l directly from there
(MasterSleepy is welcome to keep control of releases
Michael may not want to split the rpm)
there are two smeserver-sarg rpms
for 1.x wich is bundled with the binary
and for 2.x which is seperated
2.x uses a different method in the cron*/sarg files
which is irrelevant to users
but both this and the old method will fail when bug 1990 is fixed
http://bugs.contribs.org/show_bug.cgi?id=1990
ie the log filename will not match the long format
-
This hasn't been easy I tell you :shock:
I started presenting these bugs long ago and no one seemed to think it was SME related.
Today I'm using the latest version of sargs and also Dansguardian, so since I pointed sargs to the Dansguardian directory, I no longer care about the files on /var/log/squid. I then made a script to clean this directory:
#/bin/bash
for i in /var/log/squid/*; do
> "$i";
done
which I run every 48hrs (high traffic here at school)
This brought me another problem, since I use the Web interface provided by Dungog.net to manage Dans, it does not restart Dans or squid by itself:
svc -d /service/squid
svc -d /service/dansguardian
svc -u /service/squid
svc -u /service/dansguardian
I hope this helps someone in case they need a 'hack' to get things going...
-
>svc -u /service/dansguardian
smeserver-dansguardian isn't a requirement for dansguardian but be aware that smeserver-dansguardian-2.9 doesn't use svc anymore
use dansguardian -q
dansguardian
-
Thanks for the tip Steven,
Maybe you should update your package then as these commands are still being posted when 'save/reload all' gets hit.
-
Granted - I don't check the SARG reports very often....
Since Dec 8 2006 - all I get for users is localhost - before that I got listings by pc - so I could tell who went where from which pc.
There must have been an update around that timeframe which broke the sarg reporting.
any suggestions appreciated.
BTW - system is running 7.1.2 - now at least. With Dansguardian from Dungog.