How can I use the “substitute user” command in COZBATCH?

Discussion of the COZBATCH utility for z/OS
Post Reply
mghayman
Posts: 6
Joined: Mon Mar 30, 2009 6:49 pm
Location: Melbourne

How can I use the “substitute user” command in COZBATCH?

Post by mghayman »

When I try to use the “su” command in my STDIN file I receive the following error:

/bin/su: FSUM9209 cannot execute: reason code = 0b1b0473: EDC5157I An internal error has occurred.

This works OK in BXPBATCH. Is there any way I can make it work for COZBATCH?
dovetail
Site Admin
Posts: 2022
Joined: Thu Jul 29, 2004 12:12 pm

Post by dovetail »

COZBATCH does a local spawn of your login shell (-/bin/sh), and it order to do this, it must set _BPX_SHAREAS=MUST.

If your .profile or /etc/profile doesn't set _BPX_SHAREAS, then MUST will still be set when your script runs, and this would probably prevent "su" and other APF or "Shared Address Space=no" commands from running.

Add a line "env" to the beginning of your script to see how your environment is set.
mghayman
Posts: 6
Joined: Mon Mar 30, 2009 6:49 pm
Location: Melbourne

How can I use the “substitute user” command in COZBATCH?

Post by mghayman »

The "env" command showed that _BPX_SHAREAS was indeed set to 'MUST'. I added the "export _BPX_SHAREAS=YES" command and I can now execute the "su" command successfully. Thanks for your help.
Post Reply