Hi Michael,

this happens when the SMTP server receive a new mail from a remote
client. When the DATA command is received the SMTP server opens a
temporary file and start streaming the mail content to this file.

The "Exception opening socket: null" probably happens because the
connection is no more available in the mean time.

Often this kind of error is caused by something else going wrong, and it
is difficult to track if nothing else can be found.

>From your message I understand that once James Server starts throwing
this exception the only solution is to restart it because every
connection ends in this exception raised, right?

Can you run a "netstat -n" and a "jstack <jamespid>" when it happens, to
understand what the server is doing and what are the active connections?

Stefano

Michael Weissenbacher ha scritto:
> Hi List,
> today one of my JAMES installations developed an interesting (and annoying!)
> behavior. It works perfectly for hours, but suddendly this stack trace appears
> in the smtpserver log file:
> **********
> 27/09/07 15:24:53 INFO  smtpserver: Connection from nospamv3.net4you.at 
> (127.0.0.1)
> 27/09/07 15:24:53 ERROR smtpserver: Exception opening socket: null
> java.lang.NullPointerException
>         at java.io.SequenceInputStream.read(SequenceInputStream.java)
>         at java.io.SequenceInputStream.read(SequenceInputStream.java:152)
>         at
> org.apache.james.core.MimeMessageInputStreamSource.<init>(MimeMessageInputStreamSource.java:78)
>         at org.apache.james.core.MailImpl.<init>(MailImpl.java:181)
>         at
> org.apache.james.smtpserver.DataCmdHandler.processMail(DataCmdHandler.java:266)
>         at
> org.apache.james.smtpserver.DataCmdHandler.doDATA(DataCmdHandler.java:133)
>         at
> org.apache.james.smtpserver.DataCmdHandler.onCommand(DataCmdHandler.java:81)
>         at
> org.apache.james.smtpserver.SMTPHandler.handleConnection(SMTPHandler.java:393)
>         at
> org.apache.james.util.connection.ServerConnection$ClientConnectionRunner.run(ServerConnection.java:432)
>         at
> org.apache.excalibur.thread.impl.ExecutableRunnable.execute(ExecutableRunnable.java:55)
>         at 
> org.apache.excalibur.thread.impl.WorkerThread.run(WorkerThread.java:116)
> **********
> 
>>From this moment no more mail gets spooled or delivered. JAMES still listens 
>>on
> port 25 and accepts mails but it closes the connection prematurely. At the
> moment i have no other option as to constantly check for the exception and
> restart JAMES afterwards. Then it works fine again. Sadly, I haven't yet 
> found a
> pattern or a reproducable test case.
> 
> At this point I don't have a clue what could cause this problem. Maybe there 
> are
> just too many sockets open? I am using JAMES 2.3.1 and I never had this 
> problem
> with 2.3.0. This doesn't mean that it wouldn't also occur with 2.3.0, but this
> is a productive system and I don't like the idea of downgrading just for 
> testing
> things out.
> 
> I can provide more background information if needed.
> 
> Maybe someone can point me in the right direction?
> 
> many thanks,
> Michael



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to