I wrote simple programm to run REXX script across Java:
import java.io.IOException;
import java.util.Iterator;
import java.util.List;
import java.util.Properties;
import com.ibm.jzos.Exec;
import com.ibm.jzos.RcException;
import com.ibm.jzos.ZUtil;
public class CallRexx {
public static final String JOB_STATUS_CMD = "jobStatus";
public static void main(String[] args) {
Exec exec=null;
try{
exec = new Exec("/u/DAINEK/MvsSubmitJob2/jobStatus TCPIP STC05618", getEnvironment());
exec.run();
String line = exec.readLine();
System.out.println("line=" + line);
List lst = exec.getErrorLines();
Iterator it=lst.iterator();
while(it.hasNext())
{
String value=(String)it.next();
System.out.println("Value ="+value);
}
int rc = exec.getReturnCode();
if (rc != 0) {
System.out.println("RC ="+rc);
}
}catch(Exception e){
System.out.println("[b]exec.run catch failed![/b]");
e.printStackTrace();
//System.exit(8);
}
}
protected static String[] getEnvironment() {
Properties p = ZUtil.getEnvironment();
p.put("_BPX_SHAREAS", "YES");
p.put("_BPX_SPAWN_SCRIPT", "YES");
String[] environ = new String[p.size()];
int i = 0;
for (Iterator<Object> iter = p.keySet().iterator(); iter.hasNext();) {
String key = (String)iter.next();
environ[i++] = key + "=" + p.getProperty(key);
System.out.println("environ(" + (i-1) + ")=" + environ[i-1]);
}
return environ;
}
}
And create JCL:
//IASOUT JOB
//JAVA EXEC PROC=JVMPRC61,
// JAVACLS='CallRexx',
// LOGLVL='+T'
//IN1 DD DSN=DAINEK.TAPE,DISP=SHR
//STDENV DD *
set -x
. /etc/profile
export JAVA_HOME=/usr/lpp/Java601_31/J6.0.1
export PATH=$PATH:/bin:"${JAVA_HOME}"/bin:/u/DAINEK/MvsSubmitJob2 //Try to find Rexx script jobStatus.
LIBPATH=/lib:/usr/lib:"${JAVA_HOME}"/bin
LIBPATH="$LIBPATH":"${JAVA_HOME}"/lib/s390
LIBPATH="$LIBPATH":"${JAVA_HOME}"/lib/s390/j9vm
LIBPATH="$LIBPATH":"${JAVA_HOME}"/bin/classic
export LIBPATH="$LIBPATH":
APP_HOME=$JAVA_HOME
CLASSPATH=$APP_HOME:"${JAVA_HOME}"/lib:"${JAVA_HOME}"/lib/ext
for i in "${APP_HOME}"/*.jar; do
CLASSPATH="$CLASSPATH":"$i"
done
export CLASSPATH="$CLASSPATH":
IJO="-Xms16m -Xmx128m"
export IBM_JAVA_OPTIONS="$IJO "
export CLASSPATH="$CLASSPATH":/u/DAINEK/MvsSubmitJob2
And create REXX script:
say 555
Then I submit JCL and get SYSOUT:
JVMJZBL2004N Log level has been set to: T
JVMJZBL2999T -> JzosVM()
JVMJZBL1001N JZOS batch Launcher Version: 2.4.0 2010-11-16
JVMJZBL1002N Copyright (C) IBM Corp. 2005. All rights reserved.
JVMJZBL2999T <- JzosVM()
JVMJZBL2999T -> run()
JVMJZBL1029I Region requested = 0K, Actual below/above limit = 11M / 1719M
JVMJZBL1053I OS Release R23.00 Machine 2827
JVMJZBL2999T -> adoptEnvironment()
JVMJZBL2999T -> spawnChild()
JVMJZBL1036D Spawned child shell process with PID: 65711
JVMJZBL2999T <- spawnChild()
JVMJZBL2999T Writing shell script to child's stdin:
JVMJZBL2999T set -x
JVMJZBL2999T . /etc/profile
JVMJZBL2999T export JAVA_HOME=/usr/lpp/Java601_31/J6.0.1
JVMJZBL2999T export PATH=$PATH:/bin:"${JAVA_HOME}"/bin:/u/DAINEK/MvsSubmitJob2
JVMJZBL2999T LIBPATH=/lib:/usr/lib:"${JAVA_HOME}"/bin
JVMJZBL2999T LIBPATH="$LIBPATH":"${JAVA_HOME}"/lib/s390
JVMJZBL2999T LIBPATH="$LIBPATH":"${JAVA_HOME}"/lib/s390/j9vm
JVMJZBL2999T LIBPATH="$LIBPATH":"${JAVA_HOME}"/bin/classic
JVMJZBL2999T export LIBPATH="$LIBPATH":
JVMJZBL2999T APP_HOME=$JAVA_HOME
JVMJZBL2999T CLASSPATH=$APP_HOME:"${JAVA_HOME}"/lib:"${JAVA_HOME}"/lib/ext
JVMJZBL2999T for i in "${APP_HOME}"/*.jar; do
JVMJZBL2999T CLASSPATH="$CLASSPATH":"$i"
JVMJZBL2999T done
JVMJZBL2999T export CLASSPATH="$CLASSPATH":
JVMJZBL2999T IJO="-Xms16m -Xmx128m"
JVMJZBL2999T export IBM_JAVA_OPTIONS="$IJO "
JVMJZBL2999T export CLASSPATH="$CLASSPATH":/u/DAINEK/MvsSubmitJob2
JVMJZBL1005I Output from DD:STDENV config shell script:
JVMJZBL2999T + . /etc/profile
JVMJZBL2999T + PS1=$LOGNAME:$PWD: >
JVMJZBL2999T + export PS1
JVMJZBL2999T + TZ=GMT-3
JVMJZBL2999T + export TZ
JVMJZBL2999T + LANG=C
JVMJZBL2999T + export LANG
JVMJZBL2999T + readonly LOGNAME
JVMJZBL2999T + PATH=/bin:.
JVMJZBL2999T + export PATH
JVMJZBL2999T + export PATH=/usr/lpp/Printsrv/bin:/bin:.
JVMJZBL2999T + LIBPATH=/lib:/usr/lib:.
JVMJZBL2999T + export LIBPATH
JVMJZBL2999T + export LIBPATH=/usr/lpp/Printsrv/lib:/lib:/usr/lib:.
JVMJZBL2999T + NLSPATH=/usr/lib/nls/msg/%L/%N:/usr/lib/nls/msg/%L/%N.cat
JVMJZBL2999T + export NLSPATH
JVMJZBL2999T + export NLSPATH=/usr/lpp/Printsrv/%L/%N:/usr/lib/nls/msg/%L/%N:/usr/lib/nls/msg/%L/%N.cat
JVMJZBL2999T + MANPATH=/usr/man/%L
JVMJZBL2999T + export MANPATH
JVMJZBL2999T + export MANPATH=/usr/lpp/Printsrv/man/%L:/usr/man/%L
JVMJZBL2999T + MAIL=/usr/mail/
JVMJZBL2999T + export MAIL
JVMJZBL2999T + umask 022
JVMJZBL2999T + export PATH=/usr/local/bin:/usr/lpp/Printsrv/bin:/bin:.
JVMJZBL2999T + export JAVA_HOME=/usr/lpp/Java601_31
JVMJZBL2999T + export STEPLIB=DSNA10.IAS.SDSNEXIT:DSNA10.SDSNLOAD:DSNA10.SDSNLOD2:
JVMJZBL2999T + export PATH=/usr/lpp/db2810/jcc/bin:/usr/local/bin:/usr/lpp/Printsrv/bin:/bin:.
JVMJZBL2999T + export LIBPATH=/usr:/usr/lib:/usr/lpp/db2810/jcc/lib:/usr/lpp/Printsrv/lib:/lib:/usr/lib:.
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar:/usr/l
pp/mqm/V6R0M0/java/lib/jms.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar:/usr/l
pp/mqm/V6R0M0/java/lib/jms.jar:/usr/lpp/mqm/V6R0M0/java/lib/rmm.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar:/usr/l
pp/mqm/V6R0M0/java/lib/jms.jar:/usr/lpp/mqm/V6R0M0/java/lib/rmm.jar:/usr/lpp/mqm/V6R0M0/java/lib/providerutil.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar:/usr/l
pp/mqm/V6R0M0/java/lib/jms.jar:/usr/lpp/mqm/V6R0M0/java/lib/rmm.jar:/usr/lpp/mqm/V6R0M0/java/lib/providerutil.jar:/usr/l
pp/mqm/V6R0M0/j
ava/lib/jta.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar:/usr/l
pp/mqm/V6R0M0/java/lib/jms.jar:/usr/lpp/mqm/V6R0M0/java/lib/rmm.jar:/usr/lpp/mqm/V6R0M0/java/lib/providerutil.jar:/usr/l
pp/mqm/V6R0M0/j
ava/lib/jta.jar:/usr/lpp/mqm/V6R0M0/java/lib/fscontext.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar:/usr/l
pp/mqm/V6R0M0/java/lib/jms.jar:/usr/lpp/mqm/V6R0M0/java/lib/rmm.jar:/usr/lpp/mqm/V6R0M0/java/lib/providerutil.jar:/usr/l
pp/mqm/V6R0M0/j
ava/lib/jta.jar:/usr/lpp/mqm/V6R0M0/java/lib/fscontext.jar:/usr/lpp/mqm/V6R0M0/java/lib/dhbcore.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar:/usr/l
pp/mqm/V6R0M0/java/lib/jms.jar:/usr/lpp/mqm/V6R0M0/java/lib/rmm.jar:/usr/lpp/mqm/V6R0M0/java/lib/providerutil.jar:/usr/l
pp/mqm/V6R0M0/j
ava/lib/jta.jar:/usr/lpp/mqm/V6R0M0/java/lib/fscontext.jar:/usr/lpp/mqm/V6R0M0/java/lib/dhbcore.jar:/usr/lpp/mqm/V6R0M0/
java/lib/CL3Nonexport.jar
JVMJZBL2999T + export CLASSPATH=:/usr/lpp/db2810/jcc/classes:/usr/lpp/db2810/jcc/classes/db2jcc.jar:/usr/lpp/db2810/jcc/
classes/db2jcc_javax.jar:/usr/lpp/db2810/jcc/classes/sqlj.zip:/usr/lpp/db2810/jcc/classes/db2jcc_license_cisuz.jar:/usr/
lpp/mqm/V6R0M0/
java/lib/com.ibm.mq.jar:/usr/lpp/mqm/V6R0M0/java/lib/com.ibm.mqjms.jar:/usr/lpp/mqm/V6R0M0/java/lib/connector.jar:/usr/l
pp/mqm/V6R0M0/java/lib/jms.jar:/usr/lpp/mqm/V6R0M0/java/lib/rmm.jar:/usr/lpp/mqm/V6R0M0/java/lib/providerutil.jar:/usr/l
pp/mqm/V6R0M0/j
ava/lib/jta.jar:/usr/lpp/mqm/V6R0M0/java/lib/fscontext.jar:/usr/lpp/mqm/V6R0M0/java/lib/dhbcore.jar:/usr/lpp/mqm/V6R0M0/
java/lib/CL3Nonexport.jar:/usr/lpp/mqm/V6R0M0/java/lib/CL3Export.jar
JVMJZBL2999T + export JAVA_HOME=/usr/lpp/Java601_31/J6.0.1
JVMJZBL2999T + export PATH=/usr/lpp/db2810/jcc/bin:/usr/local/bin:/usr/lpp/Printsrv/bin:/bin:.:/bin:/usr/lpp/Java601_31/
J6.0.1/bin:/u/DAINEK/MvsSubmitJob2
JVMJZBL2999T + LIBPATH=/lib:/usr/lib:/usr/lpp/Java601_31/J6.0.1/bin
JVMJZBL2999T + LIBPATH=/lib:/usr/lib:/usr/lpp/Java601_31/J6.0.1/bin:/usr/lpp/Java601_31/J6.0.1/lib/s390
JVMJZBL2999T + LIBPATH=/lib:/usr/lib:/usr/lpp/Java601_31/J6.0.1/bin:/usr/lpp/Java601_31/J6.0.1/lib/s390:/usr/lpp/Java601
_31/J6.0.1/lib/s390/j9vm
JVMJZBL2999T + LIBPATH=/lib:/usr/lib:/usr/lpp/Java601_31/J6.0.1/bin:/usr/lpp/Java601_31/J6.0.1/lib/s390:/usr/lpp/Java601
_31/J6.0.1/lib/s390/j9vm:/usr/lpp/Java601_31/J6.0.1/bin/classic
JVMJZBL2999T + export LIBPATH=/lib:/usr/lib:/usr/lpp/Java601_31/J6.0.1/bin:/usr/lpp/Java601_31/J6.0.1/lib/s390:/usr/lpp/
Java601_31/J6.0.1/lib/s390/j9vm:/usr/lpp/Java601_31/J6.0.1/bin/classic:
JVMJZBL2999T + APP_HOME=/usr/lpp/Java601_31/J6.0.1
JVMJZBL2999T + CLASSPATH=/usr/lpp/Java601_31/J6.0.1:/usr/lpp/Java601_31/J6.0.1/lib:/usr/lpp/Java601_31/J6.0.1/lib/ext
JVMJZBL2999T + CLASSPATH=/usr/lpp/Java601_31/J6.0.1:/usr/lpp/Java601_31/J6.0.1/lib:/usr/lpp/Java601_31/J6.0.1/lib/ext:/u
sr/lpp/Java601_31/J6.0.1/*.jar
JVMJZBL2999T + export CLASSPATH=/usr/lpp/Java601_31/J6.0.1:/usr/lpp/Java601_31/J6.0.1/lib:/usr/lpp/Java601_31/J6.0.1/lib
/ext:/usr/lpp/Java601_31/J6.0.1/*.jar:
JVMJZBL2999T + IJO=-Xms16m -Xmx128m
JVMJZBL2999T + export IBM_JAVA_OPTIONS=-Xms16m -Xmx128m
JVMJZBL2999T + export CLASSPATH=/usr/lpp/Java601_31/J6.0.1:/usr/lpp/Java601_31/J6.0.1/lib:/usr/lpp/Java601_31/J6.0.1/lib
/ext:/usr/lpp/Java601_31/J6.0.1/*.jar::/u/DAINEK/MvsSubmitJob2
JVMJZBL2999T + echo ___JZOS_ENV_START___
JVMJZBL2999T Found environment start string
JVMJZBL2999T ___JZOS_ENV_START___
JVMJZBL2999T Ignored line: + env
JVMJZBL1006I MAIL = /usr/mail/
JVMJZBL1006I PATH = /usr/lpp/db2810/jcc/bin:/usr/local/bin:/usr/lpp/Printsrv/bin:/bin:.:/bin:/usr/lpp/Java601_31/J6.0.1/
bin:/u/DAINEK/MvsSubmitJob2
JVMJZBL1006I IBM_JAVA_OPTIONS = -Xms16m -Xmx128m
JVMJZBL1006I PS1 = $LOGNAME:$PWD: >
JVMJZBL1006I _BPX_SPAWN_SCRIPT = YES
JVMJZBL1006I _ = /bin/env
JVMJZBL1006I CLASSPATH = /usr/lpp/Java601_31/J6.0.1:/usr/lpp/Java601_31/J6.0.1/lib:/usr/lpp/Java601_31/J6.0.1/lib/ext:/u
sr/lpp/Java601_31/J6.0.1/*.jar::/u/DAINEK/MvsSubmitJob2
JVMJZBL1006I STEPLIB = DSNA10.IAS.SDSNEXIT:DSNA10.SDSNLOAD:DSNA10.SDSNLOD2:
JVMJZBL1006I LANG = C
JVMJZBL1006I LIBPATH = /lib:/usr/lib:/usr/lpp/Java601_31/J6.0.1/bin:/usr/lpp/Java601_31/J6.0.1/lib/s390:/usr/lpp/Java601
_31/J6.0.1/lib/s390/j9vm:/usr/lpp/Java601_31/J6.0.1/bin/classic:
JVMJZBL1006I _BPX_SHAREAS = YES
JVMJZBL1006I JAVA_HOME = /usr/lpp/Java601_31/J6.0.1
JVMJZBL1006I TZ = GMT-3
JVMJZBL1006I MANPATH = /usr/lpp/Printsrv/man/%L:/usr/man/%L
JVMJZBL1006I NLSPATH = /usr/lpp/Printsrv/%L/%N:/usr/lib/nls/msg/%L/%N:/usr/lib/nls/msg/%L/%N.cat
JVMJZBL1006I + echo PWD = /u/DAINEK
JVMJZBL1006I PWD = /u/DAINEK
JVMJZBL2999T Setting current working dir to: "/u/DAINEK"
JVMJZBL2999T Ignored line: + echo ___JZOS_ENV_STOP___
JVMJZBL2999T Found environment stop string
JVMJZBL2999T + exit
JVMJZBL2999T waiting for child shell process to complete
JVMJZBL2999T -> waitChild()
JVMJZBL2999T child shell process exited with exit code 0
JVMJZBL2999T <- waitChild()
JVMJZBL2999T <- adoptEnvironment()
JVMJZBL2999T argvг2…: CallRexx
JVMJZBL2999T argvг3…: BBOS001
JVMJZBL2999T argvг4…: STC05206
JVMJZBL2999T -> processExtraArgs()
JVMJZBL2999T No JZOS_MAIN_ARGS found
JVMJZBL2999T NO //DD:MAINARGS found
JVMJZBL2999T mainArgsBuf=""
JVMJZBL2999T <- processExtraArgs()
JVMJZBL2999T -> initializeVMArgs()
JVMJZBL2999T vm_args.version: 10004
JVMJZBL2999T Getting CLASSPATH
JVMJZBL2999T Classpath option string: '-Djava.class.path=/usr/lpp/Java601_31/J6.0.1:/usr/lpp/Java601_31/J6.0.1/lib:/usr/
lpp/Java601_31/J6.0.1/lib/ext:/usr/lpp/Java601_31/J6.0.1/*.jar::/u/DAINEK/MvsSubmitJob2'
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T <- initializeVMArgs()
JVMJZBL2999T -> createJvm()
JVMJZBL2999T JNI_CreateJavaVM elapsed time=0.316160 seconds, cpu time=0.229972 seconds
JVMJZBL2999T <- createJvm()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> StaticMethod.invoke()
JVMJZBL2999T com.ibm.jzos.ZUtil.getJavaVersionInfo
JVMJZBL2999T method invocation elapsed time=0.004090 seconds, cpu time=0.008901 seconds
JVMJZBL2999T <- StaticMethod.invoke()
JVMJZBL1012I Java Virtual Machine created. Version information follows:
java version "1.6.0"
Java(TM) SE Runtime Environment (build 20110418_80450)
IBM J9 VM (build 2.6, JRE 1.6.0 z/OS s390-31 20110418_80450 (JIT enabled, AOT enabled)
J9VM - R26_Java626_GA_FP1_20110418_1915_B80450
JIT - r11_20110215_18645ifx8
GC - R26_Java626_GA_FP1_20110418_1915_B80450
J9CL - 20110418_80450)
JVMJZBL2999T -> checkVersions()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> StaticMethod.invoke()
JVMJZBL2999T com.ibm.jzos.ZUtil.getJzosJarVersion
JVMJZBL2999T method invocation elapsed time=0.000323 seconds, cpu time=0.000713 seconds
JVMJZBL2999T <- StaticMethod.invoke()
JVMJZBL2999T Build versions match: 2.4.0 2010-11-16
JVMJZBL2999T <- checkVersions()
JVMJZBL2999T -> redirectStandardStreams()
JVMJZBL2999T No JZOS_OUTPUT_ENCODING found, using the default codeset 'IBM-1047'
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> StaticMethod.invoke()
JVMJZBL2999T com.ibm.jzos.ZUtil.redirectStandardStreams
JVMJZBL2999T method invocation elapsed time=0.011800 seconds, cpu time=0.009094 seconds
JVMJZBL2999T <- StaticMethod.invoke()
JVMJZBL1027I Using output encoding: IBM-1047
JVMJZBL2999T <- redirectStandardStreams()
JVMJZBL2999T -> establishMvsCommandListener()
JVMJZBL1016I MVS commands are ENABLED
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> StaticMethod.invoke()
JVMJZBL2999T com.ibm.jzos.MvsConsole.startMvsCommandListener
JVMJZBL2999T method invocation elapsed time=0.001133 seconds, cpu time=0.001118 seconds
JVMJZBL2999T <- StaticMethod.invoke()
JVMJZBL2999T <- establishMvsCommandListener()
JVMJZBL2999T -> invokeMain()
JVMJZBL2999T javaClassName: 'CallRexx'
JVMJZBL1023N Invoking CallRexx.main()...
JVMJZBL1056I Arguments to main...
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> JniUtil.convert()
JVMJZBL2999T <- JniUtil.convert()
JVMJZBL2999T -> StaticMethod.invoke()
JVMJZBL2999T CallRexx.main
JVMJZBL2999T method invocation elapsed time=0.041121 seconds, cpu time=0.015940 seconds
JVMJZBL2999T <- StaticMethod.invoke()
JVMJZBL1024N CallRexx.main() completed.
JVMJZBL2999T <- invokeMain()
JVMJZBL2999T <- run()
JVMJZBL2999T -> cleanup()
JVMJZBL1014I Waiting for non-deamon Java threads to finish before exiting...
JVMJZBL2999T JvmExitHook entered with exitCode=0, javaMainReturnedOrThrewException=1
JVMJZBL2999T DestroyJavaVM elapsed time=0.004513 seconds, cpu time=0.002609 seconds
JVMJZBL2999I JZOS batch launcher elapsed time=0 seconds, cpu time=0.540000 seconds
JVMJZBL1021N JZOS batch launcher completed, return code=0
JVMJZBL2999T <- cleanup()
JVMJZBL2999T -> ~JzosVM()
JVMJZBL2999T <- ~JzosVM()
And get STDOUT:
environ(0)=LIBPATH=/usr/lpp/Java601_31/J6.0.1/lib/s390/default:/lib:/usr/lib:/usr/lpp/Java601_31/J6.0.1/bin:/usr/lpp/Java601_31/J6.0
.1/lib/s390:/usr/lpp/Java601_31/J6.0.1/lib/s390/j9vm:/usr/lpp/Java601_31/J6.0.1/bin/classic::/usr/lpp/Java601_31/J6.0.1/lib/s390/def
ault:/usr/lpp/Java601_31/J6.0.1/lib/s390
environ(1)=_BPX_SHAREAS=YES
environ(2)=JAVA_HOME=/usr/lpp/Java601_31/J6.0.1
environ(3)=NLSPATH=/usr/lpp/Printsrv/%L/%N:/usr/lib/nls/msg/%L/%N:/usr/lib/nls/msg/%L/%N.cat
environ(4)=LANG=C
environ(5)=_BPX_SPAWN_SCRIPT=YES
environ(6)=MANPATH=/usr/lpp/Printsrv/man/%L:/usr/man/%L
environ(7)=PWD=/u/DAINEK
environ(8)=PS1=$LOGNAME:$PWD: >
environ(9)=MAIL=/usr/mail/
environ(10)=TZ=GMT-3
environ(11)=CLASSPATH=/usr/lpp/Java601_31/J6.0.1:/usr/lpp/Java601_31/J6.0.1/lib:/usr/lpp/Java601_31/J6.0.1/lib/ext:/usr/lpp/Java601_
31/J6.0.1/*.jar::/u/DAINEK/MvsSubmitJob2
environ(12)=_EDC_PTHREAD_YIELD=-2
environ(13)=STEPLIB=DSNA10.IAS.SDSNEXIT:DSNA10.SDSNLOAD:DSNA10.SDSNLOD2:
environ(14)=IBM_JAVA_OPTIONS=-Xms16m -Xmx128m
environ(15)=PATH=/usr/lpp/db2810/jcc/bin:/usr/local/bin:/usr/lpp/Printsrv/bin:/bin:.:/bin:/usr/lpp/Java601_31/J6.0.1/bin:/u/DAINEK/M
vsSubmitJob2
environ(16)=+ echo PWD=/u/DAINEK
environ(17)=_=/bin/env
line=null
Value =say: /u/DAINEK/MvsSubmitJob2/jobStatus 1: FSUM7351 not found
RC =127
FSUM7351:
not found
Explanation
You attempted to execute a command that could not be found.
User response
Ensure that the command exists and that the PATH environment variable is valid.
Why it gives this error?
I think that Java does not recognize the contents file named "jobStatus" as a REXX script..
Somebody ran REXX through Java?