Koozali.org: home of the SME Server

Unjunkmgr not sending notification mail

Offline nicolatiana

  • *
  • 721
  • +0/-0
Unjunkmgr not sending notification mail
« on: December 14, 2013, 09:30:44 AM »
Hi
I've a few installations of sme-unjunkmanager all working fine.
The last I installed does not send notification mails.
- .junkmail users folders are populated (i.e. there are recent messages that should be listed);
- launching manually  /usr/local/unjunkmgr/spamreminder.pl I do not get evident errors.
Is there a way to get some log or run the .pl script in a verbose mode ?

Nicola

Config:
[root@server ~]# /sbin/e-smith/db configuration show unjunkmgr
unjunkmgr=service
    LocalOnly=yes
    adminemails=yes
    enabled=yes
    statsclient=enabled
    statsclienthost=central.swerts-knudsen.dk
    statsclientport=1112
    unjunkhost=192.168.40.250
    useremails=yes

« Last Edit: December 14, 2013, 09:47:58 AM by nicolatiana »
Consulente di Smeserver.it -  Soluzioni e supporto su Sme server in Italia.

Offline Jean-Philippe Pialasse

  • *
  • 2,762
  • +11/-0
  • aka Unnilennium
    • http://smeserver.pialasse.com
Re: Unjunkmgr not sending notification mail
« Reply #1 on: December 17, 2013, 06:01:34 PM »
what is the version on non working SME and what is the version on others ?


rpm -qa smeserver-unjunkmgr

Offline nicolatiana

  • *
  • 721
  • +0/-0
Re: Unjunkmgr not sending notification mail
« Reply #2 on: December 17, 2013, 06:06:24 PM »
Working and not working are both smeserver-unjunkmgr-2.1-2.el5.sme

Nicola
Consulente di Smeserver.it -  Soluzioni e supporto su Sme server in Italia.

Offline Jean-Philippe Pialasse

  • *
  • 2,762
  • +11/-0
  • aka Unnilennium
    • http://smeserver.pialasse.com
Re: Unjunkmgr not sending notification mail
« Reply #3 on: December 17, 2013, 06:56:41 PM »
any error in /var/log/messages while running the script ?

tail -f /var/log/messages

Offline nicolatiana

  • *
  • 721
  • +0/-0
Re: Unjunkmgr not sending notification mail
« Reply #4 on: December 17, 2013, 09:15:00 PM »
None. The contrib does not seem to write any log in any place. I was just looking for some debug or verbose options. I've placed a mail directly to Jesper according to the wiki page with a link to this post.

Nicola

Consulente di Smeserver.it -  Soluzioni e supporto su Sme server in Italia.

Offline Knuddi

  • *
  • 540
  • +0/-0
    • http://www.scanmailx.com
Re: Unjunkmgr not sending notification mail
« Reply #5 on: December 18, 2013, 09:50:27 AM »
There is unfortunately no special verbose mode available without editing the code. This is quite easy though.

Open /usr/local/unjunkmgr/spamreminder.pl and set $debug = 1 is line 71

# Debug enabled? - will send all reports to $admin_email_addr
my $debug = 1;

This should a little debug to start with.

Then run the script manually:

/usr/local/unjunkmgr/spamreminder.pl



Offline nicolatiana

  • *
  • 721
  • +0/-0
Re: Unjunkmgr not sending notification mail
« Reply #6 on: December 18, 2013, 09:53:08 AM »
 :)
Many thanks Knuddi !!!

Nicola
Consulente di Smeserver.it -  Soluzioni e supporto su Sme server in Italia.

Offline nicolatiana

  • *
  • 721
  • +0/-0
Re: Unjunkmgr not sending notification mail
« Reply #7 on: December 18, 2013, 04:10:10 PM »
putting $debug=1 and uncommenting a print statement in line 290 I did the folllowing confrontation between a server where I get the spam-unjunk mail report and the one where I do not get it:

1) Working:
video output of /usr/local/unjunkmgr/spamreminder.pl:
Quote
Found Spam email: hidden@mifar.com with score Spam (6.9) (0)Found Spam email: hidden@rotary2031.it with score Spam (5.2) (1)User : hidden (hidden)

corresponding message header where I extracted the spam relevant lines:
Quote
X-Spam-Level: ********
X-Spam-Status: Yes, hits=8.0 required=5.0 tests=HTML_IMAGE_ONLY_04,HTML_MESSAGE,HTML_MIME_NO_HTML_TAG,HTML_SHORT_LINK_IMG_1,MIME_BASE64_BLANKS,MIME_HTML_ONLY,MSGID_FROM_MTA_HEADER,RAZOR2_CF_RANGE_51_100,RAZOR2_CF_RANGE_E8_51_100,RAZOR2_CHECK,RDNS_NONE,T_KHOP_FOREIGN_CLICK,T_REMOTE_IMAGE,URIBL_BLOCKED
X-Spam-Flag: YES
X-Spam-Check-By: hidden-domain.it
X-Spam-Report: v=2.0 cv=TcwURGsh c=1 sm=1 p=tXbHRq2oAAAA:8
 p=uClTJ7Xtslgvyvu4nGkA:9 a=qBtjWUSc9CMPdisi4oDSTw==:17 a=1rPLbuJyMEUA:10
 a=YB88Tshpz5oA:10 a=jPJDawAOAc8A:10 a=zeH40u4Env0A:10 a=iJEPqD7cgKUA:10
 a=IkcTkHD0fZMA:10 a=ksMLu6rquOUA:10 a=oGRXrEK-AAAA:8 a=QEXdDO2ut3YA:10
 a=KxyxJeeqAQsA:10 a=Iq5J-LwyKFkA:10 a=0KDs1bEon0kA:10
 a=qBtjWUSc9CMPdisi4oDSTw==:117
