Problem:
The RTS error on failure is one which may be caused by an environment variable setting problem, e.g. 173, 211, 114, etc. How to check the environment while running in CGI mode and compare it to the command line environment?
Resolution:
One good way to compare environments is to run the mfsupport utility from the successful command line environment and from the cgi environment. A comparison of the environment sections of both output files may reveal the problem. However, it is not simple to run mfsupport in the cgi environment.
To do the latter, write a small cgi program which contains the following fragments:
01 mfsupport-command-line.
10 mfsupport-command pic x(200) value 'mfsupport > /dev/null 2>&1'.
10 filler value x'00'.
call 'SYSTEM' using mfsupport-command-line.
Please note the use of UPPER CASE for the name of the called routine.
This is also a general method of issuing Unix command lines from a Cobol program.



