BSP - Beratung, Schulung, Projekte


MVS on your PC

A "Turnkey" Installation

This little document is intended for those people that would love to run their on MVS 3.8 on the PC, but don't think they should waste their time on installing that beast the hard way.

You can now install MVS with a few keystrokes, and off you go. The Distribution is on the CDROM, and contains everything that is needed. No need to download anything from weirs places of the internet, everything is set up already. The installation has been tested on:

Insert the CDROM into a suitable drive, change to the highest level directory on the CDROM, and enter setup. Then follow the few prompts and answer the questions the installation asks you. After the installation is complete, you can start MVS from your target installation# directory by entering _startmvs.

H:\>bash setup CD Rom drive is /cygdrive/h This is not Linux, assuming some kind of Windows Please enter the drive letter of the CDROM drive or press enter for default (H) You should now enter the drive letter for the drive that contains the CDROM, without the trailing colon. learned about Hercules some time ago... The chance to have a mainframe on your PC!

But... what is a mainframe without an Operating System. That is where Rick Fochtman came into the picture. He built a CD-Rom with OS/360 (MFT and MVT), and this CD I downloaded from the internet (well, the internet _is_ good for some things, once in a while....). I managed to get MFT and MVT operational on a spare computer running Linux, and I was hooked.

When finally Hercules was made available for Windows, and the MVS starter system became available, I seriously invested some effort into Hercules. This little document shows you how to create a working MVS 3.8 System on your PC, may it be Linux or Windows driven.

Please note that I have only Windows/NT and Suse Linux 7.0 available, and can only test my instructions on these two test beds. If you are running something else, you are on your own... but these instructions should help you nevertheless.

Save yourself some work

The full generation process and the generated system is available on the internet. The full system is hosted at a site generously provided by Richard Higson at ????????????????? The file size is ???????? bytes

A much smaller file, which only contains the necessary ingredients to build an MVS system, is available at mvsinst.zip

Step 1: Getting your stuff together

Download mvs_inst.zip file into a directory of your choice. Use your unzip program with a command that preserves the directory structure. After the UNZIP operation is complete, you should see the following directory structure

+                                installation directory
!
+------ conf                     configuration and control files
!
+------ dasd                     pregenerated dasd images
!
+------ herclin                  directory for Hercules binaries for linux
!
+------ hercwin                  directory for Hercules binaries for windows
!
+------ jcl                      contains the SYSGEN Job Control Files
!
+------ scripts                  command scripts used during installation
!
+------ snapshot                 Snapshots made during sysgen
!
+------ standalone               MVS standalone programs
!
+------ tapes                    Directory for tape files
!
+------ xmi                      MVS PDS files in xmi format

When you need to run command files, you will find them in the "scripts" directory. The command files for windows have the extension ".CMD", while the Linux scripts have now extension at all.

If you have a newer version of Hercules (Linux or Windows) feel free to place it into the correct subdirectory (hercwin or herclin)

Note that the Hercules version must have support for compressed disks and tapes using the bzip compression algorithm included, as all files used by this generation are compressed that way.

If in doubt, use the Hercules version provided in this package, it has the necessary compression enabled

Now the real fun starts. You first have to build a starter system. Don't worry, this is really not difficult. Just run the Installation script

INS0010 - Build Starter System

This scripts unpacks the starter system form an archive provided in the "snapshot" subdirectory. No error messages are expected from this script.

INS0020 - Build DASD Image files

The ins0020 builds two 3350 disk image files, one for the system residence, and one for the DLIB volume. Be patient, this will take a few moments

After the command script has finished, you should find two new files in the dasd directory

In the directory log you will find two files now that show you the success (hopefully) of the command file.

Note that the mvsres.148_n is not compressed, as opposed to mvsdlb.248. The compression utility only works on devices that do not have alternate tracks specified, while the utility that write IPL text requires alternate tracks. We therefore compress the system residence volume AFTER we have placed the IPL text on it.

INS0030 - Initialise the system residence volume

Invoking the command script ins0030 under Windows will start your telnet client, and then the Hercules engine. Under Linux, only the Hercules engine will be started. In order to fire up the telnet client, you need to switch to another linux session and invoke the _starttelnet script (which starts the telnet client).

Make sure that your telnet client connects to port 3270 on the machine where Hercules is running. If this the same machine as where the telnet client will be acivated, you can use the following command line:

telnet localhost 3270

Once the Hercules engine is started, and the telnet client has connected to it, you can now IPL the stand alone init utility. On the Hercules console you enter

ipl 00a
or, on the semi-graphical console that you reach by pressing the ESC key you enter
l b
After a short while the system should enter an enabled wait. Switch over to the telnet console and press the >enter< key once You will see something like:
IBC105A  DEFINE INPUT DEVICE. DASDI  7.92
HHC901I Enter input for console device 0009
to which you answer (by typing at the telnet console):
input=1442,00c
and again pressing the >enter< key once. The telnet console should now show:
MVSRES JOB   'INITIALIZE 3350 MVSRES VOLUME'
       MSG   TODEV=1052,TOADDR=009
       DADEF TODEV=3350,TOADDR=148,IPL=NO,VOLID=MVSRES,BYPASS=YES
       VLD   NEWVOLID=MVSRES,OWNERID=HERCULES
       VTOCD STRTADR=1,EXTENT=29
       END
Be patient, the system is now initializing the disk pack, and that will take a few minutes. When you see the message
IBC163A  END OF JOB.
IBC202A INTERV. REQUIRED  00C 02 0E00   4000 0000  0000

IBC154A  READY READER 00C.  DEPRESS INTERRUPT KEY.
then the disk is initialized, and you can now terminate the Hercules engine and the telnet client

INS0040 - Write IPL Text to MVSRES

Invoking the command script ins0040 will now (again) start the Hercules emulator, but with a different configuration file. This time, after the telnet client has connected, you will want to start the MVS starter system by entering

ipl 150
on the Hercules console!!. After a few seconds, the telnet session should show
IEA101A SPECIFY SYSTEM PARAMETERS FOR RELEASE 03.70.VS2
HHC901I Enter input for console device 001F
Now you enter
r 00,clpa
because this is the first IPL of the starter system. If you start the system at some later time, you can just press the >enter< key as a CLPA is not generally required then

After about a minute or two you should see

 IEF165I // START JES2
 IEE351I SMF SYS1.MAN RECORDING NOT BEING USED
*00 $HASP426 SPECIFY OPTIONS - HASP-II, VERSION JES2 4.0
To which you reply
r 00,format,noreq
Again, this is only required because this is the first time that JES2 gets started, and the spool dataset SYS1.HASPACE needs to be formatted. If you start the system later, you would enter
r 00,,noreq
Back to our IPL, though. A message will now be displayed
*01 $HASP436 REPLY Y OR N TO CONFIRM CHECKPOINT RECORD CHANGE
to which your reply is
r 01,y
Again, you need to be patient, JES2 is now formatting the SPOOL0 volume. When everything has been formatted, you will see
 IEE041I THE SYSTEM LOG IS NOW ACTIVE
 $HASP100 INIT     ON STCINRDR
 $HASP100 INIT     ON STCINRDR
 $HASP100 INIT     ON STCINRDR
 $HASP373 INIT     STARTED
 $HASP309    INIT  1 INACTIVE ******** C=A
 $HASP309    INIT  2 INACTIVE ******** C=BA
 $HASP309    INIT  3 INACTIVE ******** C=CBA
 $HASP373 INIT     STARTED
 $HASP373 INIT     STARTED
 $HASP099 ALL AVAILABLE FUNCTIONS COMPLETE
Also, Hercules will now feed a job with jobname sg0000 to the started JES.

You should now enter the following JES commands

$SPRT1
$PUNCH1
to enable printing/punching of job output.

After the job sg0000 has completed, you will find the output in the prt subdirectory with the name sg0000.lst

Running Sysgen Jobs

The JCL to be run for the system generation are in the jcl subdirectory. To submit a job, you have two possibilities:

  1. devinit 012 ../jcl/sg0000 eof
    on the Hercules console
  2. n b ../jcl/sg0000 eof
    on the semi-graphical Hercules console

Sometimes it is nice to see the JES2 assigned job numbers when diplaying MVS information via operator commands. You can achieve this by entering

$T OSC1,D=J
If you would also like to see a timestamp on every message, then enter
$T OSC1,D=T
instead

You might also consider to issue the MVS command

mn jobnames,t
which tells MVS to monitor and report on start and end of jobs.

All jobs that need to be run on the starter system have names beginning with sg followed by a number. Other jobs in the jcl directory will be run from the generated MVS system later

SG0010 - Prepare for Sysgen

The SMP4 that is distributed with MVS is unfortunately unfit for system generation!! Fortunately, a replacement is available. This job will copy it from a work file into the starter system's SYS1.LINKLIB. After this job is run, an IPL is required.

IPL - Pick up the new SMP4

As already mentioned an IPL is now required. No, don't press ctrl-alt-del yet! At the telnet screen enter the commands

$p
$pjes2
z eod
Then, at the Hercules console, enter
stop

We could now do an IPL. But, this time, we actually want to leave Hercules altogether, as we can now take the opportunity to compress the system residence. Leave Hercules by entering the command >exit< on the Hercules console, or by using the >W< command on the graphical Hercules console

Once Hercules is terminated, you will now have to run

INS0050 - Compress MVSRES

The script ins0050 will compress the mvsres system residence volume, but, just in case, will also place a backup copy of the uncompressed file into the snapshot subdirectory. The compressed file will have the name mvsres.148, and the archive with the uncompressed file will have the name mvsres_148_not_compressed.tgz.

_STARTSTART or INS0060 - Start the Starter System

The script file ins0060 has a twin, called _startstart (easier to remember). It can be used to start the MVS starter system. Remember that you will have to start a telnet client on port 3270 (using, on Linux, the tn script or the _starttelnet script)

SG0020 - Create Master Catalog

The MVS system to be generated needs a mastercatalog. We will place it on the system residence, and connect it to the starter system as a user catalog. Just run job sg0020 and see what happens...

SG0030 - Allocate DLIB files

The DLIB (=Distribution LIBrary files) contain the building parts out of which the target system (the MVS to be generated) will be built. We allocate empty DLIB files using job sg0030. Later, these files will be filled via SMP4. Therefore we need to initialize the SMP environment as well. If you run this job for the first time, expect an RC of 8 in the last step (SMP), if you repeat the job (for example, because you want to start all over), then this job should get a RC of 0

SG0040 - Receive product tape

Now we have to feed the product tape to SMP, which will unload the parts from the distribution tape and place it into temporary libraries on the MVSRES volume. (That is the volume that we specified on the TLIB parameter of the SMP4 procedure in job SG0010).

The distribution tape is in the file zdlib1.het, and you load the tape drive by entering

devinit 170 pathname/zdlib1.het
where pathname is the path to the directory containing the tape file. If you kept the the file in the tapes subdirectory (i.e. where the installation had placed it), the command would be
devinit 170 ../tapes/zdlib1.het
Now submit job sg0040. Be patient, this job has a lot to do, and it takes quite some time to complete!

Okay, so the long wait is over. What are we going to do now? Well, it is time for a snapshot.

INS0070 - Write Snapshot # 1

You have invested quite a big amount of time and effort so far. Wouldn't it be a shame to loose it all, just because, like, by accident you reran command file ins0010? Better safe than sorry, thus let us create a backup.

First shut down MVS and end the Hercules engine. Then invoke command file ins0070 which will use TAR and gzip to create several files in the directory snapshot.

A volume can be recovered from a snapshot using command script restsnapvol. The syntax is

       restsnapvol {snapshot} {volume}
                   !          !
                   !          +--- volume of disk to restore
                   +-------------- snapshot number (01, 02, etc)


Example:  restsnapvol 01 mvsres

to restore volume MVSRES from snapshot # 1

A complete snapshot can be restored command script restsnap. The syntax is

       restsnap {snapshot}
                !
                +-------------- snapshot number (01, 02, etc)

Example:  restsnap 01

to restore the complete snapshot # 1
After the snapshot is complete, you can now restart Hercules, the telnet client, and MVS

SG0050 - Receive product maintenance

No software product is without bugs. This is (especally) true for MVS. In the course of time fixpacks etc have been developed. IBM call the fixes PTFs. Ever wondered, what PTF stands for? Well, PTF = Program Temporary Fix . This tells you alot about software maintence, doesn't it?

Okay, some of the fixes are available to us. A Tape with accumulated PTFS is available, with the name of CUM003. Submit the jog sg0060, and a mount message will promptly appear on the MVS console. If you placed the AWS file into the tapes subdirectory (as recommended), you can now load the tape drive from the Hercules console by entering

devinit 170 ../tapes/cum003.het

The maintence on the tape will now be received. But wait - the job doesn't end, it asks for another tape via a mount message. What do you do now? Very simple: On the Hercules (Hercules, not MVS) console enter

devinit 170 ../tapes/uz61013.het
Soon, there will be a new mount message, to which you reply
devinit 170 ../tapes/uz71613.het
There will be a last mount message, and you supply
devinit 170 ../tapes/mvsptf1.het
All the maintenance currently available is now placed into the SMP environment.

Note that this job will have a return code of 8, as some PTFs appear twice, and SMP will record this as an error.

SG0060 - Receiving more Maintenance

On the MVSDLB volume there is a file called SYS2.SMPPTS which contains maintenance form a similar system, but from some time later. We will RECEIVE this maintenance in job sg0060 to have those PTFs available should we ever need them. A return code of 0 is expected for this job.

SG0070 - Install BTAM

For some compelling, SMP related reason it is necessary to install one specific product before all the others. Install in this moment means: Load the information from the SMPPTS and the SMPTLIBS (where they have been placed by the RECEIVE commands in SG0050-SG0080) onto the DLIB files on MVSRES.

This will be done using the ACCEPT command of SMP. Usually, though, a SYSMOD will not be ACCEPed right away, but needs to be put into the Target Sytem for testing first, which would be done via an APPLY command. But we do not have a target system in the moment. Therefore the parameter NOAPPLY on the ACCEPT command is required to tell SMP that the FMID should be ACCEPTed even though it has not yet been APPLYed.

If you don't want your SMP jobs to run forever, use DIS(WRITE) as an additional option on the ACCEPT command. This keeps the directory of the highly used PDS SYS1.SMPACDS in memory, instead of incurring gazillions of disk I/O operations. If things go wrong, though, your SMPACDS might be seriously broken... Guess why we did a Snapshot in the previous step!

SG0080 - Install BCP

The next job will install the BCP (=Base Control Program) plus a lot of related FMIDs (Functions) needed by MVS. This is a rather big job, and on my system (500 MHz, 256MB) it took about 3hours 20 minutes. Thus, have a break, watch the blinkenlights, and be patient

I also ran the same job under Linux on a 150MHz, 80MB Thinkpad. It was not exactly fast.....

INS0080 - Another Snapshot

After such a massive change to our system it might be a good idea to take another Snapshot. Just run command script ins0080, which puts new files into the snapshot directory. Don't throw away the previous snapshot files - you never know....

SG0090 - Install Networking

So far, everything has been rather straight forward. Now, we come to a difficult spot. Some of the FMIDs to be installed now may refuse to be installed, because a few IFREQ PTFS may be missing. This can be healed by also ACCEPTing UY49086, but this (at least on my system) breaks SVC94 (which is used for GTSIZE et al) and makes part of TSO (like TEST) unuseable. I do not know which PTF fixes UY49086, don't have the means to find out, and (probably) don't have the fixing PTF either. UY49086 also modifies SYSGEN for TCAM incorrectly (it will introduce a global variable &SGDTCAM that is referenced nowhere else). Instead of supplying the faulty PTF I leave it off altogether by specifiend BYPASS(IFREQ). If you prefer you can add UY49086 to the list of SYSMODS instead (and live with the consequences)

SG0100 - Install processor support

This one is really hairy. There are about 29 missing PRE or IFREQ SYSMODS, and there is nothing we can do about it right now. We will install the processor support group with BYPASS(IFREQ,ID) option to get a somewhat clean install. Expect a return code of 4 because of the BYPASS option.

SG0110 - Install JES2

The Job entry subsystem is straight forward in terms of installation. Just run job sg0110 and expect a return code of 0.

INS0090 - Time for Snapshot #3

We have completed the first phase of the sysgen process, the DLIB disk is now loaded. This is a perfect time for another snapshot. With other words, shut down MVS and the Hercules engine, and then run command script ins0050

SG0120 - Cleaning the house

