iologcloseactionrunhost() is used to specify a /path/filename to be executed on the runhost when the iolog is closed. The specified /path/filename can be a shell script or binary. The user to run the program as, environment, arguments, and working directory are specified in the function call. Stdin, stdout, stderr are redirected to /dev/null. The timeout (specified in seconds) is mandatory. A timeout value of zero indicates no timeout. Note that a timeout value greater than zero causes the end user’s invocation of pbrun to pause while the close action takes place or until the timeout expires. Any runtime errors such as invalid user, cwd, or command are logged via syslog, and to the appropriate Privilege Management for Unix and Linux log (for example,pbrunlog, pblocaldlog) if specified in pb.settings.

Iologcloseactionrunhost( user, environment, timeout, cwd "/path/command and arguments");
User The user to run the command. This user must exist on the runhost.
Environment ENV settings to execute the command with. If an empty list is specified, su – is used to create a login environment.
Timeout Required integer. When set to 0, no timeout is used, and the specified command could potentially run forever. When set to > 0, specified the number of seconds for a timeout. If the timeout is reached, the command is terminated using SIGTERM, and if needed, by a SIGKILL.

Required string to specify the working directory.

With an empty environment list, this directory may be changed via the login shell.
command Required string specifying the fully qualified command, and its arguments. This is passed to su using su’s –c option.
iologcloseactionrunhost(  "jsmith", {"PATH=/bin", "TMPDIR=/tmp/", "PBUL=PBULTEST"},  20, "/tmp", "/usr/local/bin/closeaction –a –b" );
iologcloseactionrunhost(  "root", {},  0, "/tmp", "/usr/local/bin/closeaction –a –b" );

For more information, please see iolog.