Page 1 of 1

Need help in SFTP & SYSIN

PostPosted: Mon Feb 10, 2014 12:34 pm
by rajaranganathan
Hi All,

I request all your help on an issue that i'm currently struck with,

Am currently doing secure FTP to transfer a file(Mainframe to server), on the which the file name used to change dynamically,
Example file name: PO7485.txt

In this the 4 digit numeric value will change dynamically, hence we generate the file name and place it in to a flat file and used it as SYSIN (Put statement) for my SFTP.
but , the secure FTP is not allowing a flat file to be used as SYSIN , hence it gets abend with JCL Error.

Is there any way i can use my flat file as sysin and get rid of this error ?

Re: Need help in SFTP & SYSIN

PostPosted: Mon Feb 10, 2014 12:40 pm
by BillyBoyo
Paste the full sysout from the step, please.

Re: Need help in SFTP & SYSIN

PostPosted: Mon Feb 10, 2014 3:12 pm
by rajaranganathan
There is no sysout for this paricular step , as this failed due to JCL Error, i have post the SYSMSG for that particular step,
changed the actual job name in to "JOBNAME" and actual file names in to " File.example.input"

JOBNAME STEP020 STEP060 GSYCARDI+002 - REQUEST FAILED BY SUBSYSTEM
===> CONCATENATION CONFLICT WITH LAM FILE File.example.input
JOBNAMESTEP020 STEP060 - STEP WAS NOT EXECUTED.
CONTROLM.JOBNAME .JOB0022.D0000119.? SYSOUT
CONTROLM.JOBNAME .JOB0022.D0000120.? SYSOUT
CONTROLM.JOBNAME .JOB0022.D0000121.? SYSOUT
STEP/STEP020 /START 2014038.2341
STEP/STEP020 /STOP 2014038.2341 CPU 0MIN 00.00SEC SRB 0MIN 00.00S
VOL SER NOS= PSMS02.
SYS1.PROD.BATCH.LOADLIB KEPT
VOL SER NOS= Volume.
JOB/JOBNAME/START 2014038.2341
JOB/JOBNAME/STOP 2014038.2341 CPU 0MIN 00.68SEC SRB 0MIN 00.01S

Re: Need help in SFTP & SYSIN

PostPosted: Mon Feb 10, 2014 3:30 pm
by BillyBoyo
OK, so your JCL is,,,? You are using CA-Librarian?

Re: Need help in SFTP & SYSIN

PostPosted: Mon Feb 10, 2014 3:38 pm
by rajaranganathan
here is my JCL, and what do you mean CA-Librarian ? (you mean production library ? if yes , you are right that we using production library)

XXSTEP020 EXEC PGM=GSY28C,
XX PARM='%RPATH=&RPATH,%UPATH=&UPATH,%PGSYU=&PGSYU&ADPRM1/'
IEFC653I SUBSTITUTION JCL - PGM=GSY28C,PARM='%RPATH=/ftpp/LZinR/MF,%UP
XXSYSOUT   DD SYSOUT=*
XXSYSPRINT DD SYSOUT=*
XXSYSUDUMP DD SYSOUT=&DMP
IEFC653I SUBSTITUTION JCL - SYSOUT=X
XXSTEP020.GSYCARDI DD
X/GSYCARDI DD DSN=&CNTL(GSY61R20),&LIBE
IEFC653I SUBSTITUTION JCL - DSN=SYS1.PRODSYSI.MASTER(SYSIN1),DISP=SH
XX                 DD
X/         DD DSN=&CNTL(GSY61R21),&LIBE
IEFC653I SUBSTITUTION JCL - DSN=SYS1.PRODSYSI.MASTER(SYSIN2),DISP=SH
XX                 DD DSN=File.example.input,
XX             DISP=SHR
IEFC653I SUBSTITUTION JCL - DSN=File.example.input,DISP
X/         DD DSN=&CNTL(&PUTS),&LIBE
IEFC653I SUBSTITUTION JCL - DSN=SYS1.PRODSYSI.MASTER(GSY61R22),DISP=SH
XX                 DD
X/         DD DSN=&CNTL(GSY61R23),&LIBE
IEFC653I SUBSTITUTION JCL - DSN=SYS1.PRODSYSI.MASTER(GSY61R23),DISP=SH
XXGSYCARDO DD DSN=&&FTPFILE,
DISP=(NEW,PASS,DELETE),
UNIT=&TEMP,
SPACE=(TRK,(1,1),RLSE),
DCB=(RECFM=FB,LRECL=80,BLKSIZE=0)

Re: Need help in SFTP & SYSIN

PostPosted: Mon Feb 10, 2014 5:15 pm
by BillyBoyo
It looks like SYS1.PRODSYSI.MASTER is managed by CA-Librarian. You will probably get your best results by asking the technical people responsible for this how they would like you to achieve what you need to do. It seems that a simple concatenation will not work as it stands.

Re: Need help in SFTP & SYSIN

PostPosted: Mon Feb 10, 2014 9:35 pm
by Peter_Mann
if in fact SYS1.PRODSYSI.MASTER is a LIBRAIAN filesystem and you have the LAM subsystem active, you will need to add a SUBSYS parm to the DD statement
// DSN=SYS1.PRODSYSI.MASTER(GSY61R22),DISP=SHR,SUBSYS=LAM
this may help

Re: Need help in SFTP & SYSIN

PostPosted: Wed Oct 15, 2014 1:04 pm
by Hoe San
Hi,

Do we need to code user id and password in the SFTP JCL? FTP we need to code UserID and password.

Thank you.

Re: Need help in SFTP & SYSIN

PostPosted: Wed Oct 15, 2014 2:58 pm
by Blackthorn
What product are you using for sftp?

We use Co:Z SFTP from Dovetailed Technologies, and generally speaking we generate a ssh key which is sent to the remote server so that a password is not required. It is possible though to specify the password in a file. Check the documentation for your particular product.

Re: Need help in SFTP & SYSIN

PostPosted: Wed Oct 15, 2014 4:53 pm
by Hoe San
My shop is thinking of using IBM Ported tools Open SSH. Does this tool come free with every zOS installation?