Not-so-simple FTP question

Hello everyone, how are you? Hope fine.

So, let's suppose I have FTP access to a server, holding several, continuously changing databases; suppose I want to turn on my computer, and launch a program that will automatically connect to this FTP, save the databases I want, and put them on a designated folder with a timestamp added to the file name.

Now, suppose I want to ask you how to do this. If so, what would be your answer?
LVL 1
Emanuele_CiriachiAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
SorensonConnect With a Mentor Commented:
If the operating system is windows, create a script file and execute it with the ftp command.
for example
---startup.bat--
ftp runftp.scr
----------------

--runftp.scr--
open host.domain.com
user ftpuser
ftppassword
lcd c:\localfolder
bin
get databasename.db
quit
----------------

http://support.microsoft.com/?kbid=96269

0
 
Emanuele_CiriachiAuthor Commented:
Will this work with Filezilla?

How can I add a timestamp to the filename?
0
 
Emanuele_CiriachiAuthor Commented:
Oh and yes, OS is Windows.
0
What Kind of Coding Program is Right for You?

There are many ways to learn to code these days. From coding bootcamps like Flatiron School to online courses to totally free beginner resources. The best way to learn to code depends on many factors, but the most important one is you. See what course is best for you.

 
SorensonCommented:
The file will be timestamped with the time of the download.  I am not sure I understand the filezilla comment portion.  Is filezilla the server or client?
0
 
nprignanoTechnical ArchitectCommented:
Filezilla is a Mozilla ftp client, and the above script will NOT use an FTP client to download the file - it will do so using ftp protocol only.


nprignano
0
 
Emanuele_CiriachiAuthor Commented:
Filezilla is a freeware FTP client for Windows.

Another side question: "runftp.scr" must be edited as a text file?
0
 
SorensonCommented:
With this, you would not need the ftp client for windows.  It would use the command line one that is included with windows xp.

Yes both the batch and script file would be a text file.

0
 
Emanuele_CiriachiAuthor Commented:
If my database is inside a directory, how should I change

get databasename.db

in

get /databasefolder/databasename.db

?
0
 
SorensonCommented:
or add line
cd /databasefolder

then do "get databasename.db"
0
 
SorensonCommented:
run the commands manually to see what works.
open a command window (dos window) on xp
Type:  ftp
then at the > prompt type each command from the .scr file in and test.
0
 
Emanuele_CiriachiAuthor Commented:
Ok. Thanks for the added informations, that will earn you 50% more points.
0
 
SorensonCommented:
thank you
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.