Damn it, forgot to make one change in the command stream.

//JOBNAME JOB ACCT,NAME,CLASS=A,MSGCLASS=H,
// NOTIFY=&SYSUID
//SFTP     EXEC PGM=IKJEFT01,REGION=0M
//SYSTSPRT DD   SYSOUT=*
//SYSEXEC  DD   DISP=SHR,DSN=SYS1.SBPXEXEC (MAY BE DIFFERENT)
//SYSTSIN  DD   *
OPUT 'SOME.DATA.SET.NAME <http://some.data.set.name/>' '/tmp/SOME.FILE.NAME
<http://some.file.name/>'
OSHELL { echo 'password'; +
         echo 'cd /tmp'; +
         echo 'ascii'; +
         echo 'put /tmp/SOME.FILE.NAME <http://some.file.name/>'; } | +
       sftp -v use...@remote.ssh.server
/*
//* CHANGE password TO ACTUAL PASSWORD
//* CHANGE cd COMMAND TO ACTUAL REMOTE DIRECTORY
//* REMOVE ascii LINE FOR BINARY TRANSFER
//* CHANGE userid TO REMOTE USER'S ID
//* CHANGE remote.ssh.server TO ACTUAL DNS NAME/IP ADDR
//SCP      EXEC PGM=IKJEFT01,REGION=0M
//SYSTSPRT DD   SYSOUT=*
//SYSEXEC  DD   DISP=SHR,DSN=SYS1.SBPXEXEC (MAY BE DIFFERENT)
//SYSTSIN  DD   *
OPUT 'SOME.DATA.SET.NAME <http://some.data.set.name/>' '/tmp/SOME.FILE.NAME
<http://some.file.name/>'
OSHELL echo 'password' | +
       scp /tmp/SOME.FILE.NAME <http://some.file.name/> +
       use...@remote.ssh.server:-
/tmp/SOME.UNIXFILE.NAME <http://some.unixfile.name/>
/*
//* CHANGE password TO ACTUAL PASSWORD
//* CHANGE userid TO ACTUAL REMOTE USER ID
//* CHANGE remote.ssh.server TO ACTUAL DNS NAME/IP ADDR
//* !!!! CRITICAL !!!!
//* Note that scp command is spread over 3 lines due to
//* length of SYSTSIN input line. TSO will concatenate
//* them together into one logical line. IT IS CRITICAL
//* that you notice that I put the output file name
//* (/tmp/SOME.UNIXFILE.NAME <http://some.unixfile.name/>) on its own line
//* IT IS CRITICAL that this start in column 1.
//* IT IS ALSO CRITICAL that the previous line
//* end in a dash instead of a plus and that the dash
//* is _IMMEDIATELY_ after the colon. This is to
//* force TSO to concatenate all these characters together
//* without any spaces, which would destroy the UNIX
//* command line.
//
‚Äč


-- 
Heisenberg may have been here.

Unicode: http://xkcd.com/1726/

Maranatha! <><
John McKown

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to