259 lines
12 KiB
HTML
259 lines
12 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<meta name="Copyright" content="Copyright (c) 2006 by IBM Corporation">
|
|
<title>i5/OS PASE Environment Variables</title>
|
|
<!-- Begin Header Records -->
|
|
<!-- All rights reserved. Licensed Materials Property of IBM -->
|
|
<!-- US Government Users Restricted Rights -->
|
|
<!-- Use, duplication or disclosure restricted by -->
|
|
<!-- GSA ADP Schedule Contract with IBM Corp. -->
|
|
<!-- Change History: -->
|
|
<!-- YYMMDD USERID Change description -->
|
|
<!-- Created by V2DCIJB on 23 Nov 1999 -->
|
|
<!-- Edited by Kersten Jan 02 -->
|
|
<!-- End Header Records -->
|
|
<link rel="stylesheet" type="text/css" href="../rzahg/ic.css">
|
|
</head>
|
|
<body>
|
|
<!-- Java sync-link -->
|
|
<script type="text/javascript" language="Javascript" src="../rzahg/synch.js">
|
|
</script>
|
|
|
|
<a name="Top_Of_Page"></a>
|
|
|
|
<h2>i5/OS PASE Environment Variables</h2>
|
|
|
|
<h3>Overview</h3>
|
|
|
|
<p>i5/OS PASE environment variables are independent of ILE environment
|
|
variables. Setting a variable in one environment has no effect on the other
|
|
environment, but several system interfaces allow you to copy variables between
|
|
environments:</p>
|
|
|
|
<ul>
|
|
<li>The <strong>Qp2RunPase</strong> API lets you specify any list of
|
|
environment variables you want to initialize for the i5/OS PASE program. See
|
|
<a href="qp2runpase.htm">Run an i5/OS PASE Program</a> (Qp2RunPase)
|
|
documentation for more information.<br><br></li>
|
|
|
|
|
|
<li>The <strong>QP2SHELL</strong> and <strong>QP2TERM</strong> APIs initialize
|
|
the i5/OS PASE environment with a copy of nearly all ILE environment
|
|
variables. See <a href="qp2shell.htm">Run an i5/OS PASE Shell Program</a>
|
|
(QP2SHELL) documentation for more information.<br><br></li>
|
|
|
|
|
|
<li>The <strong>systemCL</strong> i5/OS PASE runtime function copies nearly
|
|
all i5/OS PASE environment variables to the ILE environment for option
|
|
<strong>SYSTEMCL_ENVIRON</strong>. See <a href="pase_systemcl.htm">Run a CL
|
|
Command for i5/OS PASE</a> (systemCL) documentation for more information.<br><br></li>
|
|
|
|
|
|
<li>The i5/OS PASE <strong>system</strong> utility copies nearly all i5/OS
|
|
PASE environment variables to the ILE environment for option
|
|
<strong>-e</strong>. See <a href="../rzalc/pase_system.htm">Run a CL
|
|
Command</a> (i5/OS PASE <strong>system</strong> utility) documentation for
|
|
more information.<br><br></li>
|
|
|
|
</ul>
|
|
|
|
<br>
|
|
|
|
<h3>Special i5/OS PASE Environment Variables</h3>
|
|
|
|
<p>Some i5/OS PASE runtime behaviors are different from AIX because of
|
|
differences between the two operating systems. You can use these i5/OS PASE
|
|
environment variables to control some of the differences:</p>
|
|
|
|
<dl>
|
|
<dt><strong>PASE_EXEC_QOPENSYS</strong></dt>
|
|
|
|
<dd><strong>PASE_EXEC_QOPENSYS</strong> can be used to prevent the system from
|
|
searching the /QOpenSys file system for an absolute path (starting with "/")
|
|
specified as an argument to <strong>exec</strong> or
|
|
<strong>Qp2RunPase</strong>, or in the first line of a shell script. The system
|
|
normally searches the /QOpenSys file system if the absolute path name for an
|
|
i5/OS PASE program or script cannot be opened or is not a regular bytestream
|
|
file. i5/OS directory /usr/bin contains links to QShell utilities that cannot
|
|
run as i5/OS PASE programs, so searching /QOpenSys allows more AIX programs
|
|
and shell scripts to run unchanged (using i5/OS PASE utilities in directory
|
|
/QOpenSys/usr/bin). The system does not do an extended search in the /QOpenSys
|
|
file system if the i5/OS PASE shell or other program that calls
|
|
<strong>exec</strong> or <strong>Qp2RunPase</strong> has changed credentials
|
|
(<strong>setuid</strong> or <strong>setgid</strong>) or if the i5/OS PASE
|
|
environment specifies <strong>PASE_EXEC_QOPENSYS=N</strong>.<br><br></dd>
|
|
|
|
<dt><strong>PASE_FORK_JOBNAME</strong></dt>
|
|
|
|
<dd><strong>PASE_FORK_JOBNAME</strong> specifies the i5/OS job name for a new process created with the <strong>fork()</strong> or <strong>f_fork()</strong> function.
|
|
Only the first 10 characters in the string are used, and lowercase characters are converted to uppercase.
|
|
The specified value is ignored and a default job name is used if the string does not follow i5/OS simple name rules (first character alphabetic and subsequent characters alphameric or underscore).
|
|
Prestarted job are never used when a fork job name is specified.
|
|
See <a href="pase_fork400.htm">fork or f_fork Specifying i5/OS Job Name</a> (fork400 or f_fork400) for information about specifying the i5/OS job name for specific fork operations.
|
|
<p>
|
|
Some i5/OS PASE shells (including the default Korn shell) do not set environment variables for exported variables in the shell process itself.
|
|
Setting <strong>PASE_FORK_JOBNAME</strong> in such a shell does not control job names for first-order utility processes created by that shell, but can control job names for processes forked by a utility started by the shell.
|
|
<br><br></dd>
|
|
|
|
|
|
|
|
<dt><strong>PASE_MAXDATA64</strong></dt>
|
|
|
|
<dd><strong>PASE_MAXDATA64</strong> specifies the maximum number of 256MB
|
|
segments provided for brk (heap) storage in a 64-bit i5/OS PASE program. If
|
|
<strong>PASE_MAXDATA64</strong> is omitted or contains an invalid value (either
|
|
non-numeric or less than one), a default of 256 segments (64GB) is used.
|
|
<strong>PASE_MAXDATA64</strong> has no effect on 32-bit i5/OS PASE programs,
|
|
and it must be set either in the initial environment passed to
|
|
<strong>Qp2RunPase</strong> or before running <strong>exec</strong> for a
|
|
64-bit i5/OS PASE program.<br><br></dd>
|
|
|
|
|
|
<dt><strong>PASE_MAXSHR64</strong></dt>
|
|
|
|
<dd><strong>PASE_MAXSHR64</strong> specifies the maximum number of 256MB
|
|
segments provided for shared memory (shmat and mmap) in a 64-bit i5/OS PASE
|
|
program. If <strong>PASE_MAXSHR64</strong> is omitted or contains an invalid
|
|
value (either non-numeric or less than one), a default of 256 segments (64GB)
|
|
is used. <strong>PASE_MAXSHR64</strong> has no effect on 32-bit i5/OS PASE
|
|
programs, and it must be set either in the initial environment passed to
|
|
<strong>Qp2RunPase</strong> or before running <strong>exec</strong> for a
|
|
64-bit i5/OS PASE program.<br><br></dd>
|
|
|
|
<dt><strong>PASE_STDIO_ISATTY</strong></dt>
|
|
|
|
<dd>The default behavior of the i5/OS PASE <strong>isatty</strong> runtime
|
|
function returns true for file descriptors 0, 1, and 2 (stdin, stdout, and
|
|
stderr), regardless of whether the open file is a tty device. Setting i5/OS
|
|
PASE environment variable <strong>PASE_STDIO_ISATTY</strong> to N, either in
|
|
the initial environment passed to <strong>Qp2RunPase</strong> or before the
|
|
first invocation of <strong>isatty</strong>, causes <strong>isatty</strong> to
|
|
return an accurate indication of whether the open file is a tty device.<br><br></dd>
|
|
|
|
<dt><strong>PASE_SYSCALL_NOSIGILL</strong></dt>
|
|
|
|
<dd>The i5/OS PASE kernel exports some system calls that are implemented by
|
|
the AIX kernel but are unsupported by i5/OS PASE. The default behavior for any unsupported syscall is to
|
|
send exception message MCH3204, which the system converts to i5/OS PASE signal
|
|
<strong>SIGILL</strong>. The unsupported syscall returns a function result of
|
|
-1 with i5/OS-unique errno EUNKNOWN (3474) if the signal is ignored or the
|
|
handler returns. Message MCH3204 appears in the i5/OS job log to provide the
|
|
name of the unsupported system call and the i5/OS PASE instruction address
|
|
that caused the error. The message may also include the internal dump
|
|
identifier for a VLOG entry that contains this information:
|
|
|
|
<pre>
|
|
syscall number (GPR2 value)
|
|
i5/OS PASE instruction address
|
|
Link register value
|
|
GPR3-10 values (if available, or zero otherwise)
|
|
syscall name (if known, converted to uppercase)
|
|
</pre>
|
|
|
|
<p>i5/OS PASE programs can suppress the exception message and
|
|
<strong>SIGILL</strong> signal for unsupported system calls by setting
|
|
environment variable <strong>PASE_SYSCALL_NOSIGILL</strong> either in the
|
|
initial environment passed to <strong>Qp2RunPase</strong> or before running
|
|
<strong>exec</strong>. <strong>PASE_SYSCALL_NOSIGILL</strong> is ignored if the
|
|
i5/OS PASE program has the S_ISUID or S_ISGID attribute, but otherwise is
|
|
interpreted as a list of syscall function names with optional errno values,
|
|
delimited by colons. The colon-delimited values must take one of these
|
|
forms:</p>
|
|
|
|
|
|
<pre>
|
|
syscall_name
|
|
syscall_name=errno_name (errno_name is EINVAL, EPERM, and so on)
|
|
syscall_name=errno_number (errno_number is 0-127)
|
|
</pre>
|
|
|
|
<p><strong>SIGILL</strong> is suppressed for any <em>syscall_name</em> in the
|
|
list that is recognized as an i5/OS PASE system call. The first or only entry
|
|
in the list may use a special <em>syscall_name</em> of "ALL" to set a default
|
|
behavior for all unsupported syscalls. Any entry in the list that is not an
|
|
i5/OS PASE syscall name is ignored, and specifying the name of a syscall that
|
|
is supported by the i5/OS PASE kernel has no effect on the operation of that
|
|
syscall.</p>
|
|
|
|
|
|
<p>Any syscall in the <strong>PASE_SYSCALL_NOSIGILL</strong> list that is
|
|
unsupported by the i5/OS PASE kernel returns a function result of -1 with the
|
|
specified errno value (defaulting to ENOSYS) except that specifying
|
|
errno_number of 0 causes the unsupported syscall to return a function result of
|
|
zero (without setting errno). An invalid errno_name or errno_number defaults to
|
|
ENOSYS.</p>
|
|
|
|
|
|
|
|
<p>For example, the following <strong>PASE_SYSCALL_NOSIGILL</strong> value
|
|
suppresses <strong>SIGILL</strong> for all unsupported syscalls. "quotactl"
|
|
returns EPERM and "audit" returns function result of zero, while all other
|
|
unsupported syscalls return ENOSYS:</p>
|
|
|
|
<pre>
|
|
export PASE_SYSCALL_NOSIGILL=ALL:quotactl=EPERM:audit=0
|
|
</pre>
|
|
|
|
|
|
<p>Note: <strong>PASE_SYSCALL_NOSIGILL</strong> is not intended for production
|
|
programs. It is provided as a convenience for feasibility testing using
|
|
unchanged AIX binaries that need to be modified for production.</p>
|
|
|
|
</dd>
|
|
|
|
|
|
<dt><strong>PASE_THREAD_ATTACH</strong></dt>
|
|
|
|
<dd>If i5/OS PASE environment variable <strong>PASE_THREAD_ATTACH</strong> is
|
|
set to Y when an i5/OS PASE program runs libpthreads.a initialization (usually
|
|
at program startup), an ILE thread that was not started by i5/OS PASE will be
|
|
attached to i5/OS PASE when it calls an i5/OS PASE procedure (using
|
|
<strong>Qp2CallPase</strong> or <strong>Qp2CallPase2</strong>). Once an ILE
|
|
thread has attached to i5/OS PASE, that thread is subject to asynchronous
|
|
interruption for i5/OS PASE functions such as signal handling and thread
|
|
cancellation. In particular, the thread will be canceled as part of ending the
|
|
i5/OS PASE program (when <strong>exit</strong> runs or i5/OS PASE processing
|
|
terminates for a signal).<br><br></dd>
|
|
|
|
|
|
<dt><strong>PASE_UNLIMITED_PATH_MAX</strong></dt>
|
|
|
|
<dd>The i5/OS Integrated File System supports longer path names than the value
|
|
of <strong>PATH_MAX</strong> (1023) in AIX header file
|
|
<<strong>limits.h</strong>>. Setting i5/OS PASE environment variable
|
|
<strong>PASE_UNLIMITED_PATH_MAX</strong> to Y, either in the initial
|
|
environment passed to <strong>Qp2RunPase</strong> or before running
|
|
<strong>exec</strong>, allows an i5/OS PASE program to access objects with
|
|
long path names. i5/OS PASE loader functions and some library runtime
|
|
functions can fail with path names longer than AIX
|
|
<strong>PATH_MAX</strong>.<br><br></dd>
|
|
|
|
|
|
|
|
<dt><strong>PASE_USRGRP_LOWERCASE</strong></dt>
|
|
|
|
<dd>i5/OS user names and group names are case-insensitive, but the system
|
|
stores and returns them in uppercase. i5/OS PASE runtime functions that return
|
|
user names and group names (getpwnam, getpwuid, getgrnam, and getgrgid) default
|
|
to converting them to lowercase unless i5/OS PASE environment variable
|
|
<strong>PASE_USRGRP_LOWERCASE</strong> is set to N.</dd>
|
|
|
|
|
|
</dl>
|
|
<br>
|
|
<hr>
|
|
<center>
|
|
<table cellpadding="2" cellspacing="2">
|
|
<tr align="center"><td valign="middle" align="center">
|
|
<a href="#Top_Of_Page">Top</a>
|
|
| <a href="pase1.htm">i5/OS PASE APIs</a>
|
|
| <a href="aplist.htm">APIs by category</a>
|
|
</td></tr>
|
|
</table>
|
|
</center>
|
|
</body>
|
|
</html>
|
|
|