Your browser does not support HTML5 local storage or you have disabled it. Some functionality on this site, including saving your privacy settings and offering you special discounts, uses local storage and may not work with local storage disabled. We recommend allowing the use of local storage in your browser. In some browsers, it is the same setting used for disabling cookies.

SSH Tectia

Submitting JCL Jobs over Secure Shell

Secure Shell can also be used to run JCL jobs remotely. For that an REXX script, submit.rexx (shown below), is needed on the Unix System Services. The script is used to submit the data received from the Secure Shell connection to MVS.

/*   rexx   */

/* SUBMIT   */
address mvs "execio * DISKR STDIN (stem JOB.  "
/*                                                                  */
/* submit MVS job */
jobid=say SUBMIT(JOB.)
say word(jobid,2)
if pos("JOB",jobid) > 0 then rc=0
else rc=16
exit rc

Example 1: JCL written on Unix host is submitted over Secure Shell.

Copy the submit.rexx script, for example, to /usr/local/bin. The script can be found from the /opt/tectia/doc/zOS/samples directory.

$ cp /opt/tectia/doc/zOS/samples/submit.rexx /usr/local/bin/

Launch the Secure Shell connection from the Unix client using the JCL file as standard input.

$ sshg3 username@mf_server /usr/local/bin/submit.rexx < /tmp/my_jcl