Previous Topic Next topic Print topic


Support for Multiple Catalogs

Typically, just one catalog is used to hold the information about all datasets used in a batch region. You can use more catalogs in the following scenarios:

Using two catalogs with SMS DATACLAS support

If SMS DATACLAS support is enabled, you can have two catalogs. The second catalog can only store the DATACLAS information - see Using SMS Data Classes.

Using multiple catalogs

You can enable multiple catalogs (up to 32) where each additional catalog holds the information about certain datasets. These are called user catalogs and each one of them holds the information for datasets that start with a particular node name.

For example, one catalog can store a number of datasets all of which start with the node name 'ABCD'. Another catalog would store a different group of datasets, all of which start with the node name 'WXYZ'.

When the main catalog module (MVSCATIO) of Enterprise Server, requests the information for a dataset, it first inspects the dataset name. If the name matches one of the defined additional catalog nodes, it looks in that catalog data file (this, usually, is catalog.dat) for the information for that dataset.

To enable multiple catalogs in Enterprise Server and to configure which dataset is held in each catalog, you must set the following two environment variables:

  • MFUSERCAT_NODE - this variable holds the node name of each dataset that should be stored in a separate catalog.
  • MFUSERCAT_LOC - this variable specifies the location of each user catalog.

Both variables are required and can store multiple entries separated by a semi-colon (;). A value specified for MFUSERCAT_NODE must have a corresponding value in MFUSERCAT_LOC. See Example of using multiple catalogs further down in this topic.

Other methods

You can define different locations for the datasets. For example, to direct a location to a Fileshare server, specify $$FS_NAME in the location, where FS_NAME is the name of your Fileshare server.

You can use an allocation override rule to combine these different catalog locations and to store the datasets in different locations - see Controlling where Datasets are Created for more details.

For example, the following allocation rule places the datasets that start with 'ABCD' into C:\ABCD\DATA:

rule:
	- condition:	dsname1
	  value:		ABCD
	SUBDIRECTORY:	C:\ABCD\DATA\

Using this facility, you can also separate the spool files into a catalog other than the main one, and put the spool files in a different location. See Separating the Spool files from the Main Catalog.

If you use another special dataset indicator 'MVSSPOOL' in the MFUSERCAT_NODE, you can direct the catalog spool entries to the corresponding catalog location specified in MFUSERCAT_LOC.

Example of using multiple catalogs

Consider the following example, where you might have some datasets that start with 'ABCD' that should go into a catalog at C:\ABCD\CATALOG.DAT. Other datasets that start with 'WXYZ' should go into C:\WXYZ\CATALOG.DAT. Also, you might want to enable DATACLAS support and have an SMS catalog at C:\MAIN\SMS.DAT.

The MFUSERCAT_NODE variable must include the SMS catalog, known as SYSMFE1, the ABCD catalog and the WXYZ catalog:

MFUSERCAT_NODE=SYSMFE1;ABCD;WXYZ

MFUSERCAT_LOC, respectively, must include the corresponding locations for these catalog:

MFUSERCAT_LOC=C:\MAIN\SMS.DAT;C:\ABCD\CATALOG.DAT;C:\WXYZ\CATALOG.DAT

Sample allocation override rule file

The following example shows an allocation override rule file that directs datasets, including spool files and SYSIN files, to different locations. This sample uses a Fileshare server (called CATSERVER) for the main catalog and another one (called SPOOLSERVER) for the spool files.

#   =========================================================================
#                           M I C R O   F O C U S
#
#   =========================================================================
#                        DATASET ALLOCATION OVERRIDE
#                             EXAMPLE RULES FILE
#                        ===========================


# This example rule file shows some rules for defining dataset locations based on the
# catalog properties of the dataset.


# Copyright (C) 2016 Micro Focus

# Use the following rule to define where the spool files are created:

RULE:
# ALL SPOOL files go to the SPOOLSERVER
	- CONDITION:	RECORDTYPE
	  VALUE:		S
	SUBDIRECTORY:	$$SPOOLSERVER\SPOOL\
---

# Rules based on dataset name and properties:

rule:
	- condition:	dsname1
	  value:		ABCD
	  
	  
	SUBDIRECTORY:	C:\ABCD\DATA
---

rule:
	- condition:	dsname1
	  value:		WXYZ
	  
	  
	SUBDIRECTORY:	C:\WXYZ\DATA
---

# VSAM files go to the CATALOG server:
RULE:
    - CONDITION:    DSORG
    VALUE:          VSAM
    SUBDIRECTORY:   $$CATSERVER\VSAM\
---

# In-stream SYSIN file format - send to spoolserver
# MFE2015.S0508.S141108.J02351.D00006.SYSIN.DAT
# This must be placed before the more general PS rule below:

rule:
	- condition:	dsname1
	  value:		MFE*
	  
	- condition:	dsname2
	  value:		S*

	- CONDITION:    DSNAME3
	  VALUE:        S*
	
	- condition:    DSNAME4
	  VALUE:        J*
	  
	- CONDITION:    DSNAME5
	  VALUE:        D*
	  
	- CONDITION:    DSNAME6
	  VALUE:        SYSIN
	  
	SUBDIRECTORY:	$$SPOOLSERVER\SPOOL\

---	


# PS files go to the CATALOG server:
RULE:
    - CONDITION:    DSORG
    VALUE:          PS
    SUBDIRECTORY:   $$CATSERVER\DATA\
Previous Topic Next topic Print topic