ARS 3.x and Higher

ars_ExecuteProcess(ctrl, command, runOption=0)

Execute the given command on the server host as the user-id that the server process is running as. Requires Administrator privs to use.

runOptionExplanation
0Wait for process to complete and then returned the process' returnStatus and any output that the process had.
1Don't wait for process to complete.
On success
Depending upon the runOption specified returns a list of returnStatus and returnString or 1
On failure
Returns undef.

Example:

	(($returnCode, $returnString) = ars_ExecuteProcess($ctrl, "/bin/ls -l /")) || 
		die "$ars_errstr";
      
ars_ExecuteProcess was introduced in version 1.5 of ARSperl.


<-- Table of Contents

Last changes to this page 21st July 1997 by jcmurphy@arsperl.org
© J.C.Murphy, J.W.Murphy 1997 arsperl@arsperl.org