Sunday, 5 January 2014

Running a shell script as a concurrent program:

These are the few steps which is required to make a host based Concurrent Program.

 
Step 1:
Write shell Script and save it as test.prog
Place the test.prog script under the “bin” directory in application top directory e.g “$FND_TOP/bin”.

Step 2:
Make a symbolic link from your script to $FND_TOP/bin/fndcpesr
For example, if the script is called test.prog use this:

ln -s $FND_TOP/bin/fndcpesr test

This link should be named the same as your script without the “.prog” extension.
Put the link for your script in the same directory where the script is located.

Step 3:  
   Logon to Oracle Application  > System Administrator responsibility
   Navigate Concurrent > Program > Executable and enter a new one:
   Executable: Test Host Program
   Short Name: XXTSTHST
   Application: Application Object Library
   Description: Test Host Program
   Execution Method: Host
   Execution File Name: test
   Save.

Step 4:  
   Navigate to: Concurrent > Program > Define and enter a new one:
   Program: Test Host Program
   Short Name: XXTSTHST
   Application: Application Object Library
   Description: Test Host Program
   Name: XXTSTHST
   Method: Host

Step 5:  
If the script contains parameters, click on Parameters and add any parameters you might use for the script.
   Example:
   - Seq: 10 
     Parameter: Param1
     Description: Parameter 1 Value 
     Set: 15 Characters
     click on the Required: checkfield.
   - Seq: 20
     Parameter: Param2
     Description: Parameter 2 Value 
     Set: 15 Characters
     click on the Required: checkfield.
     Save.

Step 6:  
 Navigate Security > Responsibility > Request
   Query for Group: System Administrator Reports and add one request
   Type: Program, Name:  Test Host Program
   Save.

Note:  
1.  Your script will be passed at least 4 parameters, between $1 and $4.
      These are:
           $1 = orauser/pwd (Database Apps Schema User and Password)
           $2 = userid (Application Login User ID)
           $3 = username (Application Login User Name)
           $4 = request_id (Concurrent Request ID)
       Any other parameters you define will be passed in $5 and higher.
2.  Make sure your script returns an exit status also
3.  EBS OS user must have execute and read rights on shell script file  
4.  Use ${10}, ${11} instead of $10,$11 to refer to double-digit parameters
5.  If your script returns a failure exit status but the concurrent manager does not report the error and hows that it is still running normal then you should apply patch 442824.

No comments:

Post a Comment