X-Spam-Rating: mxavas1.ad.aruba.it 1.6.2 0/1000/N
X-Old-Spam-Flag: YES
X-Old-Spam-Status: Yes

2) Not working:
video output of /usr/local/unjunkmgr/spamreminder.pl:
Quote
Found Spam email: noreply@wetransfer.com with score Unknown (0)Found Spam email: noreply@wetransfer.com with score Unknown (1)User : Segreteria Operativa (segreteria)

corresponding message header where I extracted the spam relevant lines:
Quote
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on mx-avas-01.mvmnet.com
X-Spam-Flag: YES
X-Spam-Level: ******
X-Spam-Status: Yes, score=6.3 required=4.0 tests=HTML_IMAGE_RATIO_04,HTML_MESSAGE,MVMNET_UNSUB,MVMNET_XMAIL_GENMLR,MVMNET_XMAIL_PHPMAILER,MVMNET_XMAIL_PHPMLR,RDNS_NONE autolearn=disabled version=3.3.2
X-Spam-Relay-Country: DE DE
X-Spam-Report:
        *  0.5 MVMNET_XMAIL_PHPMLR Moviement PHPMailer
        *  0.5 MVMNET_XMAIL_GENMLR Generic Mailer
        *  1.5 MVMNET_XMAIL_PHPMAILER Moviement phpmailer detected
        *  1.8 MVMNET_UNSUB URI: Moviement link to path with unsubscribe
        *  0.6 HTML_IMAGE_RATIO_04 BODY: HTML has a low ratio of text to image area
        *  0.1 HTML_MESSAGE BODY: HTML included in message
        *  1.3 RDNS_NONE Delivered to internal network by a host with no rDNS
X-Spam-Prev-Subject: =?utf-8?Q?Citt=C3=A0_dei_balocchi?=

In one situation in X-Spam-Status is used the word "hits" to identify spam score, in the other it is used the word "score" (all done, I suppose by the ISP that manage the mail of the two customers - 2 different ISPs); I don't know if this makes any difference in the spamreminder.pl leaving $spamcount variable to 0 so preventing to create and send the reminder message - see line 200 of the code:

Quote
($spam, $score, $spamlimit) = $x =~ m/^X-Spam-Status: ([^\,]+)\, hits=([^\ ]+)\ required=(.*)/;

NIcola


Consulente di Smeserver.it -  Soluzioni e supporto su Sme server in Italia.

Offline Stefano

  • *
  • 10,839
  • +2/-0
Re: Unjunkmgr not sending notification mail
« Reply #8 on: December 18, 2013, 05:35:17 PM »
ok.. then, please, fill a bug, you did (almost) all the work ;-)

Offline Knuddi

  • *
  • 540
  • +0/-0
    • http://www.scanmailx.com
Re: Unjunkmgr not sending notification mail
« Reply #9 on: December 18, 2013, 09:09:04 PM »
The difference between hits and score does not make the difference, but indicates that its two different versions of SME that its running on. Can you confirm that? Also are both running server mode or server-gateway mode?

Lastly has both SpamAssassin enabled?

 

Offline nicolatiana

  • *
  • 721
  • +0/-0
Re: Unjunkmgr not sending notification mail
« Reply #10 on: December 18, 2013, 09:28:27 PM »
Definitively the problem was spamassassin not enabled: I left disabled because a "strict" (too strict. . . . :-? ) spam check is already performed by the ISP of the not-working scenario. To have unjunkmgr working sa must be enabled. Stop!

I will compile an italian translation for the body of the notification message; may be useful for you for a future version ?

Nicola

P.S.: I think that "hits" or "score" in X-Spam-Status is coming from ISP mail server where mail is fetched: this may explain the difference.
« Last Edit: December 18, 2013, 09:31:39 PM by nicolatiana »
Consulente di Smeserver.it -  Soluzioni e supporto su Sme server in Italia.

Offline nicolatiana

  • *
  • 721
  • +0/-0
Re: Unjunkmgr not sending notification mail
« Reply #11 on: December 20, 2013, 01:44:29 PM »
Once again: many thanks Knuddy !

Nicola
Consulente di Smeserver.it -  Soluzioni e supporto su Sme server in Italia.