There are several ways to migrate a PS file from a mainframe to a Linux server. The easiest is probably File Transfer...
Here's a sample job control language (JCL) in the mainframe:
//FTPJOB JOB ACCT
//FTPSTEP EXEC PGM=FTP
//OUTPUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
put 'main.frame.file' mainframe.file
Create the JCL and stack up mainframe FTP responses in the SYSIN DD card -- the same as in an interactive session. Each response is case-sensitive and will not work with JCL sequence numbers in columns 73 through 80. If you're editing in a Interactive System Productivity Facility, set the edit profile to use mixed case (caps off) and no sequence numbers (unnum).
There are three things to watch out for:
- You may need to include the mainframe data set name in quotes (as in the above example).
- Text files are automatically translated from EBCDIC to ASCII if you set the transfer mode to ASCII. Otherwise, binary files should be transferred in bin mode (as shown above) to avoid changing data.
- Linux files don't have logical record lengths or block sizes. This is less of a problem for text files because IBM's FTP marks the end of each record with carriage return/line feed character combinations that Linux text editors understand. Binary files, on the other hand, will be byte streams on the server.
Also note that FTP requires a valid logon ID and password for the server. More sophisticated file transfer software, like IBM Sterling Connect:Direct, transfers files between platforms under the originator's security context without sending passwords over the network.
About the author:
Robert Crawford spent 29 years as a systems programmer, covering CICS technical support, Virtual Storage Access Method, IBM DB2, IBM IMS and other mainframe products. He programmed in Assembler, Rexx, C, C++, PL/1 and COBOL. Crawford is currently an operations architect based in south Texas, establishing mainframe strategy for a large insurance company.
Check out these related community questions and answers:
How do I convert FTP to secure FTP on the mainframe?
Sending a mainframe file to users in CSV format?
I want to compare PS file date with current date. Is there a JCL sort?
Dig Deeper on IBM system z and mainframe systems
Related Q&A from Robert Crawford
For better mainframe capacity planning, how do I convert CPU hours to MIPS? And is there a way to calculate the relationship between MIPS and MSUs?continue reading
I have two years of experience in mainframe technology, currently working as a mainframe developer. I want to change to Java technology.continue reading
I want to replicate DB2 from the mainframe to an AIX box since it's cheaper and the copy can be used for testing. Is this possible?continue reading
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.