Hi I have created an MTA pickup for spamc of SpamAssassin. I have just submitted it to the MailEnable administrators, not too sure when they will put it up, but anyway just to share. If anyone is interested, I can share the application. I can quickly do one for spamassassin.bat as well.
The application is written in C#, and piping the mail directly to spamc and piping the output to a file.
MTA Pickup for spamc of SpamAssassin
-
- Posts: 19
- Joined: Tue Nov 18, 2003 6:17 am
- Location: Singapore
- Contact:
MTA Pickup for spamc of SpamAssassin
White Knight
-
- Posts: 302
- Joined: Tue Jul 19, 2005 1:12 pm
- Location: 404
WinSpamC
I also made something similar, some time ago, for WinSpamC (MTA Pickup Event and MailBox Delivery Event).
Using spamc/WinSpamC is much less resource intensive than passing the mail to SpamAssasin directly, so those who currently use the SpamAssasin pickup should give either spamc or WinSpamC a try.
Using spamc/WinSpamC is much less resource intensive than passing the mail to SpamAssasin directly, so those who currently use the SpamAssasin pickup should give either spamc or WinSpamC a try.
-
- Posts: 19
- Joined: Tue Nov 18, 2003 6:17 am
- Location: Singapore
- Contact:
SpamAssassin
Yes, spamc and WinSpamc is more efficient because spamd runs in the background.
Another problem is with the supplied MTA pickup for SpamAssassin. The codes show that it uses a loop to check for the exit of SpamAssassin. This takes up a lot of processing power. That means that not only is SpamAssassin less efficient, the MTA pickup supplied is inefficent.
Another problem is with the supplied MTA pickup for SpamAssassin. The codes show that it uses a loop to check for the exit of SpamAssassin. This takes up a lot of processing power. That means that not only is SpamAssassin less efficient, the MTA pickup supplied is inefficent.
White Knight
I have installed Win32 SpamAssassin following the guidelines in http://www.openhandhome.com/howtosa310.html.
Can your pickup be used with this? Also, I am a VB dev, so any thoughts on how you wrote yours, i could contribute my own.
Can your pickup be used with this? Also, I am a VB dev, so any thoughts on how you wrote yours, i could contribute my own.
-
- Posts: 19
- Joined: Tue Nov 18, 2003 6:17 am
- Location: Singapore
- Contact:
Win32 SpamAssassin
Hi netblue,
SpamAssassin has 2 modes of operation.
1) Call SpamAssassin.exe - This will load the application up everytime you call it.
2) Load spamd - This will load the application once into the memory and allows a client to connect to it many times.
Many windows users are using SpamAssassin.exe, it is much easier to use, but it takes up quite a lot of processing power expecially since it loads up all the support files whenever it is called. Spamd however is a load-once-use-many program. Once loaded, all the support files are kept in memory and are used when a client connects to it. The pickup event I created is for use with spamc or winspamc which is the client that is used to connect to spamd.
So to answer your question, if you are using spamassassin.exe, then you can't use my pickup event. But if you are using spamd and spamc, then you can.
On my thoughts on developing the pickup event. If you want to create a pickup event for spamassassin.exe, take note of the loop used to check the exit of spamassassin.exe. That is a killer for the processor. You can either insert some more sleep or wait states, or implement some event handling when the spamassassin process exits. That will make it more efficient. Try sleep with 200 or 500. You should time spamassassin to see what is the typical time it takes to complete, then tune the amount accordingly.
SpamAssassin has 2 modes of operation.
1) Call SpamAssassin.exe - This will load the application up everytime you call it.
2) Load spamd - This will load the application once into the memory and allows a client to connect to it many times.
Many windows users are using SpamAssassin.exe, it is much easier to use, but it takes up quite a lot of processing power expecially since it loads up all the support files whenever it is called. Spamd however is a load-once-use-many program. Once loaded, all the support files are kept in memory and are used when a client connects to it. The pickup event I created is for use with spamc or winspamc which is the client that is used to connect to spamd.
So to answer your question, if you are using spamassassin.exe, then you can't use my pickup event. But if you are using spamd and spamc, then you can.
On my thoughts on developing the pickup event. If you want to create a pickup event for spamassassin.exe, take note of the loop used to check the exit of spamassassin.exe. That is a killer for the processor. You can either insert some more sleep or wait states, or implement some event handling when the spamassassin process exits. That will make it more efficient. Try sleep with 200 or 500. You should time spamassassin to see what is the typical time it takes to complete, then tune the amount accordingly.
White Knight
As I understand, combination of spamd and spamc are used in some server-to-server environment, where spamd runs on machine, which actually hosts spamassassin application, and spamc connects to this machine and issues just a query, whether mail is a SPAM or not.
Now, regarding to your post, it seems to be possible to run this on a single machine and gain in performance and resources usage with spamd's posibilities to load spamassassin into memory just once and using spamc localy.
Am I right?
If that is true, where can I get spamd for windows and spamc client/pickup event for ME? I have spamassassin environment ready to test with this pickup event.
Now, regarding to your post, it seems to be possible to run this on a single machine and gain in performance and resources usage with spamd's posibilities to load spamassassin into memory just once and using spamc localy.
Am I right?
If that is true, where can I get spamd for windows and spamc client/pickup event for ME? I have spamassassin environment ready to test with this pickup event.
-
- Posts: 19
- Joined: Tue Nov 18, 2003 6:17 am
- Location: Singapore
- Contact: