Troubleshooting OAS Instance

Posted By Sagar Patil

How to start Oracle Application Server?

Starting an application server instance

a) login to server with oracle Userid
b) set the environment
c) cd $ORACLE_HOME/opmn/bin
d) opmnctl startall (to start)

How to stop Oracle Application Server?

Stopping an application server instance

a) login to server with oracle Userid
b) set the environment
c) cd $ORACLE_HOME/opmn/bin
d) opmnctl stopall (to stop)

How to query the status of an Oracle Application Server?

Status of an application server instance

a) login to server with oracle Userid
b) set the environment
c) cd $ORACLE_HOME/opmn/bin
d) opmnctl status

How to start/stop/restart a component of Oracle Application Server?

a) login to server with oracle Userid
b) set the environment
c) cd $ORACLE_HOME/opmn/bin
d) opmnctl startproc ias-component=HTTP_Server (to start HTTP server)
e) opmnctl stopproc ias-component=HTTP_Server (to stop HTTP server)
f) opmnctl restartproc ias-component=HTTP_Server (to restart HTTP server)

Where are the important OAS configuration files?

Oracle Application Server comprises of various components which together provide 3-tier application deployment environment. Following are the important configuration file in various components.

Oracle HTTP Server

$ORACLE_HOME/Apache/Apache/conf/httpd.conf

Oracle AS Forms Services

$ORACLE_HOME/forms/server/forms.conf
$ORACLE_HOME/forms/server/formsweb.cfg
$ORACLE_HOME/forms/server/default.env
$ORACLE_HOME/forms/java/oracle/forms/registry/Registry.dat

Oracle AS Report Services

$ORACLE_HOME/reports/conf/rep_hostname.conf

Oracle AS Web Cache

$ORACLE_HOME/Webcache/Webcache.xml

How to deploy forms to Oracle Application Server?

a) FTP the forms to Oracle Application Server

b) Create the following directory structure under /opt/forms/ORACLE_SID

i. Config – for any application configuration files

ii. Logfiles – for log files

iii. Source – for application source code (*.fmb, *.pll, *.mmb)

iv. Executables – for compiled application code (*.fmx, *.plx etc)

v. Images – for application images

vi. Reports – for reports

c) Compile forms (*.fmb), libraries (*.pll) and menus (*.mmb)

(Refer to how to compile a form for more information)

d) Modify default.env, reports.sh and rep_hostname.conf application server configuration files

$ORACLE_HOME/forms/server/default.env – ADD /opt/forms/ORACLE_SID/executables directory to FORMS_PATH & CLASS_PATH. ADD /opt/forms/ORACLE_SID/images directory to FORMS_PATH.

$ORACLE_HOME/bin/reports.sh – ADD /opt/forms/ORACLE_SID/reports directory to REPORTS_PATH.

$ORACLE_HOME/reports/conf/rep_hostname.conf – ADD /opt/forms/ORACLE_SID/reports directory to SourceDir XML tag.

e) Restart the application server.

How to compile a form on UNIX environment?

I have written 6 shell scripts to compile various forms and reports components

Compile.sh – To compile a form

Compileall.sh – To compile all forms

Compilepll.sh – To compile a library

Compileallpll.sh – To compile all libraries

Compilemenu.sh – To compile a menu

Compileallmenu.sh – To compile all menus

a) Set the DISPLAY variable (e.g. DISPLAY=172.17.21.167:0.0; export DISPLAY)

b) cd /opt/forms/ORACLE_SID/forms

c) ./compile.sh form_name (to compile a form) or ./compileall.sh (to compile all forms)

What are the important log files on Oracle Application Server?

The trace and diagnostic information is distributed across a number of different places in oracle application server 3-tier architecture.

Jinitiator Trace File

The first place to look for trace information is on the client machine. Jinitiator is a Java Virtual Machine (JVM) responsible for running the Forms Java client. Setting the following Java runtime parameters in the Jinitiator Control Panel will enable Jinitiator tracing.