The DLIBs are loaded, and we need room on the disk packs for the target libraries. We use SMP/4 to do some of the cleanup for us. If you run job sg0150 this will REJECT all the function SYSMODs. For ACCEPTed function SYSMODS this means that the SMPTLIB files (which were allocated on MVSRES) will be removed. Also, this job will run IEHPROGM with the SCRATCH VTOC function to remove all non-VSAM files from the MVSRES volume. You shold expect a return code of 4 for the first step, as the rejected function SYSMOD have not been APPLYed. There is a second step which cleans the MVSRES pack via a SCRATCH VTOC operation. You will get a RC=8 for this step, which is okay.

SG0130 - Allocate SYSGEN files

The SYSGEN process needs some datasets, which will be allocated in the job sg0130. Also, a new jobcard macro will be placed in SYS1.AGENLIB which includes a JOBCAT DD statement. This Job should end with an RC of 0.

SG0140 - Rebuild IFOX00

Sometimes the assembler provided by the starter system has the hiccups and randomly abends with S0C1 or S0C4. We have all the parts to build a new assembler, and that is exactly what SG0140 is doing. After this job has completed successfully (we expect RC=0) then you must shutdown MVS and Hercules! If you forget this, various abends (like S106-0E) may occurr.

INS0100 - Build Page Volumes

We will use two dedicated page volumes (3340) for our target system. Shutdown MVS and the Hercules engine. When Hercules has terminated, run command script ins0100, and two disk files (page00.160 and page01.161) will be added to your dasd subdirectory. Also two lines will be added to the end of the starter.conf configuration file

After this command script has completed, you should start Hercules and then IPL MVS again.

SG0150 - Sysgen, Stage 1

Finally! There are quite a few comments in the stage1 assembly deck, and I would recommend that you take a look at the deck before running job sg0150. A return code of 0 is expected, everything else is bad and needs to be investigated.

The IO Configuration can be viewed by clicking on one of the following links:

SG0160 - Get Stage1 output

The stage 1 of the previous job step has placed a large JCL stream into file SYS1.STAGE1.OUTPUT. Now go to the Hercules console and enter

devinit 13 ../jcl/stage2.pch ascii
before you run the job sg0160. This will place the JCL stream into file stage2.pch in the JCL subdirectory. Don't try to do something with this file, just run the command script

INS0110 - Build Stage2 Jobstream

Some modifications need to be done before the stage2 jobs can run. The easiest way to do this is running the script ins0110 which does the changes for you. If you want to see which changes are being done, take a look at conf/stage1.sed

SG0170 - remove target Libs

Sometimes, you need to start a sysgen stage2 process all over again. Then you might want to delete the target libraries, first. This is accomplished by jobs sg0170 for the full sysgen, and jobs sg0170_x (1 <= x <= 5) for sysgen jobs SYSGENx. Remember, you only need these jobs when restarting (a part of) sysgen process!!

The script ins0110has created the jobstream

SG0180 - Stage2

The real Stage 2. It is a sequence of 6 jobs to build the various MVS target libraries.

Note: The stage1 macros specify class C as the jobclass where the sysgen jobs are to run. The starter system has 3 started initiators, where only one has class C. This assures that the jobs run consecutively, not parallel

at the Hercules console enter the following command:

