HP OpenVMS Systems

ask the wizard
Content starts here

FTP File Transfer Completion Status?

» close window

The Question is:

 
I am running OpenVMS Alpha version 7.2-1 with Digital TCP/IP Services 5.0A.
 
I have a program that populates a directory with a bunch of files that get
 FTPed to a server everyday.  I want to delete the files that are successfully
 FTPed, but I do not see a way to determine which ones were successful or
 unsuccessful without restarti
ng FTP everytime.  Establishing a FTP connection everytime is very inefficient
 and timing is somewhat critical.
 
We used to use TCPware instead of DIGITAL TCP/IP Services and I was able to use
 an ERROR_EXIT n (n is the file number that I was on) to determine which file I
 failed on.  This was very helpful so I could be certain of the file that
 failed.  This eliminate
d resending all files but allowed me to send the file that the errors occurred
 on and the remaining files during the next FTP.
 
 
 
 


The Answer is :

 
  The Compaq FTSO package would be one approach.  FTSO provides
  automatic restart, retry, command execution upon completion, and
  a variety of other useful features.
 
  A sequence of COPY/FTP commands would be another -- see below.
 
  Alternatively, configure NFS serving of the directory involved.
 
 
  To relocate specified files from one system to another through FTP
  or similar file transfer tool via an automated process can be performed
  utilizing a three-step procedure:
 
    o The FTP script copies the file to the target host with a
      temporary file name.
 
    o It then directs the host to rename the file to the desired
      target filename on the remote host.
 
    o When the remote rename has been completed successfully, then
      the file on the local system can be renamed to a name
      indicating that the file has been transfered.
 
  This sequence prevents the target system from inadvertently
  trying to process an incompletely-transfered file.
 
  In the event of a transfer problem, the FTP client will stop executing
  the script and control will be returned back to the DCL procedure with
  a $STATUS and a $SEVERITY code that can be used for additional error
  handling.
 

answer written or last revised on ( 5-JAN-2001 )

» close window