//SSH2 EXEC PGM=IKJEFT1A,
// DYNAMNBR=75,
// TIME=1440,
// REGION=6M
//SYSPRINT DD SYSOUT=*
//SYSTSPRT DD SYSOUT=*
//SYSTERM DD DUMMY
//STDOUT DD PATH='/tmp/&SYSUID.-SCP2FTP.out',
// PATHOPTS=(OWRONLY,OCREAT,OTRUNC),
// PATHMODE=(SIRUSR,SIWUSR)
//STDERR DD PATH='/tmp/&SYSUID.-SCP2FTP.err',
// PATHOPTS=(OWRONLY,OCREAT,OTRUNC),
// PATHMODE=(SIRUSR,SIWUSR)
<<<<<<< .working
//STDENV DD DSN=&SYSUID..SSZ.SRVR551.PARMLIB(SSHENV),
// DISP=SHR
//SYSTSIN DD *
BPXBATCH PGM /usr/lpp/ssh2/bin/ssh2 -S -f +
-oPidfile=/tmp/my_ssh2.pid +
-L ftp/8888:localhost:21 +
user@ftp_server
/*
//FTP EXEC PGM=FTP,PARM='localhost 8888 (EXIT=8'
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
username passwd
ascii
get ftp_test.txt 'USER.FTP.TEST'
quit
/*
//FTP EXEC PGM=FTP,PARM='localhost 8888 (EXIT=8'
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
username passwd
ascii
put 'USER.FTP.TEST2' result.txt
quit
/*
//SSH2STOP EXEC PGM=BPXBATCH,
// REGION=0M,
// TIME=100,
// PARM='SH kill `cat /tmp/my_ssh2.pid`'
//STDOUT DD PATH='/tmp/&SYSUID.-SSH2STOP.out',
// PATHOPTS=(OWRONLY,OCREAT,OTRUNC),
// PATHMODE=(SIRUSR,SIWUSR)
//STDERR DD PATH='/tmp/&SYSUID.-SSH2STOP.err',
// PATHOPTS=(OWRONLY,OCREAT,OTRUNC),
// PATHMODE=(SIRUSR,SIWUSR)
/*
|