View previous topic :: View next topic
|
Author |
Message |
Grant Goodale
New User
Joined: 13 Nov 2010 Posts: 67 Location: Brampton, Ontario, Canada
|
|
|
|
I have a compiled REXX exec that invokes commands in a file via:
"BPXBATCH SH" file_name
I have STDOUT allocated to an OMVS dataset. When I run this on our system, it works just fine.
When the compiled load module is run on another system, no output is writted to STDOUT. There are no messages issued to STDERR. I do not have direct access to this other system.
I cannot figure out the reason for the missing output. Could an environment variable be causing this?
Yes, I did a forum search before posting this.
TIA |
|
Back to top |
|
|
Rohit Umarjikar
Global Moderator
Joined: 21 Sep 2010 Posts: 3053 Location: NYC,USA
|
|
Back to top |
|
|
Grant Goodale
New User
Joined: 13 Nov 2010 Posts: 67 Location: Brampton, Ontario, Canada
|
|
|
|
Rohit -
I am aware of most of that information. However, there are a few things that I will have to test. I have circumvented the problem by redirecting the output to a file rather than STDOUT.
I will post any new developments here.
Thanks |
|
Back to top |
|
|
Ed Goodman
Active Member
Joined: 08 Jun 2011 Posts: 556 Location: USA
|
|
|
|
Ugh..trying to debug a problem on a system to which you have no access!
Check the basics.
Make them copy the JCL they used and let you see it. It could be a typo.
Make sure they have permission to write to the file name they used.
Did they compile it themselves, or are they running YOUR load module?
Make them give you the entire job output. There could be a BPXBATCH error message. |
|
Back to top |
|
|
Grant Goodale
New User
Joined: 13 Nov 2010 Posts: 67 Location: Brampton, Ontario, Canada
|
|
|
|
Quote: |
Make them copy the JCL they used and let you see it. It could be a typo. |
JCL looks good to me.
Quote: |
Make sure they have permission to write to the file name they used. |
Their user ID is a super-user
Quote: |
Did they compile it themselves, or are they running YOUR load module? |
They are running my load module.
I modified the REXX to have the output redirected to a file rather than STDOUT. I have also turned trace on in the REXX. Now, when they run it, the trace says:
*-* "BPXBATCH SH" hfscmd ">" hfsout
>>> "BPXBATCH SH /tmp/rhfsadm-etc....
+++ RC(35072) +++
I have no idea of the meaning of code 35072. Google gave various other hits for this on things like Red Hat Linux but nothing that seemed to be related to what I am doing. I thought that it might be related to region size so I tried it with REGION=64K and I recieved RC(-2168).
At least I am now getting an error code of some sorts. I guess that is progress. |
|
Back to top |
|
|
Ed Goodman
Active Member
Joined: 08 Jun 2011 Posts: 556 Location: USA
|
|
Back to top |
|
|
Grant Goodale
New User
Joined: 13 Nov 2010 Posts: 67 Location: Brampton, Ontario, Canada
|
|
|
|
My invocation of BPXBATCH only executes a command script, not any of my own programs. The command input script is as follows:
Code: |
PS1="#";export PS1
echo ' '
echo ">> CMD:" chmod o=rwx '/u/userid/file.txt'
chmod o=rwx '/u/userid/file.txt'
echo "<< RC: $?"
echo ">>>> CMDEND"
exit
|
I have inherited this code so I am not that familiar with all of its contents. The strange thing is that this code works just fie on my system but it does not appear to work on another users system (in a different country). |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
Currency symbols don't always translate from country to country; that '$' might need to be changed. |
|
Back to top |
|
|
Grant Goodale
New User
Joined: 13 Nov 2010 Posts: 67 Location: Brampton, Ontario, Canada
|
|
|
|
The end user is in Europe so it is probably being converted to a euro sign.
Many thanks. |
|
Back to top |
|
|
Grant Goodale
New User
Joined: 13 Nov 2010 Posts: 67 Location: Brampton, Ontario, Canada
|
|
|
|
According to the IBM UNIX System Services User's Guide, $# is:
Quote: |
The number of positional parameters passed to this shell script. This number can be changed by several shell commands (for example, set or shift); |
To me, that sounds like things should be OK. However, I will keep investigating this. |
|
Back to top |
|
|
Ed Goodman
Active Member
Joined: 08 Jun 2011 Posts: 556 Location: USA
|
|
|
|
The dollar sign question mark combination is showing the return code of the most recent command.
The dollar sign means 'variable' and the question mark is the return code.
You can see things like:
command1
cmd1_rc=$?
command2
cmd2_rc=$?
echo $cmd1_rc $cmd2_rc
I just did a quick search on how to use the variable indicator on a system with Euro symbols, and got nothing. It's possible that it still requires the dollar sign character to work. If so, you're going to have to get that file transferred without that character being translated. |
|
Back to top |
|
|
Grant Goodale
New User
Joined: 13 Nov 2010 Posts: 67 Location: Brampton, Ontario, Canada
|
|
|
|
Finally got this one nailed down! Turns out that the user needed REGION=48M on the EXEC to make it work. REGION=32M gave a 4093 abend.
Unix is definitely the result of caffeine overdose
|
|
Back to top |
|
|
Ed Goodman
Active Member
Joined: 08 Jun 2011 Posts: 556 Location: USA
|
|
|
|
48M?!?! That's a lot of space!
So glad it's working. |
|
Back to top |
|
|
|