The professional tool to automate FTP and secure FTP transfers. Automated FTP & Batch FTP

Downloading files

Need help writing a script? Have any question about ScriptFTP?

Downloading files

Postby wglenn on Thu Mar 04, 2010 7:38 pm

I am thinking of purchasing but I want to make sure the default getfile wont download current uploading files.

File Stabilization Question.
I am going to set the scheduled task to run every 3 minutes to grab files.
My question is if a file is being uploaded as the script is kicking off, script ftp will not grab a half uploaded file, is this correct?

Thanks
Wayne
wglenn
 
Posts: 2
Joined: Thu Mar 04, 2010 7:35 pm

Re: Downloading files

Postby Zythan on Sun Mar 07, 2010 3:01 pm

Hello,

This is the experience that I have had and the solutions are not difficult to put into place.

You have a file that is called 'downloadthis.file', your script must not pick-up the file if the file has not been fully written by the progam that creates it.

So either, you get the program to create the file under a 'temp' name, ie 'downloadthis.tmp' and when fully written, it changes the name of the 'temp' file to the final name.

Or you modify your program to create a second file, like 'finished.ok', your script should then look for the '.ok' file, if it exists then it downloads the 'downloadthis.file', then deletes the '.ok' file.

This should stop things 'stepping on each others toes' as it were.

Regards.

Zythan
Zythan
 
Posts: 28
Joined: Wed Jul 15, 2009 9:57 am
Location: Nimes, France, EU

Re: Downloading files

Postby ScriptFTP support on Fri Mar 12, 2010 6:02 pm

Hello Wayne,

Some FTP servers do not actually place a file in the FTP site unless it is completely uploaded. Try to upload a big file with a traditional FTP client (not ScriptFTP) open another FTP session and check if the big file has reached the FTP site or not.

Of course, the solution that Zythan gave is also valid.
ScriptFTP support
Site Admin
 
Posts: 370
Joined: Mon Aug 04, 2008 3:08 pm
Location: Burgos, Spain, EU


Return to General



Who is online

Users browsing this forum: No registered users and 1 guest