Saturday, September 14, 2013

Origin of Oracle EBS Introduction

Level: Intermediate
Operating system: SunOS 5.10 Bash Shell
Disclaimer; the content of this blog are solely mine; I accept no liability for using it in your environment.

Origin of Oracle EBS Introduction


Oracle EBS is a suite of integrated software applications, or modules powered by multiple independent components capable of functioning independently. It evolved from different standalone components and upon close examination of its DNA, you can see inherited traits from its ancestors Apache, Oracle Application Server, Advanced Queue, Oracle database.

Apache -> Oracle HTTP server -> Oracle Application Server - >EBS web server

“Oracle HTTP Server Powered by Apache provides the communication services within Oracle Application Server. This facilitates deployment of HTML-based applications within a multi-tiered computing environment”.
 Oracle E-Business Suite System Administrator's Guide - Configuration Release 12.1 Part Number E12893-04

An example would be apache web server; you can install and run it separately.  EBS components run within three layers or tiers, the Desktop/client, Middle or Application and Database Tier. The Middle layer host most of the components Web server, Forms server, Concurrent Processing (Batch or Job schedulers). The database functions as a repository for data and code.

The web server serves static and dynamic pages. The dynamic pages are mainly Java Servlets and Java server pages. They both render dynamic data but are built differently and JSP pages end with a .jsp extension while Servlet pages don’t have an extension. JSP pages are easier to work with because you can insert raw html tags in them.


The hook to display dynamic  web page via JSP or Servlet requires java programming and a Java engine to interpret the Java commands. This raises the question about the web servers inability to execute a program in java without a Java runtime component (OC4J) engine. HTTP (hypertext transfer protocol) primary design was for collaborative distribution of hypertext, beyond that through extension of its request it can be used for programming. http://www.w3.org/Protocols/rfc2616/rfc2616.html

It is important to set your environment using the APP_$CONTEXT_NAME.env before running any command.

Set Environment

source  APP_$CONTEXT_NAME.env
echo $CONTEXT_NAME
PROD_pluto

A Tale of TWO Oracle HOMES

There are two Oracle homes within EBS. The web server $IAS_ORACLE_HOME and forms/developer home $ORACLE_HOME. They are different versions of the Oracle Application Server.

set | grep ORACLE
IAS_ORACLE_HOME=/space/R12/apps/tech_st/10.1.3

ORACLE_HOME=/space/R12/apps/tech_st/10.1.2

grep Version $IAS_ORACLE_HOME/config/ias.properties
Version=10.1.3.4.0

grep Version $ORACLE_HOME/config/ias.properties
Version=10.1.2.3.0


The $IAS_ORACLE_HOME is responsible for all http request also known as known as the web entry Point service group. $ORACLE_HOME form/developer home supports Oracle Forms by running frmweb executable
$IAS_ORACLE_HOME runs the web server to which responds to all http requests this is known as the web entry Point service group.

Http Version

$IAS_ORACLE_HOME/Apache/Apache/bin/httpd -v
Server version: Oracle-Application-Server-10g/10.1.3.4.0 Oracle-HTTP-Server
Server built:   Jul 15 2008 02:14:02

$ORACLE_HOME/Apache/Apache/bin/httpd –v
pluto.xlabbsd.net:('PROD_pluto')> $ORACLE_HOME/Apache/Apache/bin/httpd -v
Server version: Oracle-Application-Server-10g/10.1.2.2.0 Oracle-HTTP-Server
Server built:   Jan 25 2008 15:37:28


What is running out of $ORACLE_HOME

ps –eaf | grep frm
applmgr 22171 21853   0 04:59:24 ?           0:01 /space/R12/apps/tech_st/10.1.2/bin/frmweb server webfile=HTTP-0,0,1,default,192
This Oracle home  does not serve http request but runs the Forms executable, however the instance of each form running within OC4J is delivered to the user desktop via  IAS_ORACLE_HOME. The web listener for OC4J, Oracle Containers for J2EE.

What is running out of $IAS_ORACLE_HOME

You can confirm which location your web server is running from by listing httpd processes
ps -eaf | grep httpd

/space/R12/apps/tech_st/10.1.3/Apache/Apache/bin/httpd -d /space/R12/apps/tech_
/space/R12/apps/tech_st/10.1.3/Apache/Apache/bin/httpd -d /space/R12/apps/tech_

Further you can see which configuration file is used to start the server by querying the process argument.
with pargs  or ps auxwwfe (Linux)

$INST_TOP/admin/scripts/adopmnctl.sh status

