5 May

My database got too big and I wanted to make it run faster.

I added some indexes to the dspam database, in <dspam-src>/src/tools.mysql_drv/mysql_objects-speed.sql:

> alter table dspam_token_data add index(spam_hits);

>alter table dspam_token_data add index(innocent_hits);

>alter table dspam_token_data add index(last_hit);


I then dropped my current database (probably not the best idea, but adding indexes on the fly was very very slow). And reloaded the new schema *as well as* the 'virtual_users.sql' – you will need this *or* 'virtual_user_aliases.sql'.

 To test it I used:

>echo "asdf " | /usr/local/bin/dspam –stdout –deliver=spam,innocent –mode=tum –feature=chained,noise –enable-signature-headers –user amavis

 This should return some sort of stat on the innocence of the mail. If it throws an error you might have loaded in the wrong user sql ('virtual_users.sql'/'virtual_user_aliases.sql') above, just drop the table and load in the other one.

 Finally, check 'dspam/bin/dspam_stats -H' this should have some out put on how much spam is going through the server, if this doesn't work you probably have misconfigured something. You can also check the token data in the mysql db.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: