06-17-2003, 01:00 PM | #1 (permalink) |
Insane
|
FTP script help
I'm trying to write an FTP script to copy a file to an FTP server that I call with a MS-DOS batch file. I'm using "FTP -i -s:script.txt". Does anyone know where I can find a good reference for FTP script files, as well as a list of the command switches available for the FTP command?
|
06-17-2003, 01:55 PM | #3 (permalink) |
Insane
|
I know how to create the file, and I know the basic commands to put in it, but was looking for a something to help me do things like: be able to know whether the file was successfully transmitted without having to read it on the screen, so that I could display it to the user and/or log it.
|
06-17-2003, 08:18 PM | #4 (permalink) |
Insane
Location: Pacific NW
|
If you are attempting to ascertain whether or not the file was transferred in it's entirety you could run a CRC check prior to the transfer and then again right afterwards. Compare the two values, if they match, you've got a successful transfer. You may be able to find some freeware that works in batch mode. Here's a reference to CRC.
http://www.mindworkshop.com/alchemy/crc.html Good luck, there are many solutions to this problem.
__________________
"The gift of liberty is like that of a horse, handsome, strong, and high-spirited. In some it arouses a wish to ride; in many others, on the contrary, it increases the desire to walk." -- Massimo d'Azeglio |
06-18-2003, 03:05 AM | #5 (permalink) |
Tilted
|
hi. use expect. should be what you need.
goto http://expect.nist.gov/ it's available in linux & win32. easy to learn. good luck. |
Tags |
ftp, script |
|
|