-Djavaplugin.trace=true

-Djavaplugin.trace.option=basic|net|security|ext|liveconnect.

This will produce a trace file, Jinitiator<version>.trace in the User Home Directory. For example, if the User Home Directory is C:\Documents and Settings\username and Jinitiator version1.3.1.9 is used, the file C:\Documents and Settings\username\jinitiator1319.trace will be produced.

Oracle HTTP Server Access_log and Error_log

 

When a Forms application is running on the Web, the HTTP Server is responsible for the transmission of metadata, between the Forms client and the Forms runtime, as standard HTTP(S) messages.

The HTTP Server is enabled by default to log basic information about all HTTP

requests to the access_log file and report errors in the error_log file. It is possible to increase the logging level on the HTTP Server using the LogLevel directive in httpd.conf. However, the default basic logging information is sufficient to troubleshoot the Forms Listener Servlet and detailed logging is not required

Oracle HTTP Server Access_log and Error_log are found in the following

directory on the application server:

$ORACLE_HOME/Apache/Apache/logs

OC4J_BI_Forms Application.log

Finally, the Forms Listener Servlet is responsible for marshalling the communication between the individual Forms clients and their corresponding Forms runtime processes. Basic diagnostic information for this component is found in the application.log when the Forms Listener Servlet is used in the default mode.

Detailed diagnostic information can be obtained from the application.log by enabling debugging in the Forms Listener Servlet as follows:

- appending the /debug option to serverURL in the formsweb.cfg file

Eg: serverURL=/forms/lservlet/debug

The application.log is found in the following locations:

$ORACLE_HOME/j2ee/OC4J_BI_Forms/formsapp/OC4J_BI_Forms_default_island_1/

How to configure WEBUTIL on Oracle Application Server?

a) Download webutil version 1.0.6 from the following location http://www.oracle.com/technology/software/products/forms/index.html

b) After you have downloaded and extracted, the WebUtil directory structure has these folders:

doc
java
server
webutil

c) Webutil.pll, Webutil.olb and the create_webutil_db.sql exist in the Forms directory. When you extract the WebUtil Zip file, its contents are extracted into the ORACLE_HOME\forms folder. All files will be copied to the respective directories in the ORACLE_HOME\forms.

d) Create ‘webutil’ user on your database and execute create_webutil_db.sql script. This script creates WEBUTIL_DB package, create a public synonym of this package to make it available for everyone.

e) Add the following parameter to $ORACLE_HOME/forms/server/formsweb.cfg file

webUtilArchive=/forms/java/frmwebutil.jar, /forms/java/jacob.jar

baseHTMLjinitiator=webutiljini.htm

baseHTMLjpi=webutiljpi.htm

baseHTML=webutilbase.htm

f) Recompile webutil.pll, use the following command:

g) Frmcmp.sh module=$ORACLE_HOME/forms/webutil.pll userid=<webutil/webutil@dbconnect> module_type=library compile_all=yes

h) Do the following to deploy Jacob.jar file

1. Download http://prdownloads.sourceforge.net/jacob-project/jacob_18.zip

2. From the JACOB Zip file, extract both jacob.dll and jacob.jar into the ORACLE_HOME\forms\WebUtil and ORACLE_HOME\forms\java directories respectively.

3. You need to sign both frmwebutil.jar and jacob.jar with the same digital certificate. This is a one-time operation which allows your end-users to trust that the JACOB routines can access client side resources. If you do not have an existing signing certificate, or if you are not sure how to sign Jar files, a script is in the forms\WebUtil directory to help you. This script is called sign_webutil.sh

To sign the Jar files:

Check that ORACLE_HOME/jdk/bin is in the path. If it is not, add it.

Issue sign_webutil.sh $ORACLE_HOME/forms/java/frmwebutil.jar to sign frmwebutil.jar file and sign_webutil.sh $ORACLE_HOME/forms/java/jacob.jar to sign jacob.jar

Leave a Reply

You must be logged in to post a comment.

Top of Page

Top menu