Koozali.org: home of the SME Server

[Announce] Latest version of mailstats now available in smecontribs repo

Offline brianr

  • *
  • 988
  • +2/-0
I have finally managed to get the mailstats contrib into an rpm and up to date.

It is now installable by:

yum install --enablerepo=smecontribs smeserver-mailstats

It is a merge of Charlie's efficiency (and other) changes, and my latest bug fixes.  Current version of the script is 0.6.20, the rpm is version 0.0.3-4

It also has few more options via db entries (see below) and also will save the data day by day into a MySQL db (if you set the relevant option).

Unfortunately I have not yet got round to writing any analysis code yet (I am thinking of a php web application), if anyone is interested in helping, please email me.

Here are summary of the db options:

#############################################################################
#
#  SMEServer DB usage
#  ------------------
#
#  mailstats / Status ("enabled"|"disabled")
#            / <column header> ("yes"|"no"|"auto") - enable, supress or only show if nonzero
#            / QpsmtpdCodes ("enabled"|"disabled")
#            / SARules ("enabled"|"disabled")
#            / JunkMailList  ("enabled"|"disabled")
#            / SARulePercentThreshold (0.5) - threshold of SArules percentage for report cutoff
#            / Email (admin) - email to send report
#            / SaveDataToMySQL  - save data to MySQL database (default is "no")
#            / DBHost - MySQL server hostname (default is "localhost").
#            / DBPort - MySQL server post (default is "3306")
#            / Interval - "day", "week", "fortnight", "month", "99999" - last is number of seconds
#            / Base - "Midnight", "Midday", "Now", "99" hour (0-23)
#
#############################################################################

Interval defaults to "day" and Base to "midnight".  Note that if you lengthen the interval of the report, it still shows hourly summaries!

You could arrange for multiple servers to log the data to the same MySQL server, although I have not tested this.

You'll need to create the mailstats db and the table structure, more info in the comments of the script (or from me).

All plaudits here please, all bugs to the bug tracker.


 
« Last Edit: April 07, 2008, 10:21:43 AM by brianr »
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline gippsweb

  • ****
  • 232
  • +0/-0
    • Wots I.T.?
Should we remove the old version before upgrading to this contrib Brianr??

Also, should the repositry be smeserver-contribs?

Offline brianr

  • *
  • 988
  • +2/-0
Should we remove the old version before upgrading to this contrib Brianr??

Also, should the repositry be smeserver-contribs?

No need to remove the "old" version - it'll get overwritten.

Oops, sorry about the typo in the yum command - I've editted it now.
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline Teviot

  • *
  • 610
  • +0/-0
Hi

Followed the install instruction

Code: [Select]
yum install --enablerepo=smecontribs smeserver-mailstats
and now SYSMON doesn't work.

Any suggestions?  I thought about uninstalling and reinstalling but that would lose current data held.

Regards
Teviot
Regards
M0GLJ
......................................................
I am new to SAIL SME Server v8b6 and have been using SME for many years.
I have already done some research and only ask questions if I still can't work it out.

Offline brianr

  • *
  • 988
  • +2/-0
You should log an entry in the bugtracker, post the link here, and describe in more detail (in the bug entry) what it is that is now not working.
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline Franco

  • *
  • 1,171
  • +0/-0
    • http://contribs.org
I have the sysmon contrib installed, and I just installed mailstats. Everything is fine so far.

Offline mmccarn

  • *
  • 2,627
  • +10/-0
I have created a wiki page for mailstats: http://wiki.contribs.org/Mailstats and posted there what I could find in the script by way of documentation.


Offline hartmut

  • 11
  • +0/-0
    • trepkau.de
just posted scripts to create smedb and mysqldb to brian, after approval from him, we can put them into the contrib area.

this is a contrib I was looking for since I've changed to 7.3 and lost the daily reports from "knuddi"



Offline brianr

  • *
  • 988
  • +2/-0
... and i have checked the scripts and loaded them up to the contrib area, and also edited the wiki entry to reflect this.

here is the link to the wiki:

http://wiki.contribs.org/Mailstats#Logging_to_a_MySQL_database
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........