Domino on Linux/Unix, Troubleshooting, Best Practices, Tips and more ...

Issue with SMTP Extension Managers in 8.5.x

Daniel Nashed  July 12 2010 10:52:05 PM

We ran into an interesting issue on a Domino 8.5.1 FP3 Server on Linux when using SpamGeek.
SpamGeek leverages SMTP Extension Manager events which change the way the SMTP code works in the background to pass information to Extension Manager routines.
Our server crashed every couple of hours or even in shorter intervals depending on the load and after 2 weeks of debugging and hotfix code it turned out that the issue we ran into was a really bad memory overwrite occuring in some very certain situations.

If you ran into a crash situations with a similar call-stack like this, you are running into the same issue. We hope that this fix makes it into the next fixpack and 8.5.2 but it is not confirmed yet.
For reference the SPR number is #NORK86PSDM and it can hit any SMTP Extension Manager which leverages the EM_AFTER event of EM_SMTPMESSAGEACCEPT.

-- Daniel

Thread 4 (Thread -1405572192 (LWP 1938)):
#0 0xffffe410 in __kernel_vsyscall ()
#1 0xb5e64d11 in ___newselect_nocancel () from /lib/
#2 0xb6178720 in FRDoSleep ()
from /opt/ibm/lotus/notes/latest/linux/
#3 0xb6179925 in OSRunExternalScript ()
from /opt/ibm/lotus/notes/latest/linux/
#4 0xb617afcc in OSFaultCleanupExt ()
from /opt/ibm/lotus/notes/latest/linux/
#5 0xb617b0b6 in OSFaultCleanup ()
from /opt/ibm/lotus/notes/latest/linux/
#6 0xb6146bd7 in fatal_error ()
from /opt/ibm/lotus/notes/latest/linux/
#7 <signal handler called>
#8 0xffffe410 in __kernel_vsyscall ()
#9 0xb5ff7661 in raise () from /lib/
#10 0xb61949f3 in Panic () from /opt/ibm/lotus/notes/latest/linux/
#11 0xb615b951 in LockHandleExt ()
from /opt/ibm/lotus/notes/latest/linux/
#12 0xb615bac3 in LockHandle ()
from /opt/ibm/lotus/notes/latest/linux/
#13 0xb615c47c in OSUnlockObject ()
from /opt/ibm/lotus/notes/latest/linux/
#14 0xb61c9f26 in OSUnlockPool ()
from /opt/ibm/lotus/notes/latest/linux/
#15 0xb671e5ef in NSFNoteGetInfo ()
from /opt/ibm/lotus/notes/latest/linux/
#16 0xb6720176 in NSFNoteClose ()
from /opt/ibm/lotus/notes/latest/linux/
#17 0x080640d8 in CSMTPProtocol::~CSMTPProtocol ()
#18 0x0805aa6e in CSMTPTask::~CSMTPTask ()
#19 0x0805acea in CSMTPSrv::OnDisconnect ()
#20 0x0805c0be in CSMTPSrv::OnConnect ()
#21 0x08076fc7 in CIServ::ServerTaskProtocolMachine ()
#22 0x0807d9e4 in CIServ::ServerTaskIOCP ()
#23 0x0807f0f2 in ServerThread ()
#24 0xb61701a6 in ThreadWrapper ()
from /opt/ibm/lotus/notes/latest/linux/
#25 0xb5ff034b in start_thread () from /lib/
#26 0xb5e6b65e in clone () from /lib/

1Rob Shaver  07/13/2010 6:36:25 PM  Should CodeStore be De-listed from PlanetLotus

I'm sorry to see that PlanetLotus is contemplating de-listing Jake has been publishing high quality Notes/Domino developer information for many years. I'm not sure why PlanetLotus want's to lose that. Is it because he is doing some SharePoint development for one of his customers? His articles on SharePoint have reinforced my commitment to using Notes/Domino.

2Daniel Nashed  07/14/2010 11:04:37 PM  Issue with SMTP Extension Managers in 8.5.x

@Rob, I am sorry for that but I am not sure what I can do to help.

-- Daniel

3N Grant  09/08/2013 6:15:05 AM  Issue with SMTP Extension Managers in 8.5.x

Hi Daniel

I am interested in what you have said here 'leverages the EM_AFTER event of EM_SMTPMESSAGEACCEPT'

The doco says "The Callback routines for the EM_AFTER notification can change the reply returned to the connecting host however, care must be taken not to change the reply code from success to error or vice-versa as this would cause the sender-SMTP and receiver-SMTP servers to be out of synch."

Possibly they are changing the structures in After not Before !!!

I have written a few EMs & never had any luck with the After events.

4Daniel Nashed  09/11/2013 8:50:50 AM  Issue with SMTP Extension Managers in 8.5.x

In the EM_AFTER of the EM_SMTPMESSAGEACCEPT you can only change text and maybe the error-id because the logic of that code has been already processed.

If you send back a different error code the other SMTP server will not be in sync in what your server is doing.

You should put your logic in the EM_BEFORE and only set the text that you want in the EM_AFTER.

The EM_BEFORE allows you to change the return code which will have impact on the flow.

And I am finally setting the text in the EM_AFTER event to overwrite the standard text that comes with the status code that is set in the EM_BEFORE.

-- Daniel



    • [IBM Lotus Domino]
    • [Domino on Linux]
    • [Nash!Com]
    • [Daniel Nashed]