Spamassassin very slow

2008-07-22 Thread lyd mc
Hi guys,

Last day my mail server became very slow. I haven't found any mysterious 
errors/warnings in /var/log/message and maillog. When I disable spammilter in 
sendmail it became fast.

What causes spamassassin to slow?

Here is my config:

snippet from sendmail.mc

    FEATURE(`local_procmail_lmtp')
    . . .
    FEATURE(dnsbl,`all.rbl.jp')dnl 
    dnl MAILER(local) 
    MAILER(procmail)dnl
    MAILER(smtp)
    INPUT_MAIL_FILTER(`spamassassin',`S=local:/var/run/spamass-milter.sock, 
F=,   T=C:15m;S:4m;R:4m;E:10m')dnl
    INPUT_MAIL_FILTER(`clmilter', `S=local:/var/run/clamav/clmilter.sock, 
F=, T=S:4m;R:4m')dnl
    define(`confINPUT_MAIL_FILTERS', `clmilter,spamassassin')dnl
 

I have .procmailrc in every home directory of my mail users and it goes like 
this:

 :0fw: spamassassin.lock
 | /usr/local/bin/spamc

 :0:
 * ^X-Spam-Level: \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*
 /dev/null

    :0:
    * ^X-Spam-Status: Yes
    Probably-Spam

I also have RulesDuJour installed and spammassassin --lint does complain about 
it.

spamassassin process:

11894  ??  Ss 0:30.74 /usr/local/bin/spamd -c -d -r -m 20 --round-robin 
/var/run/spamd/spamd.pid (perl5.8.8)
11903  ??  Ss 0:06.55 /usr/local/sbin/spamass-milter -f -p 
/var/run/spamass-milter.sock

When my mail server became slow, my mqueue grows rapidly and there are lots of 
spamc processes.

Please help, thnx.

alyd












___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Spamassassin very slow

2008-07-22 Thread Edwin Groothuis
> iLast day my mail server became very slow. I haven't found any
> mysterious errors/warnings in /var/log/message and maillog. When I
> disable spammilter in sendmail it became fast.

Normally this happens to me when I a DNS based RBL suddenly goes
out of action.

I know it won't solve your problem, but have a look on the wire if
all DNS queries are answered in time.

Edwin

-- 
Edwin Groothuis  |Personal website: http://www.mavetju.org
[EMAIL PROTECTED]|  Weblog: http://www.mavetju.org/weblog/
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Spamassassin very slow

2008-07-22 Thread lyd mc
Thanks edwin. I better watch those dns rbl feature..

Regards,

alyd

--- On Wed, 7/23/08, Edwin Groothuis <[EMAIL PROTECTED]> wrote:
From: Edwin Groothuis <[EMAIL PROTECTED]>
Subject: Spamassassin very slow
To: freebsd-questions@FreeBSD.org
Cc: "lyd mc" <[EMAIL PROTECTED]>
Date: Wednesday, July 23, 2008, 10:38 AM

> iLast day my mail server became very slow. I haven't found any
> mysterious errors/warnings in /var/log/message and maillog. When I
> disable spammilter in sendmail it became fast.

Normally this happens to me when I a DNS based RBL suddenly goes
out of action.

I know it won't solve your problem, but have a look on the wire if
all DNS queries are answered in time.

Edwin

-- 
Edwin Groothuis  |Personal website: http://www.mavetju.org
[EMAIL PROTECTED]|  Weblog: http://www.mavetju.org/weblog/


  
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Spamassassin very slow

2008-07-22 Thread lyd mc
Thanks james. I thought before that spamc on .procmailrc handle checking mail 
for outgoing (mail from local user) and milter in sendmail handle incoming mail 
checking.

Best  regards,

alyd 

--- On Wed, 7/23/08, James Tanis <[EMAIL PROTECTED]> wrote:
From: James Tanis <[EMAIL PROTECTED]>
Subject: Re: Spamassassin very slow
To: [EMAIL PROTECTED], freebsd-questions@freebsd.org
Date: Wednesday, July 23, 2008, 11:08 AM

"lyd mc" <[EMAIL PROTECTED]> wrote:
>
> What causes spamassassin to slow?
>
> Here is my config:
>
> snippet from sendmail.mc
> ..  ..
>
> I have .procmailrc in every home directory of my mail users and it goes
like
> this:

So if I'm understanding you correctly.. your calling spamc from a sendmail
milter *and* .procmailrc. That's pretty redundant and would definately slow
you down. Choose one based on your needs.

>
> I also have RulesDuJour installed and spammassassin --lint does complain
about
> it.
>

Extra rules can slow you down regardless of syntax, but most computers
created this decade can handle RulesDuJour fine. Personally I think your
main problem is that your effectively spam checking every message twice. The
spamassassin queues most likely get filled followed by sendmail having to
wait and queue up the slack.
--
James Tanis
Technical Coordinator
Monsignor Donovan Catholic High School
e: [EMAIL PROTECTED]



___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Spamassassin very slow

2008-07-22 Thread James Tanis
"lyd mc" <[EMAIL PROTECTED]> wrote:
>
> What causes spamassassin to slow?
>
> Here is my config:
>
> snippet from sendmail.mc
> ..  ..
>
> I have .procmailrc in every home directory of my mail users and it goes
like
> this:

So if I'm understanding you correctly.. your calling spamc from a sendmail
milter *and* .procmailrc. That's pretty redundant and would definately slow
you down. Choose one based on your needs.

>
> I also have RulesDuJour installed and spammassassin --lint does complain
about
> it.
>

Extra rules can slow you down regardless of syntax, but most computers
created this decade can handle RulesDuJour fine. Personally I think your
main problem is that your effectively spam checking every message twice. The
spamassassin queues most likely get filled followed by sendmail having to
wait and queue up the slack.
--
James Tanis
Technical Coordinator
Monsignor Donovan Catholic High School
e: [EMAIL PROTECTED]


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Spamassassin very slow

2008-07-22 Thread Philip M. Gollucci

James Tanis wrote:

"lyd mc" <[EMAIL PROTECTED]> wrote:

What causes spamassassin to slow?

Here is my config:

snippet from sendmail.mc
..  ..

I have .procmailrc in every home directory of my mail users and it goes

like

this:
The following setup by the front line mx's (2 of them) for apache.org 
can handle ~1million messages/day for a total of 2million without 
breaking a sweat.


No .procailrc involved.

/etc/rc.conf:
postfix_enable="YES"
sendmail_enable="NO"
sendmail_submit_enable="NO"
sendmail_outbound_enable="NO"
sendmail_msp_queue_enable="NO"

rbldnsd_enable="YES"
rbldnsd_flags="MASKED OUT"

svscan_enable="YES"

clamav_clamd_enable="YES"
clamav_freshclam_enable="YES"

spamd_enable="YES"
spamd_pidfile="/var/run/spamd/spamd.pid"
spamd_flags="--min-children=4 --max-children=40 --min-spare=2 
--max-spare=8 --max-conn-per-child=100 -c -d 
--socketpath=/var/run/spamd/socket --socketmode=0777 -r ${spamd_pidfile}"


Thats FreeBSD 6.x (soon to be 7.x when I update it)
httpd 2.2.9+worker mpm with qpsmtp using mod_perl

in my consulting buss, for sendmail I use the following sendmail.mc snippet:

INPUT_MAIL_FILTER(`clmilter',`S=local:/var/run/clamav/clmilter.sock, F=, 
T=S:4m;R:4m')
INPUT_MAIL_FILTER(`spamassassin', `S=local:/var/run/spamass-milter.sock, 
F=, T=C:15m;S:4m;R:4m;E:10m')

define(`confMILTER_MACROS_ENVRCPT',`r, v, Z')
define(`confMILTER_MACROS_CONNECT',`b, j, _, {daemon_name}, {if_name}, 
{if_addr}')



That said, all individual users do you ~/.procmailrc, with the following 
rule:

:0
* ^X-Spam-Status: Yes
spam




--

Philip M. Gollucci ([EMAIL PROTECTED])
o:703.549.2050x206
Senior System Admin - Riderway, Inc.
http://riderway.com / http://ridecharge.com
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Spamassassin very slow

2008-07-22 Thread lyd mc
thnx Philip, your config will help in my current setup.



--- On Wed, 7/23/08, Philip M. Gollucci <[EMAIL PROTECTED]> wrote:
From: Philip M. Gollucci <[EMAIL PROTECTED]>
Subject: Re: Spamassassin very slow
To: "James Tanis" <[EMAIL PROTECTED]>
Cc: [EMAIL PROTECTED], freebsd-questions@freebsd.org
Date: Wednesday, July 23, 2008, 11:53 AM

James Tanis wrote:
> "lyd mc" <[EMAIL PROTECTED]> wrote:
>> What causes spamassassin to slow?
>>
>> Here is my config:
>>
>> snippet from sendmail.mc
>> ..  ..
>>
>> I have .procmailrc in every home directory of my mail users and it
goes
> like
>> this:
The following setup by the front line mx's (2 of them) for apache.org 
can handle ~1million messages/day for a total of 2million without 
breaking a sweat.

No .procailrc involved.

/etc/rc.conf:
postfix_enable="YES"
sendmail_enable="NO"
sendmail_submit_enable="NO"
sendmail_outbound_enable="NO"
sendmail_msp_queue_enable="NO"

rbldnsd_enable="YES"
rbldnsd_flags="MASKED OUT"

svscan_enable="YES"

clamav_clamd_enable="YES"
clamav_freshclam_enable="YES"

spamd_enable="YES"
spamd_pidfile="/var/run/spamd/spamd.pid"
spamd_flags="--min-children=4 --max-children=40 --min-spare=2 
--max-spare=8 --max-conn-per-child=100 -c -d 
--socketpath=/var/run/spamd/socket --socketmode=0777 -r ${spamd_pidfile}"

Thats FreeBSD 6.x (soon to be 7.x when I update it)
httpd 2.2.9+worker mpm with qpsmtp using mod_perl

in my consulting buss, for sendmail I use the following sendmail.mc snippet:

INPUT_MAIL_FILTER(`clmilter',`S=local:/var/run/clamav/clmilter.sock, F=, 
T=S:4m;R:4m')
INPUT_MAIL_FILTER(`spamassassin', `S=local:/var/run/spamass-milter.sock, 
F=, T=C:15m;S:4m;R:4m;E:10m')
define(`confMILTER_MACROS_ENVRCPT',`r, v, Z')
define(`confMILTER_MACROS_CONNECT',`b, j, _, {daemon_name}, {if_name}, 
{if_addr}')


That said, all individual users do you ~/.procmailrc, with the following 
rule:
:0
* ^X-Spam-Status: Yes
spam




-- 

Philip M. Gollucci ([EMAIL PROTECTED])
o:703.549.2050x206
Senior System Admin - Riderway, Inc.
http://riderway.com / http://ridecharge.com
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.


  
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Spamassassin very slow

2008-07-22 Thread lyd mc
Hi James,

I remove spamc on .procmailrc and I can see lots of improvements!

Thanx,

alyd

--- On Wed, 7/23/08, James Tanis <[EMAIL PROTECTED]> wrote:
From: James Tanis <[EMAIL PROTECTED]>
Subject: Re: Spamassassin very slow
To: [EMAIL PROTECTED]
Date: Wednesday, July 23, 2008, 11:07 AM

"lyd mc" <[EMAIL PROTECTED]> wrote:
> 
> What causes spamassassin to slow?
> 
> Here is my config:
> 
> snippet from sendmail.mc
> ..  ..
> 
> I have .procmailrc in every home directory of my mail users and it goes
like
> this:

So if I'm understanding you correctly.. your calling spamc from a sendmail
milter *and* .procmailrc. That's pretty redundant and would definately slow
you down. Choose one based on your needs.

> 
> I also have RulesDuJour installed and spammassassin --lint does complain
about
> it.
> 

Extra rules can slow you down regardless of syntax, but most computers
created this decade can handle RulesDuJour fine. Personally I think your
main problem is that your effectively spam checking every message twice. The
spamassassin queues most likely get filled followed by sendmail having to
wait and queue up the slack.

--
James Tanis
Technical Coordinator
Monsignor Donovan Catholic High School
e: [EMAIL PROTECTED]


  
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Spamassassin very slow

2008-07-23 Thread jdow

That says you are driving spamd into swapping. The two canonical
reasons for SpamAssassin to be really slow are dead BL sites or
overrunning memory and going into heavy swapping. You made a
change to reduce the amount of swapping. Hence you probably have
too many children at any one time.

Modify your minimum and maximum number of children. For best results
you MAY want only one child per processor you can spare from other
work. Regardless, use "top" to see when you go into swapping with the
spamd load. When you do, back off the number of children running at
any given time.

Check rule sets you are using with RDJ. Some of them require incredible
amounts of memory to run. I run enough rules to pull down about 60
megabytes of memory. There are some rule sets that can go over 100
megabytes on the SARE site (SpamAssassin Rules Emporium). 40 children
at 100 megabytes each could use a "lot of machine". {^_-}

You might consider investigating the spamassassin users list at
apache.org. You can find it via the SpamAssassin home page,
http://www.spamassassin.org/

{^_^}   Joanne
- Original Message - 
From: "lyd mc" <[EMAIL PROTECTED]>

Sent: Tuesday, 2008, July 22 23:31



Hi James,

I remove spamc on .procmailrc and I can see lots of improvements!

Thanx,

alyd

--- On Wed, 7/23/08, James Tanis <[EMAIL PROTECTED]> wrote:
From: James Tanis <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]

"lyd mc" <[EMAIL PROTECTED]> wrote:


What causes spamassassin to slow?

Here is my config:

snippet from sendmail.mc
..  ..

I have .procmailrc in every home directory of my mail users and it goes

like

this:


So if I'm understanding you correctly.. your calling spamc from a sendmail
milter *and* .procmailrc. That's pretty redundant and would definately 
slow

you down. Choose one based on your needs.



I also have RulesDuJour installed and spammassassin --lint does complain

about

it.



Extra rules can slow you down regardless of syntax, but most computers
created this decade can handle RulesDuJour fine. Personally I think your
main problem is that your effectively spam checking every message twice. 
The

spamassassin queues most likely get filled followed by sendmail having to
wait and queue up the slack.

--
James Tanis
Technical Coordinator
Monsignor Donovan Catholic High School
e: [EMAIL PROTECTED]



___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to 
"[EMAIL PROTECTED]" 


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"