Hi all...

First of, a huge wave to David L. for a great piece of software...
Secondly a big wave to the rest on this list...

(For the record, I'm in sunny (Currently) Johannesburg, South
Africa... [We have been tormented with torrential rains in the last
month or so...])

I am new to this list, so please bear with me if this has all been
done and said...

I came across a serious problem with re-entrance on FreeBSD 5.4, and
found various references to the issue. Basically XMail server would
keep "freezing" with an error logged to the syslog in the form of:
     Feb 14 20:43:22 mailbox XMail[46411]: Unable to create file

This would mostly happen after a flood of spamming attempts, or someone
hammering the server with POP requests... (Like 5-7 requests/second for
the next week...)

Restarting XMail nightly worked for the most part, but that was
treating the symptom, not the problem...
     
This is after successfully running it on FreeBSD 4.5 for a long time...

As this was one of my "pet projects", I didn't have much time sniffing
and searching for clues, so it took me a while... Hence the nightly
reboot...

The only reference to the "unable to open file" error, on the
xmailserver site, only appears in the SMTP Error messages under -19,
which didn't tell me much... 

So I went digging and found a reference to KQUEUE entries not being
released.

So the direct reference I found, said, remove "-lr_c" from MakeFile,
and the problem would be resolved...
Did that, and had a violent crash with coredump... :(

So I checked some more, and there where references to SMP kernels and
re-entrant issues. This seems to be in effect with any 5.x kernel. I
then figured out how to do it... 

So a quick rundown on check/solution:
   Install lsof for FreeBSD
   run "lsof | grep XMail | grep KQUEUE". If these keep increasing,
   particularly after a POP mailcheck, without decreasing, your system
   suffers from this problem...
    
   Patch the kernel as given at:
         http://www.freebsd.org/cgi/query-pr.cgi?pr=threads/75795
   Rebuild kernel and reboot.
   
   Now it won't have the problem anymore, and I can see the KQUEUEs popping
   in and out on my box...

I have not found a direct thread on this particular problem, and the
kernel patches are still not in the latest release (5.4rc11), so I
think there might be more people with this issue, and hopefully this
bit might help them...

I have rebooted with the new kernel this morning, and hopefully I
should have peace and quiet overnight... I will report more on this,
should I notice any more issues...

David: Could you possibly add this to the server doc/homepage somewhere?

-- 
Best regards,
 Jorn                            mailto:[EMAIL PROTECTED]

-
To unsubscribe from this list: send the line "unsubscribe xmail" in
the body of a message to [EMAIL PROTECTED]
For general help: send the line "help" in the body of a message to
[EMAIL PROTECTED]

Reply via email to