1. Introduction

Co:Z Batch is an IBM z/OS batch utility program that allows a Unix command or shell to be executed in a batch job step. As an alternative to confusing IBM utilities such as BPXBATCH, Co:Z Batch is designed to simplify the integration of z/OS Unix with batch jobs.

1.1 Features

  • Executes the Unix program or shell in the same address space, which simplifies job accounting and allows for the use of resources such as DD statements by the Unix program.

  • STDIN, STDOUT, and STDERR files from the Unix program are redirected to DD statements, which may refer to MVS datasets or spool files.

  • If not specified, the default Unix program to run is the user's default login shell.

  • Environment variables may be set using a STDENV DD, or passed in via JCL PARM=. Multiple COZBATCH steps may be used together to pass JCL variables into Unix environment variables, so as to avoid the limits imposed by 100-character PARM= fields.

  • If a program is run directly, its name and arguments are given in JCL PARM= and program arguments support quoting.

  • The Unix program or shell exit code is used as the step return code, but this may be overridden by a PARM setting.

  • JES Symbols are automatically exported as environment variables to the target shell or program with JES_ prefixes on the symbol names. Requires z/OS 2.1 or later.

Table 1.1. Features Comparison

FeatureBPXBATCHBPXBATSLAOPBATCHCOZBATCH
Same address spacenoyesyesyes
STDOUT/STD to dataset/sysoutyes (1.7+)yes (1.7+)yesyes
STDIN from dataset/sysinnonoyesyes
Run a default login shellyesno (unless root)noyes
Run a Unix command without a shellyesyesyesyes
Set ENV vars from JCL varslimited [1] limited [1]limited [1]yes
PARM= args support quotingnonoyesyes
Override(set) step return codenononoyes
Support for JES Symbolsnononoyes

[1] One or more ENVAR() LE runtime options may be specified on the PARM to set environment variables using JCL variables.

The size of the entire PARM field is limited to 100 characters.


1.2 Trademarks

  • Co:Z® is a trademark of Dovetailed Technologies LLC.

  • z/OS® is a trademark of IBM Corporation.


Saint Charles, Missouri
info@coztoolkit.com
+1 636.300.0901

Copyright© 2009 - 2023 Dovetailed Technologies, LLC. All rights reserved. Co:Z® is a registered trademark and Co:Z Toolkit™ is a trademark of Dovetailed Technologies, LLC.

Saint Charles, Missouri
info@coztoolkit.com
+1 636.300.0901

Copyright© 2009 - 2023 Dovetailed Technologies, LLC. All rights reserved. Co:Z® is a registered trademark and Co:Z Toolkit™ is a trademark of Dovetailed Technologies, LLC.