[jcifs] SmbException: java.io.IOException and hi cpu usage

Michael B Allen mba2000 at ioplex.com
Thu Sep 28 15:46:40 GMT 2006

On Thu, 28 Sep 2006 17:47:30 +0300
lexius.java at gmail.com wrote:

> Hi, I am using jcifs_1.2.9 and have problem with 100% cpu usage after 
> SmbException: java.io.IOException.
> getSmbFilesListjcifs.smb.SmbException: java.io.IOException: Output Shutdown at 
> com.sun.enterprise.server.ss.provider.ASOutputStream.checkClosed(ASOutputStream.java:154) 
> at 
> com.sun.enterprise.server.ss.provider.ASOutputStream.write(ASOutputStream.java:122) 
> at jcifs.smb.SmbTransport.doSend(SmbTransport.java:465) at 
> jcifs.util.transport.Transport.sendrecv(Transport.java:70) at 
> jcifs.smb.SmbTransport.send(SmbTransport.java:654) at 
> jcifs.smb.SmbSession.sessionSetup(SmbSession.java:295) at 
> jcifs.smb.SmbSession.send(SmbSession.java:246) at 
> jcifs.smb.SmbTree.treeConnect(SmbTree.java:147) at 
> jcifs.smb.SmbFile.connect(SmbFile.java:794) at jcifs.smb.SmbFile.connect0
> (SmbFile.java:761) at jcifs.smb.SmbFile.send(SmbFile.java:658) at 
> jcifs.smb.SmbFile.doFindFirstNext(SmbFile.java:1705) at 
> jcifs.smb.SmbFile.listFiles(SmbFile.java:1596) at 
> jcifs.smb.SmbFile.listFiles(SmbFile.java:1504) 
> Any body can help me?

It looks like the socket is getting closed while we're trying to write
to it. If this was happening in a loop and there was no logic to abort
the loop if an exception of this kind occured then that would explain
the cpu usage. But from looking at the code I don't see a problem like
that. Check the logic of your code.


Michael B Allen
PHP Active Directory SSO

More information about the jcifs mailing list