devinit 012 ../jcl/sg0210 trunc eof
(don't forget the trunc). Then take a break, because it will take some time to run the sysgen jobs.

SG0190 - Build JES2

Now everything is in place, nearly. We still have to build a JES system, but that is quite simple. Run the job sg0190, which Links JES2, sets up a JES2 procedure, and loads some simple JES2PARMS.

The job will also allocate a (rather small= spool dataset on MVSDLB. We will later expand the system by dedicating a full voume to the spool, but we will wait until we are certain that our generated system will start successfully)

SG0200 - Update SYS1.PARMLIB

A few changes are needed to SYS1.PARMLIB members. These changes will add SYS1.CMDLIB to LNKLST00, select a different IEAPAK00, etc. Run job sg0200 to implement the changes. After this job has completed, shutdown MVS and the Hercules engine.

INS0120 - Write Snapshot # 4

The actual System Generation is done (even though we need to do some customizing, still), and we should now do another snapshot (by running script ins0120.

_STARTMVS or INS0130 - Start the new MVS

Edit the script _startmvs or its twin ins0130 to start the 3270 client you want to use. You will at least need 3 sessions, 2 for console support, 1 for TSO. You will also need one telnet client. You should not IPL MVS until these clients have connected to Hercules

This is the first time MVS 3.8 is ipled, therefore an MVS CLPA is required, and later a spool formatting JES2 start.

During IPL with CLPA you will see the following messages:

| IEA101A SPECIFY SYSTEM PARAMETERS FOR RELEASE 03.8 .VS2
| r 00,clpa
| IEA357I ERRORS IN IEAPAK00 LIST
| IEA357I IGC0J05B INVALID - MODULE IGNORED
| IEA357I IGG08101 INVALID - MODULE IGNORED
| IEA357I IGG08102 INVALID - MODULE IGNORED
| IEA357I IGG08103 INVALID - MODULE IGNORED
| IEA357I IGG08104 INVALID - MODULE IGNORED
| IEA357I IGC11110 INVALID - MODULE IGNORED
| IEA357I IGC12110 INVALID - MODULE IGNORED
These are no errors, just information, and you can safely ignore them. After MVS is started there are three printers in the the system, at addresses 00E, 00F, and 30E. 30E is generarted as a hardcopy device while 00E and 00F are standard printers.

Issue the JES2 command

$T prt2,Q=Z
to make the second printer serve the output queue Z. This might be handy sometimes later.

At some time during startup you will see a message similar to

*$HASP190 DUMMY    SETUP -- PRINTER1 -- F = STD. -- C = 6    -- T = 0
When this setup message appears, you must start the corresponding printer, in this case by entering
$S PRINTER1

Having fun with your MVS? Well, we have some more work to do!

MVS SYSGEN is Complete

Customization

The basic system generation is complete, but we are no ways done yet. There are a lot of things left to do until the system is useable, like adding disk space, making TSO available, installing an editor and other utilities, etc.

Adding additional Volumes

The current system is a two volume system, where there is not much free space left for expansion. One of the consequences is that our spool dataset will fill up fairly quickly. Also, we will want to have work files, permanent storage for TSO users, Sort work areas, etc. With other words, we will need more disk space. Fortunately, this is not very complicated.

MVS0010 - Add VATLST00 to SYS1.PARMLIB

VAT stands for Volume Attribute List and allows automatic mounting of new disk volumes. We will create new disk volumes soon, therefore you should already run job mvs0010 to place a new VATLST00 into your SYS1.PARMLIB library.

Shut down MVS and the Hercules engine now. Then run

INS0140 - Build DASD Files

This script will build quite a few DASD image files in your ../dasd subdirectory. When it is complete, you will find the following

The script will also update the MVS.CONF file used for Hercules startup, such that the newly created disk files can be accessed by MVS.

Now you should start Hercules again, and then MVS. After MVS has completely initialzed, and JES2 was started, enter the MVS command

D U,DASD,ONLINE
on the MVS master console. You should get a result similar to this:
 d u,dasd,online
 IEE450I 16.17.17 UNIT STATUS 086                             C
 UNIT TYPE STATUS  VOLSER VOLSTATE   UNIT TYPE STATUS  VOLSER VOLSTATE
 130  2314 O       SORT00  PUB/RSDNT 131  2314 O       SORT01  PUB/RSDNT
 132  2314 O       SORT02  PUB/RSDNT 133  2314 O       SORT03  PUB/RSDNT
 134  2314 O       SORT04  PUB/RSDNT 135  2314 O       SORT05  PUB/RSDNT
 140  3350 O       WORK00  PUB/RSDNT 141  3350 O       WORK01  PUB/RSDNT
 148  3350 S       MVSRES PRIV/RSDNT 150  3330 O       SPOOL0  PUB/RSERV
 160  3340 A       PAGE00 PRIV/RSDNT 161  3340 A       PAGE01 PRIV/RSDNT
 240  3350 O       PUB000 STRG/RSDNT 241  3350 O       PUB001 STRG/RSDNT
 248  3350 A       MVSDLB PRIV/RSDNT
which sjows you the accessible volumes and their mount attributes.

We will make immediate use of the new volumes. Let us first make a dedicated Spool pack:

MVS0020 - Build a Spool Volume

The spool space on MVSDLB is very small, and we would run into problems if we wanted to use it in "real" work. This is where mvs0020 will help you - When this job is run, it will

When the job has completed, you need to stop JES2, and then restart it with the FORMAT option. you will see the following messages:
      STC    7  $HASP100 NET      ON STCINRDR
      STC    7  IEF452I NET      JOB NOT RUN - JCL ERROR
    - STC    7  $HASP396 NET      TERMINATED
      STC    7  $HASP150 NET      ON PRINTER2         7 LINES
     *STC    7 *$HASP190 NET      SETUP -- PRINTER2 -- F = 0001 -- C = 6    --
     * T = QN
      STC    8  $HASP100 TSO      ON STCINRDR
      STC    8  IEF452I TSO      JOB NOT RUN - JCL ERROR
    - STC    8  $HASP396 TSO      TERMINATED
Don't worry, there is nothing wrong with your system. There are commands to start VTAM and TSO, but we haven't actually setup those two components yet (but will do so shortly)

Which changes were implemented to JES2PARMS? You might want to look at the member in SYS1.PARMLIB. The main changes are:

MVS0030 - Remove spool from MVSDLB

The new spool is working, we now can remove the spool space from MSDLB. This is done by running job mvs0030. We are now ready to build VTAM and TSO:

VTAM and TSO

MVS0040 - Allocate files

Just run this job. When it is completed, some new files have been created, and some members the SYS1.PARMLIB have been updated. The following files were created:

The JES2 proc has been amended to reflect the new proclib, and the LNKLST00 has been updated to contain CMDLIBs and SYS2.LINKLIB.

Following procedures have been added to SYS2.PROCLIB:

You need now to re-Ipl MVS. The CLPA option is not required.

MVS0050 - Build VTAM and TSO Libraries and Procs

A straight forward affair. Just run this job, and it will create Libraries and LOGON procedures for you:

The LOGON Interpret Table BSPLIN01 contains references to the users IBMUSER, HERC01, and HERC02. You will just have to enter these names to LOGON to TSO. Other TSO users will have to use the LOGON command, i-e they will have to enter
logon someone
to logon to TSO using the userid "someone"

MVS0060 - Assemble VTAM Tables

which will assemble Logon Interpret Table, Logmode Table, and USSTAB. After this is done, you will want to

Start VTAM

Go to the MVS console, and enter

s net
You should see messages similar to the following:
    - STC   19  $HASP373 NET      STARTED
    - STC   19  IEF403I NET - STARTED - TIME=17.44.23
      STC   19  IST025I  BLDL FAILED FOR ISTYTCM1 IN VTAMLIB
      STC   19  IST126I  ISTYTCM1 MODE NOT SUPPORTED DUE TO LOADING FAILURE
      STC   19  IST025I  BLDL FAILED FOR ISTYTCM2 IN VTAMLIB
      STC   19  IST126I  ISTYTCM2 MODE NOT SUPPORTED DUE TO LOADING FAILURE
      STC   19  IST025I  BLDL FAILED FOR ISTYTCM3 IN VTAMLIB
      STC   19  IST126I  ISTYTCM3 MODE NOT SUPPORTED DUE TO LOADING FAILURE
      STC   19  IST110I  NETWORK SOLICITOR STARTED
      STC   19  IST093I  APPLTSO  ACTIVE
      STC   19  IST093I  APPLCICS ACTIVE
  00  STC   19  IST093I  LCLMAJ00 ACTIVE
      STC   19  IST020I  VTAM INITIALIZATION COMPLETE
The ISTYTCMx modules belong to TCAM, which we have not generated, and can be ignored. When VTAM is initialized, enter
s tso
to which the system should reply
    -           s tso
      STC   20  $HASP100 TSO      ON STCINRDR
    - STC   20  $HASP373 TSO      STARTED
    - STC   20  IEF403I TSO - STARTED - TIME=17.46.08
  00- STC   20  IKT007I TCAS ACCEPTING LOGONS
    - STC   20  IKT005I TCAS IS INITIALIZED
After the message TCAS IS ACCEPTING LOGONS appears, you can now logon using the IBM supplied userid IBMUSER. How? Go to a 3270 session that displays


THIS TERMINAL IS LOGGED ON TO THE NETWORK SOLICITOR

and in the top row enter
ibmuser size(4096)
Note: The default size for IBMUSER is 44K, which is enough for running ACCOUNT, but not for running anything else. If logon worked, just enter LOGOFF again. We are going to create new TSO users in a minute

MVS0070 - Build Usercat for TSO Users

We do not want all the files for specific TSO users to be cataloged in the MVS master catalog. Therefore we build a usercat on volume PUB000 for all the TSO related files. Run job mvs0070

MVS0080 - Build Control Datasets etc

We need a file containing skeleton for commands to make certain tasks (like creating users) easier. Job mvs0080 builds two files for use in a TSO environment:

The skeletons in above dataset assembler PUNCH statements with references to the assembler SYSPARM variable. You can see in the next job how this is being used. The Job will also place two command lists into SYS1.PROCLIB:

MVS0090 - Add TSO Users

You might want to modify mvs0090 before running it to suit your needs. AS written it will add four users to the system

Your userids are now defined, and ready to use.

Shutting down for Snapshot # 5

It is time for another snapshot. We need to shutdown MVS again, but this time we first have to stop tso and net.

At the MVS console enter the command

p tso
if there are still users active, you will see a message like
  00-           p tso
     *STC   22 *03 IKT010D 00001 USERS ACTIVE, REPLY 'SIC' OR 'FSTOP'
to which you reply
r xx,FSTOP
if there are no (more) active users, you will see the message
    *STC   22 *04 IKT012D TCAS TERMINATION IN PROGRESS - SPECIFY 'U' OR 'DUMP'
to which you need to reply
r xx,u
TSO will now terminate. You can now terminate VTAM with one out the the following three commands
z net
z net,quick
z net,cancel
Eventually, you will see the message
      STC   21  IST102I  VTAM IS NOW INACTIVE
    - STC   21  IEC223I IFG0200V,NET,NET,UNKNOWN
  00- STC   21  $HASP395 NET      ENDED
and now you can terminate JES in the usual way
$P
$PJES2
Z EOD

INS0150 - Take Snapshot # 5

This snapshot will NOT save all the dasd image files you have. It will only save

We use START1.150 and SPOOL0.151 as an emergency system, and therefore keep saving them in the snapshot. The other DASD image files, WORK*, SORT* etc are not saved. It is your responsibility to devise backup mechanism for them if you need them.

When you now start Hercules, and MVS, you will possibly see a message

  *STC   31 *01 IKT003D TCAS UNABLE TO ACCEPT LOGONS, REASON CODE=0092 REPLY
  * 'RETRY' OR 'TERM'
This happens because TSO starts up faster than VTAM. When VTAM has initialized, enter
r 01,retry
and then TSO will connect to VTAM.

Complete the SMP/4 Environment

MVS0100 - Build SMP Procedures

This jobs builds a few procedures in SYS1.PROCLIB fro SMP4 processing:

Just run this job, no modifications are necessary, and no problems are expected.

MVS0110 - Build SMP Libraries

In order to use SMP/4 on the target system we need the SMP/4 target libraries. The job mvs0100 will allocate the files, and copy the contents of the DLIB SMP libraries into the newly created files.

Note: This job takes a long time, and uses quite a bit of CPU cycles. In order to avoid S322 abends on somewhat slower machines, I have added a TIME=1440 parameter to JOB and EXEC JCL statements

MVS0120 - Run JCLIN

The stage2 job contains the building instructions for making our MVS system. Performing a JCLIN process as in mvs0120 will feed these instructions into SMP/4. SMP will then be able to rebuild elements of the MVS system

MVS0130 - Install Usermod

To test the SMP/4 environment we will install a simple usermod which will authorize some external commands to TSO. We will install these commands later, for now we will be happy when the usermod gets correctly installed. Just run the job mvs0130 and check that the module IKJEFTE2 gets linked correctly.

MVS0140 - Building a private Maclib

For the next activity we need some private macros. Just run this job to load the macros into SYS2.MACLIB

MVS0150 - Install another Usermod

Well, this was simple. Now to a more complex adventure: A usermod that relinks the the master scheduler. If this works, we can be rather sure that our sysgen process was successful. The job mvs0150 will assemble the element IEFACTRT and will ask SMP/4 to put it into our MVS. After the job has finished, SMP/4 should have relinked module IEFW21SD.

What does IEFACTRT do? It will put a job step completion summary in the top of the job log. No need for hunting for the many COND CODE lines any more.... Also, IEFACTRT does some step accounting. I used some numbers from 20 years ago to give you an idea how much you would have to pay for running MVS jobs if this wouldn't be your private PC.....
You will see its action after the next IPL with the CLPA option. Therefore - shutdown TSO, NET, MVS and re-IPL with CLPA

MVS0160 - Install an APAR

When user log off from TSO, you will see an error message IEC233I for IGV0200V. Peter Vander Woude has located an error resolution in the IBM service databases. The relevant PTF is unfortunately no longer available, but he copied the information from the APAR AZ58122 and made it availble. The job mvs0170 will use SMP/4 to install this fix. After installing it, an IPL with CLPA is required.

Addtional Software

MVS is up and running, The network is up, TSO is working - what more do we want? Well, there are dozens of little helper programs that can make your life easier when using TSO. Many of these can be found on the so called CBT-Tape and/or CD-ROM. They are available in source code, and you might need to customize them before being able to use them.

Preparing to build TSO Command Processors

Some of the utilities are rather bulky (in terms of size of source code), while others are rather small. For these small utilities we create a source file, and also a set of procedures to assembles (and link) the TSO commands into SYS2.CMDLIB.

TSO0010 - ALLOC CP source file

The tso0010 job creates a file SYS1.TSOCP.ASM to contain source for TSO command processors, and two procedures in SYS2.PROCLIB:

TSO0020 - Assemble and link a tiny TSO command

The job tso0010 assembles and links a tiny TSO command, called CLRSCRN. It can be used to clear the screen of a 327x display terminal (Don't ask me why IBM hasn't provided such a command as part of the TSO package - they jsust didn't!). Run this job to see if the command gets compiled correctly, and then log on to TSO to test it. Oh, CLRSCRN is too much of typing for you? The command has more than one name, pick the one you like most:

TSO0030 - Load some TSP utilities

The job tso0030 loads a few TSO utilities from tape into SYS2.CMDLIB. When you run it, you must provide the tape file BSP001.HET (which is located in the tapes subdirectory). The following commands will be installed (together with help members in SYS2.HELP:

ASM
An Assembler Prompter
DENQ
Displays ENQ conflicts
DSAT
Displays data set attributes
DSPACE
Displays free space on volumes
DSN
Alias of DENQ
DVOL
Displays mounted volumes
FREEALL
Frees all dynamically allcated files
HEL
Full Screen HELP command
REVIEW
Full Screen BROWSE program
RLSE
Release empty space from data set

RPF - Rob's Programming Facility

One thing is dearly missing in our MVS system: SPF. Unfortunately, SPF is a licenced IBM software product, and there is little chance of legally getting a copy of it to run on MVS 3.8 and Hercules.

But there is a silver lining on the horizon: Rob Prins has written a full screen editor that is somewhat SPF alike.

There is a RPF User's Guide in your doc directory. RPF is rather easy to implement:

RPF0010 - Allocate RPF Files

This job will build some files (including the RPF source) on the PUB000 volume. Read the JCL and the comments and make all the changes needed for your system, then run the job. It will need the RPF product tape, which should be in

../tapes/rpf130.het

RPF0020 - Copy RPF to SYS2.CMDLIB

This job will copy the RPF load modules into SYS2.CMDLIB. This has the advantage that

RPF0030 - Build RPFKEY01

RPF needs a member in SYS1.PARMLIB for customization info. This member is built by job rpf0030. After this job is complete, RPF can be invoked from the TSO command prompt.

Q - A Queue Manager

Don't you just miss SDSF? Well, we don't have the source for it and can't build it. but there is this thing called CBT Tape, which is very useful. Among others I found the program QUEUE, aka QUE, aka (you guessed it) Q. It allows you to look at the contents of the spool, browse output datasets, Syslog, etc. It is not as comfortable as SDSF, but much better than the OUTPUT command

QUE0010 - Build Q libraries

Just run this job. It will place the Q source into your system. You may want to invoke RPF and look into JES2.QUEUE.ASM. There are two members where you might want to do some customization: QCOMMON and QSTART. Read the comments in those members on where modifications might be required.

If you kept the names as suggested in this article you will not need any changes and can immediately compile queue by either submitting member COMPILE from the JES2.QUEUE.ASM dataset or by running job

QUE0020 - Assemble and link Q

This job will run a series of assemblies (35 altogether). Each and everyone should get a RC=0, if not, the jobstream aborts on the first non-zero return code. After all assemblies are done, the program is linked into SYS2.CMDLIB

In order to see which functions are available, press PF1 to show the first help screen. When you press the ENTER key, the next help screens will be displayed

FSE - A Full Screen Editor

RPF is great - but it has one drawback! It only allows editing of fixed length datasets. Varying length records are not supported. If you need those, you might consider installing FSE - the Full Screen Editor.

INS0160 - Update FSE installation

Open the file fse.sed in the directory conf. It contains control statements for the sed utility. Follow the comments and instructions and change this member to fit your needs, then save it.

Now run command script ins0160. When this has finished, two new jobs will have appeared in your jcl directory:

FSE0010 - Build FSE libraries

Run this job unchanged, and it will create the FSE libraries on your system. After it has completed, run

FSE0020 - Assemble and link FSE

Which does a bunch of assemblies and links, all of which should be successful. Note, that an SVC will be linked into SYS1.LPALIB. This means that you cannot use FSE until you have done an IPL with the CLPA option.

The CBT Tape - Readily Available on DASD

If you do not know, what the CBT tape is - go to http://www.cbtorg.com to find out more. For MVS S3.8 the older CBT tapes are really interesting, as opposed to the newer ones, which use such new-fangled stuff as 31 bit addressing, weird set of additional registers, etc. etc. p. p.

I have created three 3350 disk volumes packed with PDS datasets containing the files from the following CBT tapes (in reverse chronological order) On these three volumes, there are two user catalogs, which you just need to import to your systems master catalog, to gain access to the files. The file names are:

INS0170 - Unpack CBT volumes

If you haven't done so already, shut down MVS and the Hercules engine. Then run ins0170,

This installation script will unpack an archive and add 3 volumes to your MVS configuration file:

When unpacking is complete, restart Hercules and MVS to make sure that you can access the newly created disk packs. Then run

CBT0010 - Import CBT Catalogs

This job will import and connect the two CBT catalogs on the CBT volumes, and will define the three high level qualifiers used so far:

From now on, you can directly access the source of any provided utility (perhaps via RPF) and do whatever you want to do with it.

Compilers and Utilities

Now the MVS System is somewhat useable. But - useable for what? Do you want to develop applications? Well, no problem. You can use any language you like, as long as it is assembler.... What if you are mpre fluent in another language? The MVS distribution does not contain any other languages, but the OS/360 distribution does. We can salvage parts of OS/360 and place it into MVS. This work has been done by Jay Moseley, and I have reproduced it here for the sake of completenes. His original work can be found at his page Compilers for MVS 3.8

COBOL

LNG0010 - Load COBOL from tape

Running job lng0010 will load the COBOL libraries and procedures to your MVS system

LNG0040 - Testing COBOL

Running job lng0040 will compile, link, and run a COBOL "Hello World" program to test successful implementation

FORTRAN

Two FORTRAN compilers are available, FORTRAN G and FORTRAN H. You get both by running

LNG0020 - Load FORTRAN from tape

Running job lng0020 will load the FORTRAN libraries and procedures to your MVS system

LNG0050 - Testing FORTRAN

Running job lng0045 will compile, link, and run FORTRAN "Hello World" programs to test successful implementation of both compilers

PLI

LNG0030 - Load PL1 from tape

Running job lng0030 will load the PL1 libraries and procedures to your MVS system

LNG0060 - Testing PL1

Running job lng0060 will compile, link, and run a PL1 "Hello World" program to test successful implementation of the compiler

SORT

A discussion of the sort parameters etc can be found in the Sort User's Guide manual.

SORT010 - Load SORT from tape

Running job sort010 will load the sort libraries to your MVS system

SORT020 - Testing SORT

Running job sort020 will sort a file of 500 records to test successful implementation of the sort program

INS0180 - Snapshot # 6

Shut down MVS and the hercules engine, and then run ins0180 to create the snapshot # 6. This is the last snapshot for this installation. If you are satisfied with this build of the MVS system, you can delete the earlier snapshots to reclaim some disk space.

Enjoy your private Mainframe

Installation checklist

Command
or JCL file
Expected RCRemarks
ins00100Build starter system
ins00200Build DASD image files
ins00300Init MVSRES
ins00400Write IPL Text
ins00500Compress MVSRES
ins00600IPL Starter system
sg00100Prepare for Sysgen
n/an/aIPL
sg00200Create Master Catalog
sg0030First time: 8
else: 0
Allocate DLIBs
sg00400RECEIVE Product tape
ins00700Snapshot # 1
sg00508RECEIVE Maintenance
sg00600RECEIVE More Maintenance
ins00300Snapshot # 1
sg00700ACCEPT EBT1102
sg00800ACCEPT BCP
and major FMIDs
ins00800Snapshot # 2
sg00904ACCEPT Networking
sg01004ACCEPT MVS Processor support
sg01100ACCEPT JES2
ins00900Snapshot # 3
sg0120Step1: 4
Step2: 8
Cleanup SMPTLIBs
sg01300Allocate Sysgen file
sg01400Rebuild IFOX00
ins00600Build Page Volumes
sg01500Sysgen Stage1
sg01600Get Stage1 output
sg0170./.Remove Target Libs
sg01800 for most steps
4 for some link-edit steps
Sysgen Stage 2
sg01900Build JES2
sg02000Update SYS1.PARMLIB
ins01200Snapshot # 4
_startmvs
ins0130
0Start MVS
mvs00100Add VATLST00 to SYS1.PARMLIB
ins01400Build DASD Image files
mvs00200Add Spool Volume to HASP
mvs00300Remove spool space from MVSDLB
mvs00400Allocvate additional files
mvs00500Build VTAM and TSO libraries and procedures
mvs00600Assemble VTAM tables
mvs00700Build TSO user catalog
mvs00800Build user control dataset
mvs00900Add TSO Users
ins01500Snapshot # 5
mvs01000Build SMP Procedures
mvs01100Build SMP Libraries
mvs01200Run JCLIN
mvs01300Install Usermod ZUM0001
to authorize Q
mvs01400Build private MACLIB
mvs01500Install Usermod ZUM002
SMF Exit IEFACTRT
to authorize Q
mvs01500Install Usermod ZUM002
SMF Exit IEFACTRT
to authorize Q
mvs01000Build Q Libraries
mvs01100Assemble/Link Q
ins00800Update FSE Installation
fse00100Build FSE libraries
fse00200Assemble/Link FSE
fse00300Create FSE user
ins00900Checkpoint # 4
sg00700RECEIVE Even More Maintenance
sg00800LIST SMPPTS file
sg01400Test for acceptable SYSMODs
ins01800Snapshot # 6

If I managed to confuse you with these instructions, just drop me a line.

Enjoy your private Hercules mainframe




© BSP Beratung, Schulung, Projekte GmbH

SG0250 (optional) - Check for PTFs

You don't have to run this job, but it doesn't cost too much, either. It will ACCEPT CHECK all SYSMODs that have not been ACCEPTed so far (except for UY49086, which I don't like and which is excluded explicitly).