[jcifs] renameTo

roy-jcifs at xemaps.com roy-jcifs at xemaps.com
Tue May 23 16:45:16 GMT 2006


Just letting you know we got it again with the 1.2.9.

jcifs.util.transport.TransportException: Transport2 timedout waiting for response to SmbComRename[command=SMB_COM_RENAME,received=false,errorCode=0,flags=0x0018,flags2=0xC003,signSeq=0,tid=4103,pid=19192,uid=6145,mid=779,wordCount=1,byteCount=245,searchAttributes=0x0016,oldFileName=\schonfeld.com\mail\2006\05\22\18\20060522185330000_-_p45143.tm3,newFileName=\schonfeld.com\mail\2006\05\22\18\20060522185330000.eml]
	at jcifs.util.transport.Transport.sendrecv(Transport.java:76)
	at jcifs.smb.SmbTransport.send(SmbTransport.java:602)
	at jcifs.smb.SmbSession.send(SmbSession.java:231)
	at jcifs.smb.SmbTree.send(SmbTree.java:102)
	at jcifs.smb.SmbFile.send(SmbFile.java:687)
	at jcifs.smb.SmbFile.renameTo(SmbFile.java:1791)

So it turns out that I was wrong on what was happening.  After looking at my logs some more, the rename was actually renaming successfully and then erroring out leaving only one file.  But we have a cleanup process that tries again and errors out again (since the renamed file already exists) leaving two files.

Thank you,


On 5/23/06, Michael B Allen <mba2000 at ioplex.com> wrote:
> Odd. The remameTo method does not use copyTo and it does not copy. It
> simply issues an SmbComRename command to the server. So as to whether
> or not it's atomic I suppose that probably depends on the server. Look
> at the code for jcifs/smb/SmbFile.java:renameTo. It's really simple.
> Mike

More information about the jcifs mailing list