Hi, I have a problem with increasing memory usage of SpamAssassin on windows (spamc/spamd). I created a stand alone test program to check if the increasing memory is a problem of communication code or SA. The program tests the sample-spam.txt file using a loop of 1000 times.
Result (Win2k SP4; ActiveState Perl 5.6.1): memory increasing Next I moved the script to a linux box (change path names only). The SA is installed without any extra options (perl MakrFile.PL, make, make test, make install). I run the script and monitor the memory (size) with top. Result (Linux 2.2.14, Perl 5.6.1): memory increasing Can someone check my script and proof the result on another configuration please? Thanks Klaus sa-test.pl ---------------------------------------------- my $PREFIX = '/usr/bin/perl'; # substituted at 'make' time my $DEF_RULES_DIR = '/usr/bin/perl/share/spamassassin'; # substituted at 'make' time my $LOCAL_RULES_DIR = '/etc/mail/spamassassin'; # substituted at 'make' time use Mail::SpamAssassin; my ($spamtest) = new Mail::SpamAssassin({ dont_copy_prefs => $dontcopy, rules_filename => ($opt{'configpath'} || 0), local_tests_only => ($opt{'local'} || 1), debug => ($opt{'debug'} || 0), paranoid => ($opt{'paranoid'} || 0), home_dir_for_helpers => (defined $opt{'home_dir_for_helpers'} ? $opt{'home_dir_for_helpers'} : $orighome), # 'rules_filename' => 'c:/etc/spamassassin.rules', 'userprefs_filename' => $ENV{HOME}.'/.spamassassin.cf', PREFIX => $PREFIX, DEF_RULES_DIR => $DEF_RULES_DIR, LOCAL_RULES_DIR => $LOCAL_RULES_DIR }); Mail::SpamAssassin::Util::clean_path_in_taint_mode(); $spamtest->compile_now(0); use strict; sub processFile { my ($spamtest, $file) = @_; open(IN, "<$file"); my @msglines = <IN>; close(IN); chomp @msglines; # test with check and NoMailAudit object # my $mail = Mail::SpamAssassin::NoMailAudit->new(data => [EMAIL PROTECTED]); # my ($status) = $spamtest->check($mail); # $status->finish(); # $mail->finish(); # check with plain message text my $msg = join("\n", @msglines); my ($status) = $spamtest->check_message_text($msg); $status->finish(); @msglines = (); } my ($i) = 0; while ($i < 1000) { processFile($spamtest, "/export/klaus/Mail-SpamAssassin-2.55/sample-spam.txt"); $i++; print $i, "\n"; } 1; ---------------------------------------------- ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Spamassassin-talk mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/spamassassin-talk