Steps for submitting a job and automatically receiving output
You can submit a job by using the JCL that you have built on the FTP server rather than on the FTP client. Automatic retrieval of jobs works only if the file contains a single job. It does not work for files that include more than one job (multiple JOB cards).
Procedure
Perform the following steps to submit a job using FTP.
Results
The MVS FTP server reads the data set SOURCE.JCLNAME and submits it to the JES internal reader.
You know you are done when you see the following replies. The next two replies indicate that the
job has been submitted and the MVS FTP server is waiting for it
to complete. The third reply indicates that the job has finished and the files have been copied to
your output data set:
125 Submitting job SOURCE.JCLNAME FIXrecfm 80
125 When JOB05125 is done, will retrieve its output250 Transfer completed successfully.
Note: When submitting a job and automatically receiving the output, remember that your session is
suspended. You should use care, based on the anticipated run time of your job, when using this
function. If your session times out, you must restart FTP and manually retrieve your output. Session
timeouts are caused by the following cases:
- The FTP Server does not wait long enough for the job that is executing to end. Increase the JESPUTGETTO interval in the FTP.DATA data statement on the server. This defaults to 10 minutes and defines the amount of time FTP waits for the submitted job to complete before timing out.
- The FTP client does not wait long enough for the job to complete and the server to retrieve the output. Increase the DATACTTIME timer value in the client. This defaults to two minutes and defines the amount of time the client waits for a response from the server.
- The control or data connection is closed. This is usually caused by a firewall that timed out the session because of inactivity. Add FTPKEEPALIVE (control connection) and DATAKEEPALIVE (data connection) statements in the FTP.DATA data file.
- FTP client and FTP Server receive resets. This is usually caused by a firewall that timed out the session because of a lack of activity. Add an FTPKEEPALIVE statement or decrease the time interval on the current FTPKEEPALIVE statement in the FTP.DATA data file. The keepalive value on FTPKEEPALIVE must be less than the expected value of the server.