1. Home
  2. Tutorials
  3. Linux vs IBM Mainframe
Yolinux.com Tutorial

Linux for IBM TSO / MVS / OS390 Mainframe Users

This guide should help the IBM Mainframe programmers migrate out of the computer Jurasic period and into the modern Linux/UNIX world. This tutorial covers a comparison of Mainframe commands, file types and system variables with the Linux/Unix equivalent.

Free Information Technology Magazines and Document Downloads
TradePub link image

Linux Command Comparison with TSO:

TSO Command Linux/Unix Command Description
ls -l (include more file info)
List directory contents
EDIT file-name nano, ex, sed, vi, xedit, xemacs,dtpad Edit a file.
HELP man
man -k subject-key-word
Display manual on command.
Display list of commands related to key word or subject
FORT f95
Fortran compiler
LINK ld GNU Linker
To run an executable on Linux simply type the name of the executable. If it is an executable, the system will run it.
SUBMIT command&
To submit a job to run in the background, append an apmersand to the command. The commands bg, fg and jobs are bash shell commands. Third party batch ques can also be set up in Linux.
LIST cat
List the contents of a file to the screen
LISTCAT ls List members of a partitioned dataset has no direct equivalent. Use "ls" to list files in a directory
LOGON user-id su - user-id Login as a different user. (Switch User)
LOGOFF exit Exit session.
TIME date Show date and time
SEND mail
Send message to a user
RENAME mv Move/Rename a file
DELETE rm Delete/remove a file
Allocate a dataset. Not necessary on Linux/Unix. The touch file-name command will create an empty file if necessary.
Not required as Unix file systems do not allocate extra space for a file. Unix only uses what is needed
TEST gdb Debug program. Must compile with the "-g" option.

File types:

Mainframe file type Linux equivalent Description
CLIST Shell script Bourne (sh), C-Shell (csh or tcsh), PERL
OBJ file-name.o Object file
FORT file-name.f Fortran source file
PREFIX1.PREFIX2.PARTITN(DATASET) directory-1/directory-2/file-name.extention There is no equivalent to the Mainframe partitioned dataset. The closest concept is a heiarchy of directories with files held in the directory

TSO Symbols/Unix Environment Variables:

TSO Symbol Unix Environment Variable Description
Shell and default environment definition.
&SYSPREF $HOME System prefix/Home directory.
Most recent return code. Unix return code of "0" is a return from a successful execution.
DATE=`date` Command in back quotes substitutes the result of the command into the variable. See date man page for formats available. Time is a reserved bash shell word.

TSO CLIST Command statement - Bash shell Comparisson:

TSO Statement Unix/Linux Description
SET set Set variable value.
IF-THEN-ELSE-END if-then-elif-fi If block
DO-WHILE-END while-do-donw Loop construct
READ read Read input
WRITE printf
Write output
RETURN return Return from script
GOTO goto label: Jump to location in code.
EXIT exit Terminate execution.
touch file-name
> or >>
File handlers.

See the bash man page for lots of detail on shell scripting on Unix/Linux.



by Cameron Newham, Bill Rosenblatt
O'Reilly & Associates, ISBN# 1565923472

This book is a great bash shell script book.

"UNIX Power Tools"
by Jerry D. Peek, Tim O'Reilly, Mike Loukides
O'Reilly & Associates, ISBN# 1565922603

This book is a requirement for any serious system administrator or developer. One of my favorite UNIX books.

Z Journal
The Resource for Users of IBM Mainframe Systems.

z/Journal is the only independent magazine dedicated solely to IT professionals in organizations using IBM mainframe computer systems (e.g. System z, S/390).

Z journal


    Bookmark and Share