Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

ToKi

I changed the way the script runs. I will check the results tomorrow.
martin

ToKi wrote:

The file can be transfered through the gui but when in command line mode the 0kb file doesn't get sent. Usually you get 100% on the transfer file line but with 0kb files it stays at 0%. I had a look at the log and there were no failures.
I have tried sending in both Ascii and Binary modes with the same result.

Are you sure that the file wasn't actually created? Despite 0% indication in script output?
ToKi

martin wrote:

OK, but again does it work in GUI or not?

I have the same problem.
The file can be transfered through the gui but when in command line mode the 0kb file doesn't get sent. Usually you get 100% on the transfer file line but with 0kb files it stays at 0%. I had a look at the log and there were no failures.
I have tried sending in both Ascii and Binary modes with the same result.

. 2009-02-23 17:35:13.264 Copying 1 files/directories to remote directory "/Toxxx"
. 2009-02-23 17:35:13.264 PrTime: Yes; PrRO: No; Rght: rw-r--r--; PrR: No (No); FnCs: N; RIC: 01; Resume: S (102400); CalcS: No; Mask:
. 2009-02-23 17:35:13.264 TM: M; ClAr: No; CPS: 0; ExclM(No):
. 2009-02-23 17:35:13.264 AscM: *.*html; *.htm; *.txt; *.php; *.php3; *.cgi; *.c; *.cpp; *.h; *.pas; *.bas; *.tex; *.pl; .htaccess; *.xtml; *.css; *.cfg; *.ini; *.sh; *.xml
. 2009-02-23 17:35:13.264 File: "L:\xxxxgan\20090223_RExx_APAC_xxx.txt"
. 2009-02-23 17:35:13.264 Copying "L:\xxxxgan\20090223_RExx_APAC_xxx.txt" to remote directory started.
. 2009-02-23 17:35:13.264 Ascii transfer mode selected.
. 2009-02-23 17:35:13.264 Opening remote file.
> 2009-02-23 17:35:13.264 Type: SSH_FXP_OPEN, Size: 60, Number: 259
< 2009-02-23 17:35:13.717 Type: SSH_FXP_HANDLE, Size: 10, Number: 259
> 2009-02-23 17:35:13.717 Type: SSH_FXP_CLOSE, Size: 10, Number: 772
> 2009-02-23 17:35:13.717 Type: SSH_FXP_SETSTAT, Size: 56, Number: 521
< 2009-02-23 17:35:14.514 Type: SSH_FXP_STATUS, Size: 40, Number: 772
< 2009-02-23 17:35:14.514 Status/error code: 0
< 2009-02-23 17:35:14.967 Type: SSH_FXP_STATUS, Size: 40, Number: 521
< 2009-02-23 17:35:14.967 Status/error code: 0
. 2009-02-23 17:35:14.967 Closing connection.
. 2009-02-23 17:35:14.967 Sending special code: 12
. 2009-02-23 17:35:14.967 Sent EOF message
martin

OK, but again does it work in GUI or not?
Guest

Hi,

Sorry for the late reply.

I am currently using WinSCP 4.0.5.

I have actually tried transferring the files to other different servers (using FTP though) and it seems to have successfully transferred the files over even though it is an empty .txt file.

When I tried with another server, it seems to have "skipped" transferring these empty files over for both FTP and SFTP.

Hope you can help me out here. Thanks a lot!
martin

Can you try the same in GUI? Also what version of WinSCP are you using? Can you try the latest one?
Guest

Hi,

Apologies on the late reply.

I am unsure on how to log the transfer. However, I have entered the exact comamnds in the previous email in console and these are the output I get in the console. Hope it helps.

winscp> put D:\folder_name\*.txt
D:\folder_name\empty1.txt | 0 kB | 0.0 kB/s | binary | 0%
D:\folder_name\empty2.txt | 0 kB | 0.0 kB/s | binary | 0%
D:\folder_name\empty3.txt | 0 kB | 0.0 kB/s | binary | 0%
winscp>


I do not think that the transfer failed though. Seems like it was 'skipped'. Does the server settings have anything to do with this? Thank you once more for your help!
martin

Re: Transferring Empty Text Files

They should not. Can you post a log file showing unsuccessful upload of single empty file?
Guest

Transferring Empty Text Files

Hi,

I wrote a WinSCP Script to transfer files over. But seems like empty .txt files are ignored for transfers. Is there any way to enable empty .txt files for transfer too?

Here is an example of my script:

option batch off 

option confirm off
option transfer binary
 
open sftp://username:password@server:22

put D:\folder_name\*.txt
 
close
exit


Thanks in advance for the reply.