[jcifs] timeout exception

Michael B Allen ioplex at gmail.com
Wed Oct 7 13:39:41 MDT 2009


Ok. In the future please always CC the JCIFS mailing list for
posterity (as I have just done).

On Tue, Oct 6, 2009 at 8:00 PM, jiang ding <jiang.d at tier-3.com> wrote:
> Hi Michael,
>  At last I find out the reason of the timeout. It is the realtime antivirus
> software in my target windows host. Unfortunately the file I was
> transferring by jcifs contains a virus. So the antivirus software in the
> target windows did some actions against the virus.
>  I tried another big file, it works like a charm.
>
> Thanks for your time.
>
> Jiang.
>
> -----Original Message-----
> From: Michael B Allen [mailto:ioplex at gmail.com]
> Sent: Wednesday, 7 October 2009 7:34 AM
> To: jiang ding
> Cc: jcifs at lists.samba.org
> Subject: Re: [jcifs] timeout exception
>
> On Tue, Oct 6, 2009 at 12:03 AM, jiang ding <jiang.d at tier-3.com> wrote:
>> Hi,
>>
>>  I am trying to copy a huge local file, size is 1.4G to a remote windows.
>>
>> Here is my code:
>>
>>   smbFile = new SmbFile(remoteSmbUrl);
>>
>>   BufferedInputStream in  = new BufferedInputStream(localFile);
>>
>>   BufferedOutputStream out = new
>> BufferedOutputStreram(smbFile.getOutputStream());
>
> Hi Jiang,
>
> You do not need to use Buffer{Input,Output}Stream. In fact it will
> probably just slow things down. Just use FileInputStream with the
> OutputStream of SmbFile directly.
>
>> jcifs.smb.SmbException: Transport1 timedout waiting for response to
>>
> SmbComClose[command=SMB_COM_CLOSE,received=false,errorCode=0,flags=0x0018,fl
> ags2=0xC803,signSeq=0,tid=2049,pid=51602,uid=2049,mid=12445,wordCount=3,byte
> Count=0,fid=16385,lastWriteTime=0]
>>
>> jcifs.util.transport.TransportException: Transport1 timedout waiting for
>> response to
>
> Try setting jcifs.smb.client.responseTimeout = 120000. This is 4 x the
> default of 30 seconds. The file server is probably trying to do
> something on close that is causing the response to take a long time.
> If it still happends after waiting 2 minutes, I don't know what the
> problem is.
>
> Mike
>
> --
> Michael B Allen
> Java Active Directory Integration
> http://www.ioplex.com/
>
>



-- 
Michael B Allen
Java Active Directory Integration
http://www.ioplex.com/


More information about the jCIFS mailing list