Actually there is missing DISP=DELETE for unix files
Of course another solution for the conflicting names would be to use
home directory, not /tmp.
--
Radoslaw Skorupka
Lodz, Poland
W dniu 27.08.2026 o 16:46, Kirk Wolf pisze:
Hmm, what happens if another user does the following before your run your job
and before /tmp/cmd.txt is created?
cd /tmp
echo "rm -rf /" > cmd.txt
chmod 644 cmd.txt
PS> BPXBATCH sucks.
Kirk Wolf
Dovetailed Technologies
https://coztoolkit.com
On Wed, Aug 26, 2026, at 6:38 PM, Dana Mitchell wrote:
If you put the commands in a unix file, you can feed them into bpxbatch/su via
STDIN:
//*-----------------------------------------------------------------*/
//* Copy command to uss file
//*-----------------------------------------------------------------*/
//OCOPY1 EXEC PGM=IKJEFT01
//SYSTSPRT DD SYSOUT=*
//FILE DD PATH='/tmp/cmd.txt',
// PATHOPTS=(OWRONLY,OCREAT),
// PATHMODE=(SIRWXU,SIRGRP)
//SYMOUT DD SYSOUT=*
//CARDS DD *,SYMBOLS=(EXECSYS,SYMOUT)
cd /u/zzzz/ibm/zzz-3_1_1-20260810
pax -ppx -rvzf zzzz-3.1.1-zzzzz-20260810.pax.Z
/*
//SYSTSIN DD *
OCOPY +
INDD(CARDS) +
OUTDD(FILE) +
TEXT +
PATHOPTS(OVERRIDE)
/*
//*-----------------------------------------------------------------*/
//* Issue command under su
//*-----------------------------------------------------------------*/
//UNMOUNT EXEC PGM=BPXBATCH,
// PARM='SH su'
//STDIN DD PATH='/tmp/cmd.txt',PATHOPTS=(ORDONLY)
//STDOUT DD SYSOUT=*
//STDERR DD SYSOUT=*
//*-----------------------------------------------------------------*/
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN