cURL / Mailing Lists / curl-library / Single Mail


POST_QUOTE option failing during sftp for rename in Windows sftp serverū

From: Naganathan Rajesh <>
Date: Fri, 25 Feb 2011 15:39:03 +0000

Hi All,
We are using CURLOPT_POSTQUOTE option to rename a file after transfer of the file using sftp protocol.But the POSTQUOTE option for rename is failing when the sftp server is runing in Windows O/S.The same code works perfectly when the sftp server is Linux or Sun OS.
 Following is the Log from the server side.Is this is a open issue from libcurl or an improper server implementation?
Complete FTP:
2011-02-23 14:46:31,203 INFO SFTPSubsystemServer [48:temp] Opened /C-drive/.A20110223.0826+0000-XYZ.TBD.0000075BCD15.1 for writing
2011-02-23 14:46:31,844 ERROR SFTPSubsystemServer [48:temp] Failed to move file .A20110223.0826+0000-XYZ.TBD.0000075BCD15.1 => A20110223.0826+0000-XYZ.TBD.0000075BCD15.1: The process cannot access the file because it is being used by another process.
Cerebres SFTP :
2011/02/23 15:05:33 [5] File Open command received
2011/02/23 15:05:33 [5] File handle to '//.A20110223.0931+0000-XYZ.TBD.0000075BCD15.1' opened
2011/02/23 15:05:33 [5] Upload started for file 'C:\.A20110223.0931+0000-XYZ.TBD.0000075BCD15.1'
2011/02/23 15:05:34 [5] Unable to rename file 'C:\.A20110223.0931+0000-XYZ.TBD.0000075BCD15.1'
2011/02/23 15:05:34 [5] Upload complete for file 'C:\.A20110223.0931+0000-XYZ.TBD.0000075BCD15.1'
2011/02/23 15:05:34 [5] Handle '//.A20110223.0931+0000-XYZ.TBD.0000075BCD15.1' closed
FreeFTPD also shows a similar error that rename could not be done on a open file.
Did someone face some issue like and there is a resolution for this?


List admin:
Received on 2011-02-25