Processes in Instance: PROD_pluto.pluto.xlabbsd.net

---------------------------------+--------------------+---------+---------
ias-component                    | process-type       |     pid | status
---------------------------------+--------------------+---------+---------
OC4JGroup:default_group          | OC4J:oafm          |   18781 | Alive
OC4JGroup:default_group          | OC4J:forms         |   18750 | Alive
OC4JGroup:default_group          | OC4J:oacore        |   18714 | Alive
HTTP_Server                      | HTTP_Server        |   18658 | Alive

OC4J:oafm   Java virtual machine for running Map viewer applications           
OC4J:forms  Java virtual machine for running Forms          
OC4J:oacore Java virtual machine all web request or pages  

HTTP Configuration File  

There is a plethora of HTTP configurations files located within EBS installation, two reside within the two oracle homes and others within $INST_TOP.

Note this pid 18658 is a parent process which spawns other child httpd processes.

pargs 18658
18658:  /space/R12/apps/tech_st/10.1.3/Apache/Apache/bin/httpd -d /space/R12/apps/tech_
argv[0]: /space/R12/apps/tech_st/10.1.3/Apache/Apache/bin/httpd
argv[1]: -d
argv[2]: /space/R12/apps/tech_st/10.1.3/Apache/Apache
argv[3]: -DSSL
argv[4]: -f
argv[5]: /space/R12/inst/apps/PROD_pluto/ora/10.1.3/Apache/Apache/conf/httpd.conf

find ./ -name http.conf –print
./apps/tech_st/10.1.3/Apache/Apache/conf/httpd.conf
./apps/tech_st/10.1.2/Apache/Apache/conf/httpd.conf
./apps/tech_st/10.1.2/dcm/config/plugins/apache/httpd.conf
./inst/apps/PROD_pluto/admin/out/03031908/httpd.conf
./inst/apps/PROD_pluto/admin/out/11281237/httpd.conf
./inst/apps/PROD_pluto/ora/10.1.3/Apache/Apache/conf/httpd.conf

The configuration files contain instructions for configuration and functionality of the web server. It also allows extension for support for Java programming language via mod_oc4j.conf


What Port is accepting http request

By default most web servers accept request on port 80, however EBS uses higher number ports toavoid conflicts. The port has the Listen directive in the httpd.conf file, which is used by the httpd deamon

grep Listen $INST_TOP/ora/10.1.3/Apache/Apache/conf/httpd.conf

# See also the <VirtualHost> and Listen directives.
Listen 8020

The context file is the main repository of EBS configuration, no surprise that we can also determine the http port from reviewing the file. 

grep web_port $CONTEXT_FILE
      <web_port oa_var="s_webport" oa_type="PORT" base="8000" step="1" range="-1" label="Web Listener Port">8020</web_port>


Include Directives


Apache functionality is extened by including the module directive. a programs so it employs  mod_oc4j, a module for  ( Oracle Container for J2EE) its responsible for executing all java related pages by routing  all http request to the Java containers for execution.

grep mod_oc4j  $INST_TOP/ora/10.1.3/Apache/Apache/conf/httpd.conf

# Include the configuration files needed for mod_oc4j
include "/space/R12/inst/apps/PROD_pluto/ora/10.1.3/Apache/Apache/conf/mod_oc4j.conf"

Directive Document Root

Apache has a directive for default location to serve files not defined elsewhere or overridden by other directives. oracle has gracefully included a reference to redirect you the EBS pages.

grep DocumentRoot  $INST_TOP/ora/10.1.3/Apache/Apache/conf/httpd.conf

# DocumentRoot: The directory out of which you will serve your
DocumentRoot "/space/R12/inst/apps/PROD_pluto/portal"


more $INST_TOP/portal/index.html

Oracle's  warning

This is Oracle’s attempt to warn you not to manage the web server as a regular one but use commands in $ADMIN_SCRIPTS_HOME.

more $IAS_ORACLE_HOME/Apache/Apache/conf/EBIZ_R12_README.txt
######################################################################
#  txkstubcgf1013.pl
#
# Oracle E-Business Suite Release 12 does not use the configuration
# files present in this directory for day to day running of services.
# The configuration files present in this directory are required for
# ORACLE_HOME maintenance and patching utilities.
######################################################################

Start and Stop

$INST_TOP/admin/scripts or $ADMIN_SCRIPTS_HOME contains the scripts to start and stop services on the Middle tier. These scripts call the configuration file $CONTEXT_FILE when starting the application.

grep $CONTEXT_FILE $ADMIN_SCRIPTS_HOME/adstrtal.sh